Bladeren bron

2773 人员档案优化汇总

cyy 1 jaar geleden
bovenliggende
commit
3c848f8f77

+ 4 - 3
src/views/component/personnelFile/components/modulesTag.vue

@@ -221,10 +221,11 @@ export default {
         padding: 0 20px 15px;
         background-color: #fff;
         // padding-bottom: 1%;
+
         box-shadow:
-            0 4px 2px -5px rgba(0,0,0,.0),
-            -2px 10px 15px -5px rgba(0,0,0,.1),
-            2px 10px 15px -5px rgba(0,0,0,.1);
+            0px 6px 8px -6px rgba(255,0255,255,1),
+            -6px 6px 8px -6px rgba(0,0,0,.1),
+            6px 6px 8px -6px rgba(0,0,0,.1);
         border-radius: 0 0 4px 4px;
     }
     ::v-deep .el-tabs__item.is-active{

+ 37 - 6
src/views/component/personnelFile/components/personnelInfo.vue

@@ -30,7 +30,7 @@
                         <el-button v-if="buttonType===3" type="primary" icon="ibps-icon-check-square-o" @click="changeButton('sendBack')">退回</el-button>
                         <el-button v-if="buttonType===0&&buttonShow===true" type="primary" icon="el-icon-edit-outline" @click="changeButtonShow(false,'edit')">编辑</el-button>
                         <el-button v-if="buttonType===0&&buttonShow===false" type="warning" icon="el-icon-switch-button" @click="changeButtonShow(true,'exitEdit')">退出编辑</el-button>
-                        <el-button v-if="type==='dialog'||buttonType===3||buttonType===4" type="danger" icon="el-icon-close" autofocus @click="showSubmit()">关闭</el-button>
+                        <el-button v-if="type==='dialog'||buttonType===3||buttonType===4 || ($parent.$attrs&&$parent.$attrs.params&&$parent.$attrs.params.instanceId)" type="danger" icon="el-icon-close" autofocus @click="showSubmit()">关闭</el-button>
                     </div>
                 </div>
                 <div class="contentFooter">
@@ -67,9 +67,12 @@
                         </el-col>
                         <el-col :span="8" class="contentFooterC">
                             <p>岗位:</p>
-                            <div v-if="typeof userList.find(t => t.userId === submitperInfoData.id) != 'undefined'" class="posSty">
+                            <div v-if="typeof userList.find(t => t.userId === submitperInfoData.id) != 'undefined'" ref="posBox" class="posSty">
                                 <el-tag v-for="(item,i) in userList.find(t => t.userId === submitperInfoData.id).roles.split(',')" :key="i" class="interspaceTag" size="mini">{{ item }}</el-tag>
                             </div>
+                            <el-tooltip v-if="moreShow&&typeof userList.find(t => t.userId === submitperInfoData.id) != 'undefined'" class="item" effect="dark" :content="getContent(userList.find(t => t.userId === submitperInfoData.id).roles.split(','))" placement="bottom-end">
+                                <el-button id="resetFormButton" type="primary" icon="el-icon-more" size="mini" circle plain @click="clickHandler" />
+                            </el-tooltip>
                         </el-col>
                     </el-row>
                 </div>
@@ -121,7 +124,8 @@ export default {
             userList,
             submitperInfoData: {},
             buttonShow: true,
-            flowDiagramVisible: false
+            flowDiagramVisible: false,
+            moreShow: false
         }
     },
     watch: {
@@ -143,13 +147,22 @@ export default {
             immediate: true
         }
     },
+    mounted () {
+        setTimeout(() => {
+            this.handleResize()
+        }, 1000)
+        // window.addEventListener('resize', this.handleResize)
+    },
+    beforeDestroy () {
+        // window.removeEventListener('resize', this.handleResize)
+    },
     methods: {
         getPhoto (photo) {
             return getFile(photo)
         },
         showSubmit () {
-            // console.log(this, '222222222222')
             this.$emit('showTF', false)
+            // window.removeEventListener('resize', this.handleResize)
         },
         changeButtonShow (val, name) {
             if (this.$parent.userId !== '') {
@@ -183,7 +196,6 @@ export default {
             }
         },
         changeButton (val) {
-            console.log(val, 'aaaaaaaaaaaaaaaaaaaaa')
             this.$emit('changeBtn', val, this.submitperInfoData)
             setTimeout(() => {
                 this.$emit('changeBtn', '', {})
@@ -199,6 +211,20 @@ export default {
         },
         errorHandler () {
             return true
+        },
+        clickHandler () {
+            document.getElementById('resetFormButton').blur()
+        },
+        getContent (val) {
+            return val.join(',')
+        },
+        handleResize () {
+            const height = this.$refs.posBox ? this.$refs.posBox.scrollHeight : 0
+            if (height > 30) {
+                this.moreShow = true
+            } else {
+                this.moreShow = false
+            }
         }
     }
 }
@@ -277,10 +303,15 @@ export default {
                         font-size: 14px;
                     }
                     .interspaceTag{
-                        margin: 0 2px;
+                        margin: 0 2px 10px 2px;
                     }
                     .posSty{
                         width: 80%;
+                        height:24px;
+                        overflow: hidden;
+                    }
+                    .el-button--mini.is-circle{
+                        padding: 2px;
                     }
                 }
             }

+ 2 - 1
src/views/component/personnelFile/index.vue

@@ -136,6 +136,7 @@ export default {
     },
     created () {
         console.log(this)
+        this.$parent.$parent.showClose = false
         if (this.$attrs.params) {
             const sql1 = `select a.CREATE_BY_ from ibps_bpm_inst a join ibps_bpm_task_pendding b on b.proc_inst_id_=a.id_ where b.PROC_DEF_KEY_ = 'Process_08xwabfNEW' and b.task_id_ ='${this.$attrs.params.taskId}'`
             // const sql1 = `select CREATE_BY_ FROM ibps_bpm_oper_log WHERE PROC_INST_ID_ = (SELECT PROC_INST_ID_ FROM ibps_bpm_bus_rel WHERE BUSINESSKEY_ = "${this.$attrs.params.attrs.id}" LIMIT 1 )AND OPER_TYPE_ IN('start')`
@@ -177,7 +178,7 @@ export default {
             })
         },
         showTF (val) {
-            if (this.$attrs.params && this.$attrs.params.attrs.flow) {
+            if ((this.$attrs.params && this.$attrs.params.attrs.flow) || (this.$attrs.params && this.$attrs.params.instanceId)) {
                 this.$emit('close', false)
             }
             this.dialogVisible = val