|
@@ -9,6 +9,7 @@ import com.platform.dao.entity.part.PartType;
|
|
import com.platform.dao.entity.sb.SbInfo;
|
|
import com.platform.dao.entity.sb.SbInfo;
|
|
import com.platform.dao.entity.sb.SbPosition;
|
|
import com.platform.dao.entity.sb.SbPosition;
|
|
import com.platform.dao.entity.sb.SbType;
|
|
import com.platform.dao.entity.sb.SbType;
|
|
|
|
+import com.platform.dao.entity.spareAdd.LongYanInventoryCode;
|
|
import com.platform.dao.entity.sqarepartmanage.SpareType;
|
|
import com.platform.dao.entity.sqarepartmanage.SpareType;
|
|
import com.platform.dao.entity.store.Store;
|
|
import com.platform.dao.entity.store.Store;
|
|
import com.platform.dao.entity.upms.SysDept;
|
|
import com.platform.dao.entity.upms.SysDept;
|
|
@@ -295,6 +296,29 @@ public class TreeUtil {
|
|
return TreeUtil.buildByLoop(trees, root);
|
|
return TreeUtil.buildByLoop(trees, root);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * 通过sysMenu创建树形节点
|
|
|
|
+ *
|
|
|
|
+ * @param menus
|
|
|
|
+ * @param root
|
|
|
|
+ * @return
|
|
|
|
+ */
|
|
|
|
+ public List<CommonTree> buildInventoryCodeTree(List<LongYanInventoryCode> menus, String root) {
|
|
|
|
+ List<CommonTree> trees = new ArrayList<>();
|
|
|
|
+ menus.forEach(menu -> {
|
|
|
|
+ CommonTree node = new CommonTree();
|
|
|
|
+ node.setId(menu.getId());
|
|
|
|
+ node.setKey(menu.getId());
|
|
|
|
+ node.setParentId(menu.getParentId());
|
|
|
|
+ node.setCode(menu.getCode());
|
|
|
|
+ node.setTitle(menu.getName());
|
|
|
|
+ node.setItem(menu);
|
|
|
|
+ node.setValue(menu.getId());
|
|
|
|
+ trees.add(node);
|
|
|
|
+ });
|
|
|
|
+ return TreeUtil.buildByLoop(trees, root);
|
|
|
|
+ }
|
|
|
|
+
|
|
/**
|
|
/**
|
|
* 通过sysMenu创建树形节点
|
|
* 通过sysMenu创建树形节点
|
|
*
|
|
*
|