Просмотр исходного кода

去除报错警告,首页待办已办新增发起人信息

cfort 3 лет назад
Родитель
Сommit
feee67fb48

+ 11 - 0
src/api/detection/jcwtd.js

@@ -62,3 +62,14 @@ export function deleteMe(data){
     params: data
   })
 }
+
+/*
+无效接口,去除引用警告
+*/
+export function remove(data){
+    return request({
+        url:JCWTD_URL + '/delete',
+        method: 'post',
+        params: data
+    })
+}

+ 1 - 1
src/views/component/normalSelect.vue

@@ -5,7 +5,7 @@
         v-model="selected"
         filterable
         :multiple="field.field_options.custom_class === 'multiple'"
-        :disabled="field.disabled" 
+        :disabled="field.disabled"
         placeholder="请选择"
     >
         <el-option

+ 4 - 2
src/views/detection/jtsjpz/list.vue

@@ -24,7 +24,8 @@
       <template slot="dsBuMenSelect">
         <el-select v-model="bianZhiBuMenId" clearable placeholder="请选择" style="width:120px">
           <el-option
-            v-for="item in buMenList"
+            v-for="(item, index) in buMenList"
+            :key="index"
             :label="item.label"
             :value="item.value"
           />
@@ -57,7 +58,8 @@
       <template slot="dsDuiXiangSelect">
         <el-select v-model="duiXiang" clearable placeholder="请选择" style="width:120px">
           <el-option
-            v-for="item in duiXiangList"
+            v-for="(item, index) in duiXiangList"
+            :key="index"
             :label="item.label"
             :value="item.value"
           />

+ 0 - 8
src/views/system/blank/index.vue

@@ -1,11 +1,3 @@
-<!--
- * @Author: error: git config user.name && git config user.email & please set dead value or install git
- * @Date: 2022-12-13 17:41:41
- * @LastEditors: error: git config user.name && git config user.email & please set dead value or install git
- * @LastEditTime: 2022-12-19 09:53:28
- * @FilePath: \lh_firm_former\src\views\system\blank\index.vue
- * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
--->
 <template>
   <div style="width: 86%;">
           <div style="font-size:32px; font-weight: bold; color:rgb(2, 188, 254); margin-top: 10%;text-align: center;">

+ 67 - 8
src/views/system/dashboard/components/new-home.vue

@@ -59,6 +59,13 @@
                                 label="任务提交人"
                             />
 
+                            <el-table-column
+                                prop="submitBy"
+                                show-overflow-tooltip
+                                width="100"
+                                label="任务发起人"
+                            />
+
                             <el-table-column
                                 show-overflow-tooltip
                                 width="145"
@@ -184,6 +191,23 @@
                                 </template>
                             </el-table-column>
 
+                            <el-table-column
+                                show-overflow-tooltip
+                                label="任务发起人"
+                                width="100"
+                            >
+                                <template slot-scope="scope">
+                                    {{ scope.row.createBy | getUserName(userList)}}
+                                </template>
+                            </el-table-column>
+
+                            <!-- <el-table-column
+                                prop="submitBy"
+                                show-overflow-tooltip
+                                width="100"
+                                label="任务发起人2"
+                            /> -->
+
                             <el-table-column
                                 show-overflow-tooltip
                                 width="145"
@@ -424,6 +448,12 @@
     export default {
         components: { BpmnFormrender, homeCalendar },
         name: 'calendar',
+        filters: {
+            getUserName (v, list) {
+                let user = list.find(i => i.id_ === v)
+                return user ? user.name_ : ''
+            }
+        },
         data() {
             return {
                 taskId: '', // 编辑dialog需要使用
@@ -463,6 +493,11 @@
         },
         mounted: function () {
             this.loadData()
+
+            let sql = `select id_, name_ from ibps_party_employee where status_ = 'actived'`
+            curdPost('sql', sql).then(res => {
+                this.userList = res.variables && res.variables.data
+            })
             if (this.timer) {
                 clearInterval(this.timer)
             }
@@ -533,9 +568,21 @@
             getWait() {
                 this.waitLoading = true
                 pending(this.getFormatParams(null, this.pagination)).then(response => {
-                    if (response.data.dataResult) {
-                        this.pendingData = response.data.dataResult
-                        this.pendingPage = response.data.pageResult
+                    let {dataResult, pageResult} = response.data
+                    if (dataResult && dataResult.length) {
+                        let instList = []
+                        dataResult.forEach(item => {
+                            instList.push(item.bpmnInstId)
+                        })
+                        let sql = `select b.bpmn_inst_id_, b.create_by_, a.name_ from ibps_bpm_inst b left join ibps_party_employee a on a.id_ = b.create_by_ where b.bpmn_inst_id_ in (${instList.join(',')}) order by find_in_set(b.bpmn_inst_id_,'${instList.join(',')}')`
+                        curdPost('sql', sql).then(res => {
+                            const data = res.variables && res.variables.data
+                            data.forEach((item, index) => {
+                                dataResult[index].submitBy = item.name_
+                            })
+                            this.pendingData = dataResult
+                            this.pendingPage = pageResult
+                        })
                     }
                     this.waitLoading = false
                 }).catch(() => {
@@ -551,9 +598,21 @@
             getOrver() {
                 this.orverLoading = true
                 handledTask(this.getFormatParams(1, this.orverPagination)).then(response => {
-                    if (response.data.dataResult.length > 0) {
-                        this.handledData = response.data.dataResult
-                        this.orverPage = response.data.pageResult
+                    let {dataResult, pageResult} = response.data
+                    if (dataResult && dataResult.length) {
+                        // let instList = []
+                        // dataResult.forEach(item => {
+                        //     instList.push(item.bpmnInstId)
+                        // })
+                        // let sql = `select b.bpmn_inst_id_, b.create_by_, a.name_ from ibps_bpm_inst b left join ibps_party_employee a on a.id_ = b.create_by_ where b.bpmn_inst_id_ in (${instList.join(',')}) order by find_in_set(b.bpmn_inst_id_,'${instList.join(',')}')`
+                        // curdPost('sql', sql).then(res => {
+                        //     const data = res.variables && res.variables.data
+                        //     data.forEach((item, index) => {
+                        //         dataResult[index].submitBy = item.name_
+                        //     })
+                        // })
+                        this.handledData = dataResult
+                        this.orverPage = pageResult
                     }
                     this.orverLoading = false
                 }).catch(() => {
@@ -563,7 +622,7 @@
             getMessage() {
                 // console.log("当前用户id",this.$store.getters.userId)
                 // console.log(this.$store)
-                console.log('当前用户信息', this.$store.getters.userInfo.employee)
+                // console.log('当前用户信息', this.$store.getters.userInfo.employee)
                 // getNews().then(response => {
                 //     this.newsData = response.data;
                 //     this.loading = false
@@ -601,7 +660,7 @@
                 let sql = "select td.*,ie.NAME_ from t_dxtz td,ibps_party_employee ie  where td.bian_zhi_ren_ = ie.id_ and  td.fa_song_fang_shi_ like  '%公告%' ORDER BY create_time_ desc"
 
                 curdPost('sql', sql).then(res => {
-                    console.log(res)
+                    // console.log(res)
                     if (res.state == 200) {
                         let dbData = res.variables.data
                         this.newsDataCms = dbData

+ 0 - 4
src/views/viewFile/index.vue

@@ -94,7 +94,3 @@ export default {
     }
 }
 </script>
-
-<style scoped>
-
-</style>