Преглед изворни кода

Merge branch 'master' of http://47.100.37.243:10191/wutt/manHourHousekeeper

QuYueTing пре 2 дана
родитељ
комит
f821f81fa4

+ 13 - 13
fhKeeper/formulahousekeeper/timesheet_mld/src/views/project/gantt.vue

@@ -257,19 +257,19 @@ export default {
     gantt.config.end_date = new Date(this.valueDate[1]);
 
     //设置任务条样式
-    gantt.templates.task_class = function (start, end, item) {
-      const { taskPlan, taskStatus } = item
-      if(taskStatus == 5 || taskStatus == 6) {
-        return "reject_line"
-      }
-      if(taskPlan == 1 && taskStatus == 0) {
-        return "success_line"
-      }
-      if(taskPlan == 1 && taskStatus == 2) {
-        return "draft_line"
-      }
-      return item.taskPlanType == 3 ? "error_line" : "person_line"
-    };
+    // gantt.templates.task_class = function (start, end, item) {
+    //   const { taskPlan, taskStatus } = item
+    //   if(taskStatus == 5 || taskStatus == 6) {
+    //     return "reject_line"
+    //   }
+    //   if(taskPlan == 1 && taskStatus == 0) {
+    //     return "success_line"
+    //   }
+    //   if(taskPlan == 1 && taskStatus == 2) {
+    //     return "draft_line"
+    //   }
+    //   return item.taskPlanType == 3 ? "error_line" : "person_line"
+    // };
 
     const that = this
     // 设置任务条内容显示

+ 1 - 1
fhKeeper/formulahousekeeper/timesheet_mld/src/views/project/list.vue

@@ -116,7 +116,7 @@
                     <!-- <router-link to="/projectGantt"> -->
                         <el-link type="primary" :underline="false" @click="isganttshow = true">{{ $t('resourceallocation') }}</el-link>
                     <!-- </router-link> -->
-                    <el-dialog v-if="isganttshow" :visible.sync="isganttshow" width="90vw" top="3vh" style="height:96%" class="ganttdialog">
+                    <el-dialog v-if="isganttshow" :visible.sync="isganttshow" fullscreen class="ganttdialog">
                         <projectgantt ref="projectganttRef"></projectgantt>
                     </el-dialog>
                 </el-form-item>

+ 1 - 1
fhKeeper/formulahousekeeper/timesheet_mld/src/views/project/project_gantt.vue

@@ -640,7 +640,7 @@ export default {
   .left-container {
     overflow: hidden;
     position: relative;
-    height: 60vh;
+    height: 80vh;
   }
   .demand-container{
     overflow: hidden;

+ 10 - 1
fhKeeper/formulahousekeeper/timesheet_mld/src/views/task/list.vue

@@ -81,12 +81,18 @@
                     </div>
                 </el-form-item>
                 <el-form-item style="float: right;" v-if="user.companyId != '3092'">
+                    <el-link type="primary" :underline="false" @click="isganttshow = true" style="margin-right: 10px;" v-if="permissions.projectResources">资源分配</el-link>
                      <el-link type="primary" :underline="false" @click="addTask()">新建任务</el-link>
                      <el-link type="primary" :underline="false" @click="importTaskDialog = true" style="margin-left: 10px;">批量导入</el-link>
                      <el-link type="primary" :underline="false" @click="exportTaskList()" style="margin-left: 10px;" v-loading="exportTaskLoading"  >数据导出</el-link>
                 </el-form-item>
             </el-form>
         </el-col>
+        <!-- 资源分配 -->
+        <el-dialog v-if="isganttshow" :visible.sync="isganttshow" fullscreen class="ganttdialog">
+            <projectgantt ref="projectganttRef"></projectgantt>
+        </el-dialog>
+
         <div style="display: flex;width: 100%;">
             <div class="classification">
                 <div>
@@ -625,6 +631,7 @@ import { error } from 'dingtalk-jsapi';
     import cascaderOption from "@/components/cascaderOption.vue"
 
     import taskComponent from "@/components/taskComponent.vue"
+    import projectgantt from "../project/project_gantt.vue"
 
     // 富文本样式
     import 'quill/dist/quill.core.css'
@@ -648,7 +655,8 @@ import { getThemeColor } from '@/utils/commonMethod.js'
             selectCat,
             taskComponent,
             vueCascader,
-            cascaderOption
+            cascaderOption,
+            projectgantt
         },
         data() {
             return {
@@ -828,6 +836,7 @@ import { getThemeColor } from '@/utils/commonMethod.js'
                 tablesTwoKey: 300,
                 tableMultipleSelection: [],
                 loadingExport: false,
+                isganttshow: false,
             };
         },
         methods: {