Bladeren bron

代码提交:
1031知识分享

sunruiqi 2 jaren geleden
bovenliggende
commit
cc9e7a7669

+ 46 - 5
src/views/modules/flowable/task/NoticePageList.vue

@@ -1,8 +1,31 @@
 <template>
   <div class="page">
 
+    <el-form size="small" :inline="true"  class="query-form" ref="searchForm" :model="searchForm" @keyup.enter.native="refreshList()" @submit.native.prevent>
+      <el-form-item label="标题" prop="title">
+        <el-input v-model="searchForm.title"></el-input>
+      </el-form-item>
+      <el-form-item label="流程名称" prop="taskName">
+        <el-input v-model="searchForm.taskName"></el-input>
+      </el-form-item>
+      <el-form-item>
+        <el-button  type="primary" @click="refreshList()" size="small" icon="el-icon-search">查询</el-button>
+        <el-button @click="resetSearch()" size="small" icon="el-icon-refresh-right">重置</el-button>
+      </el-form-item>
+    </el-form>
+
       <div class="top bg-white">
-        <vxe-toolbar :refresh="{query: refreshList}" export print custom></vxe-toolbar>
+        <vxe-toolbar :refresh="{query: refreshList}" custom>
+          <template #buttons>
+            <el-button v-if="hasPermission('knowledgeShare:info:add')" type="primary" size="small" @click="add()">全部标记已读</el-button>
+            <el-button v-if="hasPermission('knowledgeShare:info:add')" type="primary"  size="small" @click="del()">标记为已读</el-button>
+          </template>
+        </vxe-toolbar>
+
+        <el-tabs v-model="type" type="card" @tab-click="handleClick">
+          <el-tab-pane :key="index" v-for="(item,index) in typeList" :label="item.value" :name="item.value" :value="item.id"></el-tab-pane>
+        </el-tabs>
+
         <div style="height: calc(100% - 80px);">
             <vxe-table
               border="inner"
@@ -29,15 +52,12 @@
                 </template>
               </vxe-column>
               <vxe-column  title="流程名称" field="taskName" > </vxe-column>
-              <vxe-column  title="当前环节" field="link" ></vxe-column>
-              <vxe-column  title="流程发起人" field="createName" ></vxe-column>
+              <vxe-column  title="流程发起人" field="createUser" ></vxe-column>
               <vxe-column
                 field="createTime"
                 title="创建时间">
               </vxe-column>
-              <vxe-column  title="通知人" field="noticeName" ></vxe-column>
               <vxe-column  title="读取状态" field="type" ></vxe-column>
-              <vxe-column  title="重复次数" field="repetitionCount" ></vxe-column>
             </vxe-table>
             <vxe-pager
               background
@@ -72,6 +92,11 @@
     data () {
       return {
         dataList: [],
+        typeList: [],
+        searchForm: {
+          title: '',
+          taskName: ''
+        },
         tablePage: {
           total: 0,
           currentPage: 1,
@@ -89,6 +114,10 @@
     created () {
       this.noticeService = new NoticeService()
       this.taskService = new TaskService()
+      this.typeList = [
+        {id: '0', value: '未读'},
+        {id: '1', value: '已读'}
+      ]
     },
     activated () {
       this.refreshList()
@@ -100,6 +129,9 @@
       // 获取数据列表
       refreshList () {
         this.loading = true
+        if (this.commonJS.isEmpty(this.searchForm.type)) {
+          this.searchForm.type = '0'
+        }
         this.noticeService.list({
           'current': this.tablePage.currentPage,
           'size': this.tablePage.pageSize,
@@ -141,6 +173,15 @@
             }
           })
         })
+      },
+      resetSearch () {
+        this.$refs.searchForm.resetFields()
+        this.refreshList()
+      },
+      handleClick (tab) {
+        const val = tab.$attrs.value
+        this.searchForm.type = val
+        this.refreshList()
       }
     }
   }

+ 4 - 4
src/views/modules/flowable/task/TaskForm.vue

@@ -533,11 +533,11 @@
               assignee: this.auditForm.assignee
             }).then(({data}) => {
               this.$message.success('提交成功')
+              this.changeBusiness()
+              this.$refs.form.close()
               // 我的通知
               let createDate = ''
               this.myNotice(data, this.procDefId, this.title, vars.userName, createDate)
-              this.changeBusiness()
-              this.$refs.form.close()
               this.$store.dispatch('tagsView/delView', {fullPath: this.$route.fullPath})
               // this.$router.push('/flowable/task/TodoList')
               // this.cc(data)
@@ -660,11 +660,11 @@
               this.inputForm.taskName = data.name
             })
             // 流程发起人
-            this.inputForm.createUser = userName
+            this.inputForm.createUser = data[0].assigneeName
             // 创建时间
             this.inputForm.createTime = data[0].histIns.endTime
             // 通知人
-            this.inputForm.noticeName = userName
+            this.inputForm.noticeName = data[0].assigneeName
             this.noticeService.addInfo(this.inputForm)
           }
         })

+ 2 - 1
src/views/modules/reimbursement/info/ReimbursementForm.vue

@@ -255,6 +255,7 @@
     watch: {
       'businessId': {
         handler (newVal) {
+          console.log('aaaaaaaaaaaaaaaaaaaaaaaaaa', this.businessId)
           if (this.businessId && this.businessId !== 'false') {
             this.init('edit', this.businessId)
           } else {
@@ -287,7 +288,7 @@
         this.visible = true
         this.loading = false
         this.$nextTick(() => {
-          if (this.formReadOnly === true) {
+          if (this.formReadOnly === true && this.businessId !== 'false') {
             method = 'view'
           }
           if (method === 'edit' || method === 'view') { // 修改或者查看