ggooalice 2 роки тому
батько
коміт
c778fdc3fc

+ 5 - 2
fhKeeper/formulahousekeeper/timesheet/src/views/expense/expense.vue

@@ -69,7 +69,7 @@
               </el-select>
             </el-form-item>
             <!-- 填报日期 -->
-            <el-form-item label="填报日期" style="position: relative;top: 38px;">
+            <el-form-item label="填报日期" style="position: relative;top: 38px;" prop="createDate">
               <el-col :span="11">
                 <el-date-picker type="date" placeholder="选择日期" v-model="addForm.createDate" value-format="yyyy-MM-dd" style="width: 200px;"></el-date-picker>
               </el-col>
@@ -473,7 +473,10 @@ export default {
       fileList: [],
       muHeight: document.documentElement.clientHeight || document.body.clientHeight,
       imgs: [],
-      addFormRules: {ownerId: [{ required: true, message: "请选择报销人", trigger: "blur" }]},      
+      addFormRules: {
+        ownerId: [{ required: true, message: "请选择报销人", trigger: "blur" }],
+        createDate: [{ required: true, message: "请选择日期", trigger: "blur" }],
+      },      
       isAuditList: false,
       statusTxt:["审核通过","待审核", "已驳回", "已撤销"],
       user: JSON.parse(sessionStorage.getItem("user")),

+ 18 - 0
fhKeeper/formulahousekeeper/timesheet/src/views/project/project_gantt.vue

@@ -474,6 +474,23 @@ export default {
                                   }
                                 }
                                 this.tasks = {data:res.data};
+                                let taskson = []
+                                for(let m in this.tasks.data){
+                                  this.tasks.data[m].render = null
+                                  if(this.tasks.data[m].time != 0){
+                                    
+                                    if(this.tasks.data[m].id != this.tasks.data[m].userId){
+                                      this.tasks.data[m].render = 'split'
+                                      let item = JSON.parse(JSON.stringify(this.tasks.data[m]))
+                                      item.parent = this.tasks.data[m].id
+                                      item.id = this.tasks.data[m].id + 'son'
+                                      taskson.push(item)
+                                      this.tasks.data[m].time = 0
+                                    }
+                                    
+                                  }
+                                }
+                                this.tasks.data.push.apply(this.tasks.data,taskson) 
                                 for(let i in this.tasks.data){
                                   if(this.tasks.data[i].time == 0){
                                     delete this.tasks.data[i].start_date
@@ -488,6 +505,7 @@ export default {
                                     this.tasks.data[i].end_date = date2.getFullYear() + '-' + (dmonth < 10 ? '0' + dmonth : dmonth) + '-' + (dday < 10 ? '0' + dday : dday)
                                   }
                                 }
+                                console.log('ganttData',this.tasks.data);
                                 this.$nextTick(()=>{
                                   this.updatakey1 += 1
                           })

+ 1 - 1
fhKeeper/formulahousekeeper/timesheet_h5/src/views/edit/index.vue

@@ -452,7 +452,7 @@
                         }
                         this.projectss = res.data;
                         this.project = res.data;
-                        this.projectss = this.projectss.filter(p=>p.status == 1);
+                        this.projectss = this.projectss.filter(p=>p.status == 1 || p.status == 4);
                         this.proads = res.data
                     } else {
                         this.$toast.fail('获取失败:'+res.msg);