Ver Fonte

Merge remote-tracking branch 'origin/master'

yurk há 2 anos atrás
pai
commit
36d32a54df

+ 34 - 30
fhKeeper/formulahousekeeper/timesheet/src/components/cascader.vue

@@ -26,7 +26,7 @@
         <div class="transitionBox">
             <ul class="transitionBoxUl">
                 <li :class="transitionBoxLiIdx == index ? 'liHover' : ''" v-for="(item, index) in options" :key="index" @mouseover="liMouseOver(index, item)" @click.stop="liClist(item)"> 
-                    <span :class="item.children ? 'idxspan' : ''" v-if="!radios">
+                    <span :class="item.children ? 'idxspan' : ''" v-if="!radios || fistRadio">
                         <!-- {{item.label}} -->
                         <span v-if="userName">
                             <span v-if="item.type == 'dep'">
@@ -41,7 +41,7 @@
                         </span>
                         <!-- <ww-open-data type='departmentName' :openid='item.label'></ww-open-data> -->
                     </span>
-                    <span v-if="radios" style="margin-left: -15px">
+                    <span v-if="radios && !fistRadio" style="margin-left: -15px">
                         <el-radio v-model="optionsOId" :label="item.value">
                             <span class="idxspan" style="margin-left: -10px"> 
                                 <!-- {{item.label}}  -->
@@ -147,6 +147,11 @@ export default {
         userName: {
             type: Boolean,
             default: false
+        },
+        // 第一季是否不选中
+        fistRadio: {
+            type: Boolean,
+            default: false
         }
     },
     data() {
@@ -298,36 +303,35 @@ export default {
         },
         // 点击
         liClist(item) {
-            console.log('我被你点击了')
-            if(!item.children) {
-                this.selectName = item.label
-                if(item.type) {
-                    this.selectNameType = item.type
-                }
-                let obj = {
-                    id: item.value,
-                    distinction: this.distinction
-                }
-                console.log('将要传出去的值1', obj)
-                this.$emit('vueCasader', obj)
-            }
-            if(this.radios) {
-                this.selectName = item.label
-                if(item.type) {
-                    this.selectNameType = item.type
+            if(item.label != this.$t('lable.department') && item.label != this.$t('designatedpersonnel')) {
+                if(!item.children) {
+                    this.selectName = item.label
+                    if(item.type) {
+                        this.selectNameType = item.type
+                    }
+                    let obj = {
+                        id: item.value,
+                        distinction: this.distinction
+                    }
+                    this.$emit('vueCasader', obj)
                 }
-                let obj = {
-                    id: item.value,
-                    distinction: this.distinction,
-                    item: item
+                if(this.radios) {
+                    this.selectName = item.label
+                    if(item.type) {
+                        this.selectNameType = item.type
+                    }
+                    let obj = {
+                        id: item.value,
+                        distinction: this.distinction,
+                        item: item
+                    }
+                    this.$emit('vueCasader', obj)
+                } else {
+                    this.transitionBoxLiIdx = ''
+                    this.show = !this.show
+                    this.classDiv = false
+                    this.move = false
                 }
-                console.log('将要传出去的值2', obj)
-                this.$emit('vueCasader', obj)
-            } else {
-                this.transitionBoxLiIdx = ''
-                this.show = !this.show
-                this.classDiv = false
-                this.move = false
             }
         },
         // 接受子组件传过来的值

+ 2 - 2
fhKeeper/formulahousekeeper/timesheet/src/views/awayOffice/awayOffice.vue

@@ -462,7 +462,7 @@
                     <el-form-item :label="$t('selectdepartmentsdesignatepersonnel')" >
                         <el-cascader filterable ref="deptCascader" v-model="curDeptId" :placeholder="$t('defaultText.pleaseChoose')" style="width: 100%" @change="chooseDept" v-if="user.userNameNeedTranslate != 1" :options="soption" :props="{ checkStrictly: true,expandTrigger: 'hover' }" :show-all-levels="false" clearable></el-cascader>
                         <!-- <vueCascader :size="'small'" :widthStr="'200'" :clearable="true" :subjectId="this.selectedAuuid" :subject="soption" :radios="true" :distinction="'1'" @vueCasader="vueCasader" v-if="user.userNameNeedTranslate == 1"></vueCascader> -->
-                        <vueCascader :size="'small'" :widthStr="'200'" :clearable="true" :userName="true" :subjectId="this.selectedAuuid" :subject="soption" :radios="true" :distinction="'1'" @vueCasader="vueCasader" v-if="user.userNameNeedTranslate == 1"></vueCascader>
+                        <vueCascader :size="'small'" :widthStr="'200'" :clearable="true" :fistRadio="true" :userName="true" :subjectId="this.selectedAuuid" :subject="soption" :radios="true" :distinction="'1'" @vueCasader="vueCasader" v-if="user.userNameNeedTranslate == 1"></vueCascader>
                     </el-form-item>
                 </el-form>
                 <div slot="footer" class="dialog-footer">
@@ -1918,7 +1918,7 @@ export default {
                     nodes = {userId: node.value, userName: node.label, auditorType: 2};
                   }
                 } else {
-                  if(node.managerId) {
+                  if(node.type == 'dep') {
                     nodes = {auditDeptId: node.value, auditDeptName: node.label, auditorType: 1};
                   } else {
                     nodes = {userId: node.value, userName: node.label, auditorType: 2};

+ 4 - 32
fhKeeper/formulahousekeeper/timesheet/src/views/leave/list.vue

@@ -430,6 +430,7 @@
                     <icon class="iconfont firerock-iconInsertLine addNode" @click="showNodeDialog(0)"></icon>
                     <icon class="iconfont firerock-iconright"></icon>
                     <span v-for="(item, index) in dataArray" :key="item.seq" >
+
                         <el-button type="primary" v-if="item.auditorType == 1 && user.userNameNeedTranslate == 1" @click="editNodeDialog(index, item)">
                           <!-- {{item.auditDeptName}} -->
                           <ww-open-data type='departmentName' :openid='item.auditDeptName'></ww-open-data>
@@ -438,6 +439,7 @@
                           <!-- {{item.userName}} -->
                             <ww-open-data type='userName' :openid='item.userName'></ww-open-data>
                         </el-button>
+
                         <el-button type="primary" v-if="item.auditorType == 1 && user.userNameNeedTranslate != 1" @click="editNodeDialog(index, item)">
                           {{item.auditDeptName}}
                         </el-button>
@@ -472,7 +474,7 @@
                   <el-cascader filterable ref="deptCascader"  v-model="curDeptId" :placeholder="$t('defaultText.pleaseChoose')" style="width: 100%" @change="chooseDept"
                     :options="soption" :props="{ checkStrictly: true,expandTrigger: 'hover' }" :show-all-levels="false" clearable v-show="user.userNameNeedTranslate != 1"></el-cascader>
 
-                  <vueCascader :size="'small'" :widthStr="'200'" :clearable="true" :userName="true" :subjectId="this.selectedAuuid" :subject="soption" :radios="true" :distinction="'1'" @vueCasader="vueCasader" v-if="user.userNameNeedTranslate == 1"></vueCascader>
+                    <vueCascader :size="'small'" :widthStr="'200'" :clearable="true" :userName="true" :fistRadio="true" :subjectId="this.selectedAuuid" :subject="soption" :radios="true" :distinction="'1'" @vueCasader="vueCasader" v-if="user.userNameNeedTranslate == 1"></vueCascader>
 
               </el-form-item>
               </el-form>
@@ -953,7 +955,6 @@ export default {
       this.getUsers() // 获取人员信息
       this.getDepartment();
       this.getAl();
-      this.getApproverList();
       this.getAuditWorkflow();
     }
   },
@@ -1207,35 +1208,6 @@ export default {
       this.getVacationList(1)
     },
 
-
-
-
-    getApproverList(){
-      this.http.post('/project/getMyParticiPMList',{
-      },res => {
-        if(res.code == 'ok'){
-          this.approverList = res.data
-          if(this.approverList.length == 0){
-            this.$message({
-              message: this.$t('configureanapprover'),
-              type: 'warning'
-            })
-          }
-          // console.log('list',res.data);
-        }else {
-          this.$message({
-            message: res.msg,
-            type: 'error'
-          })
-        }
-      },error => {
-        this.$message({
-          message: error,
-          type: 'error'
-        })
-      })
-    },
-
     changeAltime(e){
       if(e == 0 && this.AlchangeP.length == 0){
           this.$message(this.$t('selecttheitemsyouwanttobatchset'))
@@ -1482,7 +1454,7 @@ export default {
                     nodes = {userId: node.value, userName: node.label, auditorType: 2};
                   }
                 } else {
-                  if(node.managerId) {
+                  if(node.type == 'dep') {
                     nodes = {auditDeptId: node.value, auditDeptName: node.label, auditorType: 1};
                   } else {
                     nodes = {userId: node.value, userName: node.label, auditorType: 2};

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

@@ -652,7 +652,10 @@
                                                 {{$t('dai-fen-pei')}}
                                             </span>
                                             <span v-else>
-                                                <ww-open-data type='userName' :openid='scope.row.executorName'></ww-open-data>
+                                                <span v-for="item,index in scope.row.executorName" :key="index">
+                                                    <ww-open-data type='userName' :openid='item'></ww-open-data>
+                                                    <span v-if="index < scope.row.executorName.length - 1">,</span>
+                                                </span>
                                             </span>
                                         </span>
                                     </template>
@@ -2754,6 +2757,11 @@
                 this.http.post('/task/getTask',{id: id},
                 res => {
                     if (res.code == "ok") {
+                        if(this.user.userNameNeedTranslate == 1) {
+                            for(var i in res.data.subTaskList) {
+                                res.data.subTaskList[i].executorName = res.data.subTaskList[i].executorName.split(',')
+                            }
+                        }
                         this.addForm = res.data;
                         this.addForm.createDate = null;
                         this.addForm.indate = null;