yusm 5 gün önce
ebeveyn
işleme
6277354b69

+ 1 - 0
fhKeeper/formulahousekeeper/management-platform-mld/src/main/java/com/management/platform/entity/vo/GanttDataItem.java

@@ -18,6 +18,7 @@ public class GanttDataItem {
     public String end_date;
     public String parent;
     public Integer projectId;
+    public String projectName;
     public String render;
     public String type;
     public String translationType;

+ 5 - 1
fhKeeper/formulahousekeeper/management-platform-mld/src/main/java/com/management/platform/service/impl/ProjectServiceImpl.java

@@ -5162,6 +5162,7 @@ public class ProjectServiceImpl extends ServiceImpl<ProjectMapper, Project> impl
                         parent.id = userId;
                         parent.userId = (String) map.get("user_id");
                         parent.text = (String) map.get("name");
+                        parent.setProjectName(map.get("project_name") == null ? "请假" : (String) map.get("project_name"));
                         parent.render = "split";
                         parent.start_date = start_date;
                         parent.end_date = end_date;
@@ -5177,6 +5178,7 @@ public class ProjectServiceImpl extends ServiceImpl<ProjectMapper, Project> impl
                     curItem.userId = (String) map.get("user_id");
                     String s = map.get("project_name") == null ? "请假" : (String) map.get("project_name");
                     curItem.text = s +"/"+(String)map.get("task_name");
+                    curItem.setProjectName(map.get("project_name") == null ? "请假" : (String) map.get("project_name"));
                     curItem.start_date = start_date;
 
                     curItem.setTaskPlanType(map.get("taskPlanType")==null?null:(Integer)map.get("taskPlanType"));
@@ -5205,6 +5207,7 @@ public class ProjectServiceImpl extends ServiceImpl<ProjectMapper, Project> impl
                         parent.id = projectId;
                         parent.userId = (String) map.get("user_id");
                         String s = map.get("project_name") == null ? "请假" : (String) map.get("project_name");
+                        parent.setProjectName(map.get("project_name") == null ? "请假" : (String) map.get("project_name"));
                         parent.text = s;
                         parent.render = "split";
                         parent.start_date = start_date;
@@ -5218,6 +5221,7 @@ public class ProjectServiceImpl extends ServiceImpl<ProjectMapper, Project> impl
                     curItem.id = projectId+"_"+exeId;
                     curItem.userId = (String) map.get("user_id");
                     curItem.text = (String) map.get("name")+"/"+(String)map.get("task_name");
+                    curItem.setProjectName(map.get("project_name") == null ? "请假" : (String) map.get("project_name"));
                     curItem.setTaskPlanType(map.get("taskPlanType")==null?null:(Integer)map.get("taskPlanType"));
                     curItem.setIsTaskPlan(map.get("isTaskPlan")==null?null:(Integer)map.get("isTaskPlan"));
                     curItem.setCheckFirstId(map.get("checkFirstId")==null?null:(String) map.get("checkFirstId"));
@@ -5253,7 +5257,7 @@ public class ProjectServiceImpl extends ServiceImpl<ProjectMapper, Project> impl
         msg.data = itemList;
         if (type==1){
             for (GanttDataItem dataItem : itemList) {
-                if (dataItem.getProjectId()==null){
+                if (dataItem.getParent()==null){
                     dataItem.setTime(0.0);
                 }
             }