Browse Source

2022.5.26 9:19

山水共长天一色 3 years ago
parent
commit
360bb596dc

+ 32 - 11
fhKeeper/formulahousekeeper/timesheet/src/views/awayOffice/awayOffice.vue

@@ -191,16 +191,18 @@
                 <el-table :data="tableList" style="width: 100%" height="90%">
                     <el-table-column prop="ownerName" label="出差人员" width="100" fixed="left" align="center"></el-table-column>
                     <el-table-column prop="reason" label="出差事由" width="150" header-align="center"></el-table-column>
-                    <el-table-column prop="projectName" label="投入项目" width="150" align="center" show-overflow-tooltip>
+                    <el-table-column label="出差详情" width="600" align="center">
                         <template slot-scope="scope">
-                            <span v-for="item in scope.row.projectList" :key="item.projectId">{{item.projectName + '\u3000'}}</span>
+                            <div v-for="item in scope.row.projectList" :key="item.projectId" class="detailsScope">
+                                <span>{{item.startDate + '至' + item.endDate}}</span><span>{{item.projectName}}</span><span>{{item.degreeName}}</span>
+                            </div>
                         </template>
                     </el-table-column>
-                    <el-table-column prop="degreeName" :label="wuduData.customDegreeName" width="150" align="center" show-overflow-tooltip>
+                    <!-- <el-table-column prop="degreeName" :label="wuduData.customDegreeName" width="150" align="center">
                         <template slot-scope="scope">
                             <span v-for="item in scope.row.projectList" :key="item.projectId">{{item.degreeName == null ? '' : item.degreeName + '\u3000'}}</span>
                         </template>
-                    </el-table-column>
+                    </el-table-column> -->
                     <el-table-column label="交通工具" width="120" align="center">
                         <template slot-scope="scope">
                             <span v-if="scope.row.way == 0">飞机</span>
@@ -791,12 +793,7 @@ export default {
         },
         DingdingAddorMod(row){
             this.appendAddorModDialog = true
-            if(row == null){
-                this.relationItem.startDate = this.relationItemTemporaryDate.startDate
-                this.relationItem.endDate = this.relationItemTemporaryDate.endDate
-                this.relationItem.projectId = null
-                this.relationItem.degreeId = null
-            }else {
+            if(row){
                 this.relationItem.id = row.id
                 this.relationItem.projectId = row.projectId
                 this.getwuduList(2,1)
@@ -804,7 +801,12 @@ export default {
                 this.relationItem.endDate = row.endDate
                 this.relationItem.degreeId = row.degreeId == null ? row.degreeId : row.degreeId.toString()
                 // console.log('degreeId',this.relationItem.degreeId);
-                
+            }else {
+                this.relationItem.startDate = this.relationItemTemporaryDate.startDate
+                this.relationItem.endDate = this.relationItemTemporaryDate.endDate
+                this.relationItem.projectId = null
+                this.relationItem.degreeId = null
+                delete this.relationItem.id
             }
         },
         appendAddorModSure(formname){
@@ -1668,4 +1670,23 @@ export default {
 .addNode:hover {
   color:#20a0ff;
 }
+.detailsScope{
+    font-size: 12px;
+    padding: 3px 0;
+    line-height: 15px;
+}
+.detailsScope span:nth-child(1){
+    display: inline-block;
+    width: 25%;
+}
+.detailsScope span:nth-child(2){
+    display: inline-block;
+    width: 40%;
+    text-align: left;
+}
+.detailsScope span:nth-child(3){
+    display: inline-block;
+    width: 35%;
+    text-align: left;
+}
 </style>