瀏覽代碼

更改人员单日请假显示日期一样的问题,更改要是日记数据录不进去的问题

sunyanqiang 2 年之前
父節點
當前提交
44098550eb
共有 2 個文件被更改,包括 24 次插入20 次删除
  1. 16 12
      src/views/grassrootsregistration/bdgldiary/index.vue
  2. 8 8
      src/views/peopleChuRu/leaveOne/index.vue

+ 16 - 12
src/views/grassrootsregistration/bdgldiary/index.vue

@@ -1982,13 +1982,15 @@ export default {
           ) {
             this.form.bdglDiaryLeaveList = this.qingJia;
           }
-          // 工作安排
-          if (
-            this.xunlian[0].dateline != null &&
-            this.xunlian[0].contents != null &&
-            this.xunlian[0].percentage != null
-          ) {
-            this.form.bdglDiaryWeekworkRegisterList = this.xunlian;
+          if (this.xunlian.length > 0) {
+            // 工作安排
+            if (
+              this.xunlian[0].dateline != null &&
+              this.xunlian[0].contents != null &&
+              this.xunlian[0].percentage != null
+            ) {
+              this.form.bdglDiaryWeekworkRegisterList = this.xunlian;
+            }
           }
           if (this.form.id != null) {
             updateBdgldiary(this.form).then((response) => {
@@ -2023,11 +2025,13 @@ export default {
               this.form.kinsfolk = this.relatives;
             }
             // 工作安排
-            if (
-              this.xunlian[0].dateline != null &&
-              this.xunlian[0].contents != null
-            ) {
-              this.form.bdglDiaryWeekworkRegisterList = this.xunlian;
+            if (this.xunlian.length > 0) {
+              if (
+                this.xunlian[0].dateline != null &&
+                this.xunlian[0].contents != null
+              ) {
+                this.form.bdglDiaryWeekworkRegisterList = this.xunlian;
+              }
             }
             this.form.blogDate = new Date(this.form.blogDate);
             // // 训练计划

+ 8 - 8
src/views/peopleChuRu/leaveOne/index.vue

@@ -85,11 +85,11 @@
         prop="startTime"
         width="180"
       >
-        <template slot-scope="scope">
+        <!-- <template slot-scope="scope">
           <span>{{
             parseTime(scope.row.startTime, "{y}-{m}-{d} {h}:{m}:{s}")
           }}</span>
-        </template>
+        </template> -->
       </el-table-column>
       <el-table-column
         label="请假结束时间"
@@ -97,11 +97,11 @@
         prop="endTime"
         width="180"
       >
-        <template slot-scope="scope">
+        <!-- <template slot-scope="scope">
           <span>{{
             parseTime(scope.row.endTime, "{y}-{m}-{d} {h}:{m}:{s}")
           }}</span>
-        </template>
+        </template> -->
       </el-table-column>
       <el-table-column label="请假类型" align="center" prop="leaveType">
         <template slot-scope="scope">
@@ -123,11 +123,11 @@
         prop="departureTime"
         width="180"
       >
-        <template slot-scope="scope">
+        <!-- <template slot-scope="scope">
           <span>{{
             parseTime(scope.row.departureTime, "{y}-{m}-{d} {h}:{m}:{s}")
           }}</span>
-        </template>
+        </template> -->
       </el-table-column>
       <el-table-column
         label="归队时间"
@@ -135,11 +135,11 @@
         prop="returnTime"
         width="180"
       >
-        <template slot-scope="scope">
+        <!-- <template slot-scope="scope">
           <span>{{
             parseTime(scope.row.returnTime, "{y}-{m}-{d} {h}:{m}:{s}")
           }}</span>
-        </template>
+        </template> -->
       </el-table-column>
       <el-table-column
         label="操作"