| | |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import java.time.LocalDate; |
| | | import java.util.Arrays; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | |
| | | |
| | | //移动到固化树下的机床节点下层 |
| | | String newParentIds = machineNode.getParentIds()+","+machineNode.getId(); |
| | | |
| | | //更新机床 下属节点的数据 为旧版本,锁定(最新版本=0,lock=1) |
| | | this.nodeService.lambdaUpdate().likeRight(NcNode::getParentIds, newParentIds) |
| | | .in(NcNode::getNodeType, Arrays.asList(NcNode.TYPE_PROGRAM_PACKAGE,NcNode.TYPE_PROGRAM_FILE)) |
| | | .set(NcNode::getIsLastEdition,0).set(NcNode::getIsLocked,1).update(); |
| | | |
| | | for(NcNode hisNode : historyNodes){ |
| | | if(!hisNode.getId().equals(pkgNode.getId())){ |
| | | hisNode.setIsLastEdition(0); |