设备编号增加

parent d271d9bb
...@@ -1700,6 +1700,14 @@ private GlobalParam InitGlobalParam() ...@@ -1700,6 +1700,14 @@ private GlobalParam InitGlobalParam()
for (Long id : MachineIds) { for (Long id : MachineIds) {
Machine machine = new Machine(); Machine machine = new Machine();
PlanResource PlanResource = PlanResources.stream()
.filter(t -> t.getId() == id.intValue())
.findFirst().orElse(null);
if (PlanResource != null){
machine.setCode(PlanResource.getReferenceCode());
machine.setName(PlanResource.getTitle());
machine.setDepartment(PlanResource.getDepartTitle());
}
machine.setId(id); machine.setId(id);
machines.add(machine); machines.add(machine);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment