Pārlūkot izejas kodu

选择时长填报情况下,默认时长按照timeType需求

Lijy 3 gadi atpakaļ
vecāks
revīzija
19506a95dc

+ 1 - 1
fhKeeper/formulahousekeeper/timesheet/src/views/project/projectInside.vue

@@ -270,7 +270,7 @@
                     </el-input>
                 <el-tree :data="deptMembData" show-checkbox :props="defaultProps" node-key="id"
                     ref="chooseMembTree2" @check-change="onTreeItemChange" :default-checked-keys="alreadyPartArray"
-                    highlight-current  :filter-node-method="filterNode" default-expand-all></el-tree>
+                    highlight-current  :filter-node-method="filterNode"></el-tree>
                 </el-scrollbar>
             </div>
             <div>已选中&nbsp;{{chosenMembCount}}&nbsp;人</div>

+ 11 - 1
fhKeeper/formulahousekeeper/timesheet/src/views/workReport/daily.vue

@@ -273,7 +273,7 @@
                         <el-select v-model="domain.workingTime" style="width:200px;"
                         v-if="reportTimeType.type == 1"
                         :disabled="workForm.domains.length==0?true:(workForm.domains[index].state>=2?false:true)"
-                        placeholder="请选择工作时长"
+                        :placeholder="'请选择工作时长' + domain.workingTime"
                         @change="seleChn(0,domain)">
                         <el-option v-for="item in timeRange" :key="item" :value="item.toFixed(1)">{{item.toFixed(1)}}</el-option>
                         </el-select>
@@ -1248,6 +1248,7 @@
     export default {
         data() {
             return {
+                alalal: '8.0',
                 timeBasecostList:null,
                 tbload: false,
                 exportTimeDialog: false,
@@ -3546,6 +3547,9 @@
                                 userNames:null,
                                 time: this.report.time
                             }
+                            if(this.user.timeType.type == 1) {
+                                    this.workForm.domains[0].workingTime = this.user.timeType.allday+'.0'
+                                }
                             if (this.timeBasecostList && this.timeBasecostList.length > 0) {
                                 //默认给第一个,必填字段
                                 this.workForm.domains[0].basecostId = this.timeBasecostList[0].id;
@@ -3590,6 +3594,7 @@
 
             // 打开日报填写
             fillInReport(i, isBatch) {
+                console.log(this.user.timeType.type, '选择时长')
                 if(i != 1) {
                     this.falsss = false 
                 } else {
@@ -3609,6 +3614,7 @@
                     this.workForm.createDate = this.date + day; // 获取个人某天的日报
                     this.getReport(i);
                 } else {
+                    console.log('执行到了这里')
                     this.jsTime = 0
                     this.jsDay = 0
                     this.workForm = {
@@ -3625,6 +3631,10 @@
                                     worktimeList:[{}],
                                 }],
                             }
+                            if(this.user.timeType.type == 1) {
+                                this.workForm.domains[0].workingTime = this.user.timeType.allday+'.0'
+                            }
+                            console.log(this.workForm)
                     if (this.timeBasecostList&&this.timeBasecostList.length>0) {
                         this.workForm.domains[0].basecostId = this.timeBasecostList[0].id;
                     }