Parcourir la source

Merge branch 'master' of http://47.108.172.52:3000/dayou/item-management-web

GouGengquan il y a 1 an
Parent
commit
33360541d8

+ 6 - 4
src/router/urlMap.js

@@ -117,7 +117,8 @@ import _views_administration_major_declare_check_list from '@/views/administrati
 import _views_administration_major_declare_check from '@/views/administration/major/declareDetail'
 import _views_finance_real_fund_claim from '@/views/finance/fundClaim'
 import _views_income_assets_declare_evaluate from '@/views/income/assets/evaluate'
-import _views_income_assets_declare_check from '@/views/income/assets/checkList'
+import _views_administration_assets_declare_check_list from '@/views/administration/assets/checkList'
+import _views_administration_assets_declare_check from '@/views/administration/assets/declareDetail'
 import _views_income_assets_declare_detail from '@/views/income/assets/declareDetail'
 import _views_income_assets_declare_market from '@/views/income/assets/market'
 import _views_finance_fund_warning from '@/views/finance/fundWarning'
@@ -236,8 +237,6 @@ export default {
   _views_administration_major_declare_check,
   _views_finance_real_fund_claim,
   _views_income_assets_declare_evaluate,
-  _views_income_assets_declare_check,
-  _views_income_assets_declare_detail,
   _views_income_assets_declare_market,
   _views_finance_fund_warning,
   _views_finance_settle_major,
@@ -248,6 +247,9 @@ export default {
   _views_finance_assets_commission_calculate,
   _views_finance_settle_assets,
   _views_assets_department_todo_list,
-  _views_assets_department_done_list
+  _views_assets_department_done_list,
+  _views_administration_assets_declare_check_list,
+  _views_administration_assets_declare_check,
+  _views_income_assets_declare_detail
 
 }

src/views/income/assets/checkList.vue → src/views/administration/assets/checkList.vue


+ 321 - 0
src/views/administration/assets/declareDetail.vue

@@ -0,0 +1,321 @@
+<template>
+  <div class="app-container">
+    <div class="title-container">
+      <breadcrumb id="breadcrumb-container" class="breadcrumb-container" />
+    </div>
+    <el-collapse v-model="activeNames" style="margin-top: 30px;">
+      <el-collapse-item name="board">
+        <template slot="title">
+          <span style="font-size:15px; margin-left:15px;letter-spacing:2px; color:RGB(168,168,168)">
+            点击展开查看实时流程图
+          </span>
+        </template>
+        <WorkflowBoard ref='board' :nodeBusinessInfo="nodeBusinessInfo" />
+      </el-collapse-item>
+    </el-collapse>
+    <div class="button-area">
+      <el-button v-if="nodeBusinessInfo.currentNodePermission.commit && doWorkflow" class="y-save" type="success" round
+        @click="commit('PASS')">通过</el-button>
+      <el-button v-if="nodeBusinessInfo.currentNodePermission.terminable && doWorkflow" class="y-save" type="danger" round
+        @click="commit('TERMINATE')">拒绝</el-button>
+      <el-button class="y-save" round type="info" @click="goBack">返回</el-button>
+    </div>
+    <el-card>
+      <el-divider content-position="left">
+        <span style="color:red;font-weight: bold;">
+          【{{ this.nodeBusinessInfo.mainBusiness === 'COMMISSION_DECLARE_ASSET_EVALUATE' ? '评估人员' : '市场人员' }}】
+        </span>资产业务提成申报详情</el-divider>
+      <el-form :model="declareForm" ref="declareForm">
+        <el-row>
+          <el-col :xs="24" :sm="12" :lg="24" :span="6">
+            <el-form-item label="项目名称:" prop="name" label-width="140px" class="postInfo-container-item">
+              <el-input :value="declareForm.name" :step="1" :max="100" style="width: 100%;" readonly disabled></el-input>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row>
+          <el-col :xs="24" :sm="12" :lg="12" :span="6">
+            <el-form-item label="订单号:" prop="orderId" label-width="140px" class="postInfo-container-item">
+              <el-input :value="declareForm.orderId" :step="1" :max="100" style="width: 100%;" readonly
+                disabled></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="12" :lg="12" :span="6">
+            <el-form-item label="报告号:" prop="reportNo" label-width="140px" class="postInfo-container-item">
+              <el-input :value="declareForm.reportNo" :step="1" :max="100" style="width: 100%;" readonly
+                disabled></el-input>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row>
+          <el-col :xs="24" :sm="12" :lg="12" :span="6">
+            <el-form-item label="业务分类:" prop="businessCate" label-width="140px" class="postInfo-container-item">
+              <el-input :value="declareForm.businessCate" :step="1" :max="100" style="width: 100%;" readonly
+                disabled></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="12" :lg="12" :span="6">
+            <el-form-item label="产品类型:" prop="production" label-width="140px" class="postInfo-container-item">
+              <el-input :value="prod" :step="1" :max="100" style="width: 100%;" readonly disabled></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="12" :lg="12" :span="6"
+            v-if="declareForm.businessType === 'COMMISSION_DECLARE_ASSET_EVALUATE'">
+            <el-form-item label="提成比例:" prop="ratio" label-width="140px" class="postInfo-container-item">
+              <el-input v-model="declareForm.ratio" type="number"
+                :disabled="declareForm.businessType !== 'COMMISSION_DECLARE_ASSET_EVALUATE' || nodeBusinessInfo.nodeCode !== 'DEPARTMENT_LEADER_CHECK' || !couldEdit">
+                <template #suffix>
+                  %
+                </template>
+              </el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="12" :lg="12" :span="6"
+            v-if="declareForm.businessType === 'COMMISSION_DECLARE_ASSET_EVALUATE'">
+            <el-form-item label="提成下限:" prop="definedLowLimitAmount" label-width="180px" class="postInfo-container-item">
+              <el-input v-model="declareForm.definedLowLimitAmount" type="number"
+                :disabled="declareForm.businessType !== 'COMMISSION_DECLARE_ASSET_EVALUATE' || nodeBusinessInfo.nodeCode !== 'DEPARTMENT_LEADER_CHECK' || !couldEdit">
+                <template #suffix>
+                  元
+                </template>
+              </el-input>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row>
+          <el-col :xs="24" :sm="12" :lg="12" :span="6">
+            <el-form-item label="申报人:" prop="declareUser" label-width="140px" class="postInfo-container-item">
+              <el-input :value="declareForm.declareUser" style="width: 100%;" readonly disabled>
+              </el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="12" :lg="12" :span="6">
+            <el-form-item label="申报日期:" prop="created" label-width="140px" class="postInfo-container-item">
+              <el-input :value="declareForm.created" style="width: 100%;" readonly disabled></el-input>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row>
+          <el-col :xs="24" :sm="12" :lg="12" :span="6">
+            <el-form-item label="审核状态:" prop="declareResult" label-width="140px" class="postInfo-container-item">
+              <el-input :value="declareForm.declareResult" readonly disabled>
+              </el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="12" :lg="12" :span="6">
+            <el-form-item label="审核备注:" prop="remarks" label-width="140px" class="postInfo-container-item">
+              <el-input :value="declareForm.remarks + ''" style="width: 100%; color: red;" readonly disabled></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="12" :lg="12" :span="6"
+            v-if="declareForm.businessType === 'COMMISSION_DECLARE_ASSET_EVALUATE' && nodeBusinessInfo.nodeCode === 'DEPARTMENT_LEADER_CHECK' && couldEdit">
+            <el-button @click="updateAssetsCommissionDeclare()" style="margin-left: 30px;" type="danger" round>
+              修改提成比例与下限
+            </el-button>
+          </el-col>
+        </el-row>
+        <el-table :data="declareForm.userShareRates" border style="width: 100%; margin-top: 10px; margin-bottom: 10px;">
+          <el-table-column prop="userId"
+            :label="this.nodeBusinessInfo.mainBusiness === 'COMMISSION_DECLARE_ASSET_EVALUATE' ? '评估人员' : '市场人员'"
+            align="center">
+            <template slot-scope="{row}">
+              <span>{{ row.name }}</span>
+            </template>
+          </el-table-column>
+          <el-table-column prop="rate" label="提成比例" align="center">
+            <template slot-scope="{row}">
+              <span style="color: red;">{{ row.rate }}%</span>
+            </template>
+          </el-table-column>
+          <el-table-column v-if="declareForm.businessType === 'COMMISSION_DECLARE_ASSET_EVALUATE'" prop="rate"
+            label="参与时长" align="center">
+            <template slot-scope="{row}">
+              <span style="color: red;">{{ row.participationDuration }}小时</span>
+            </template>
+          </el-table-column>
+          <el-table-column prop="rate" label="成员类型" align="center">
+            <template slot-scope="{row}">
+              <span>{{ row.memberType }}</span>
+            </template>
+          </el-table-column>
+        </el-table>
+      </el-form>
+    </el-card>
+  </div>
+</template>
+<script>
+import Breadcrumb from '@/components/Breadcrumb'
+import WorkflowBoard from '@/components/workflowBoard'
+
+
+export default {
+  name: 'declareDetail',
+  components: {
+    Breadcrumb,
+    WorkflowBoard
+  },
+  filters: {
+
+  },
+  computed: {
+    prod() {
+      if (this.declareForm.production === 'REPORT') {
+        return "评估报告";
+      }
+      if (this.declareForm.production === 'LETTER') {
+        return "意见函";
+      }
+      if (this.declareForm.production === 'CONSULT') {
+        return "咨询报告";
+      }
+    }
+  },
+  data() {
+    return {
+      activeNames: ['board'],
+      couldEdit: true,
+      nodeBusinessInfo: {
+        currentNodePermission: {
+          commit: true,
+          reversible: true,
+          restartable: true,
+          terminable: true,
+          skippable: true,
+        },
+        mainBusiness: null,
+        doWorkflow: null,
+        businessSubId: null,
+        businessId: null,
+        currentInstanceNodeId: null,
+        production: [],
+        nodeCode: null
+      },
+      doWorkflow: false,
+      declareForm: {
+        orderId: null,
+        name: null,
+        reportNo: null,
+        businessId: null,
+        productionId: null,
+        businessType: null,
+        commissionRateId: null,
+        ratio: null,
+        definedLowLimitAmount: null,
+        userShareRates: [
+          {
+            userId: this.$store.getters.userInfo.id,
+            rate: 100
+          }
+        ],
+        production: null,
+        remarks: []
+
+      },
+      users: [],
+      cates: [],
+      currentNode: {
+        flowId: null,
+        pnodeId: null,
+        nodeId: null,
+        flowCode: null,
+        nodeName: "",
+        nodeCode: null,
+        state: "",
+        instanceId: null,
+        sequence: null,
+        restartable: null,
+        reversible: null,
+        skippable: null,
+        terminable: null,
+        tasks: []
+      }
+    }
+  },
+  created() {
+    this.couldEdit = this.$route.query.couldEdit === 'true';
+    this.nodeBusinessInfo.businessId = this.$route.query.businessId;
+    this.nodeBusinessInfo.mainBusiness = this.$route.query.businessType;
+    this.declareForm.businessType = this.$route.query.businessType;
+    this.doWorkflow = this.$route.query.doWorkflow === 'true';
+    this.getCurrentNodeInfo();
+    this.businessId = this.$route.query.businessId;
+    this.getDeclareDetail();
+  },
+  methods: {
+    getCurrentNodeInfo() {
+      if (this.nodeBusinessInfo.businessId) {
+        this.$api.workNodeInstance.currentNode({
+          "mainBusiness": this.nodeBusinessInfo.mainBusiness,
+          "businessId": this.nodeBusinessInfo.businessId
+        }).then(res => {
+          if (res.code === 200 && res.data != null) {
+            this.currentNode = res.data;
+            this.nodeBusinessInfo.currentInstanceNodeId = res.data.instanceId;
+            this.nodeBusinessInfo.nodeCode = res.data.nodeCode;
+          }
+          this.$refs.board.getInstanceArray(this.nodeBusinessInfo.mainBusiness, this.nodeBusinessInfo.businessId);
+        })
+      }
+    },
+    goBack() {
+      const back = this.$route.query.back
+      if (back) {
+        this.$router.push(back)
+      }
+    },
+    getSimpleAllUser() {
+      this.$api.user.simpleAll().then(res => {
+        if (res.code === 200) {
+          this.users = res.data;
+        }
+      })
+    },
+    getDeclareDetail() {
+      this.$api.commissonDeclare.detail(this.businessId).then(res => {
+        if (res.code === 200) {
+          this.declareForm = res.data;
+          this.declareForm.businessType = res.data.declareBusinessType;
+        }
+      })
+    },
+    //提交节点
+    commit(state) {
+      this.$refs.board.commit(state);
+    },
+    updateAssetsCommissionDeclare() {
+      let declareDTO = new Object();
+      declareDTO.id = this.businessId;
+      declareDTO.ratio = this.declareForm.ratio;
+      declareDTO.definedLowLimitAmount = this.declareForm.definedLowLimitAmount;
+      declareDTO.recordId = this.currentNode.tasks[0].recordId;
+      this.$api.commissonDeclare.updateAssetsCommissionDeclare(declareDTO).then(res => {
+        if (res.code === 200 && res.data) {
+          this.$notify({
+            title: '成功',
+            message: '提成比例与下限信息更新成功!',
+            type: 'success',
+            duration: 3000
+          });
+          this.getAssetsDetailById(this.pageParams.row.assetsId);
+        } else {
+          this.$notify({
+            title: '失败',
+            message: '提成比例与下限信息更新失败!请稍后重试!',
+            type: 'warning',
+            duration: 3000
+          });
+        }
+      })
+    }
+  },
+
+}
+</script>
+<style lang="scss" scoped>
+.button-area {
+  position: absolute;
+  top: 70px;
+  right: 50px;
+}
+</style>
+  

+ 48 - 25
src/views/complex/index.vue

@@ -168,7 +168,7 @@
               </svg>
               <div class="icon-word">财务模块</div>
             </div>
-            <div class="icon-area" v-if="meunNames.includes('大中型行政审批')" @click="jumpDir('/income/major/declare/check')">
+            <div class="icon-area" v-if="meunNames.includes('行政审批')" @click="jumpDir('/administration')">
               <svg t="1716175649139" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"
                 p-id="2070" width="48" height="48">
                 <path
@@ -274,7 +274,7 @@
       <el-card class="left-buttom-card" shadow="always">
         <el-button style="z-index: 10;position: absolute; right: 3%;" type="text" @click="todoReflush()">刷新一下<i
             class="el-icon-refresh-right el-icon--right"></i></el-button>
-        <el-tabs v-model="activeName" @tab-click="handleClick">
+        <el-tabs v-model="maxTagKey" @tab-click="handleClick">
           <el-tab-pane name="major" v-if="meunNames.includes('大中型业务')">
             <span slot="label">大中型待办({{ majorTodoTotal }})</span>
             <div v-if="majorTodoList.length > 0">
@@ -576,8 +576,8 @@
                 description="太棒了!暂无任务需要处理。"></el-empty>
             </div>
           </el-tab-pane>
-          <el-tab-pane name="majorCheck" v-if="meunNames.includes('大中型行政审批')">
-            <span slot="label">大中型审批({{ majorDeclareCheckNum }})</span>
+          <el-tab-pane name="majorCheck" v-if="meunNames.includes('行政审批') && ifMajorDeclareCheck">
+            <span slot="label">大中型提成申报审批({{ majorDeclareCheckNum }})</span>
             <div v-if="majorDeclareCheckList.length > 0">
               <div style="margin-top: 1%; margin-bottom: 2%;">
                 <svg t="1713513294985" class="icon" viewBox="0 0 1024 1024" version="1.1"
@@ -588,7 +588,7 @@
                 </svg>
                 <span style="color: #e16531;margin-left: 3px;">您有{{ majorDeclareCheckNum }}条待处理任务</span>
                 <el-button type="text" style="position: absolute; right:0.5%; top: 0;"
-                  @click="goToTodoPage('/income/major/declare/check')">查看更多<i
+                  @click="goToTodoPage('/administration/major/declare/check/list')">查看更多<i
                     class="el-icon-arrow-right el-icon--right"></i></el-button>
               </div>
               <div class="left-content">
@@ -667,8 +667,8 @@
                 description="太棒了!暂无任务需要处理。"></el-empty>
             </div>
           </el-tab-pane>
-          <el-tab-pane name="assetsDeclareCheckList" v-if="meunNames.includes('资产绩效工资')">
-            <span slot="label">资产绩效提成审批({{ assetsDeclareCheckNum }})</span>
+          <el-tab-pane name="assetsDeclareCheckList" v-if="meunNames.includes('行政审批') && ifAssetsDeclareCheck">
+            <span slot="label">资产提成申报审批({{ assetsDeclareCheckNum }})</span>
             <div v-if="assetsDeclareCheckList.length > 0">
               <div style="margin-top: 1%; margin-bottom: 2%;">
                 <svg t="1713513294985" class="icon" viewBox="0 0 1024 1024" version="1.1"
@@ -679,7 +679,7 @@
                 </svg>
                 <span style="color: #e16531;margin-left: 3px;">您有{{ assetsDeclareCheckNum }}条待处理任务</span>
                 <el-button type="text" style="position: absolute; right:0.5%; top: 0;"
-                  @click="goToTodoPage('/income/assets/declare/check')">查看更多<i
+                  @click="goToTodoPage('/administration/assets/declare/check/list')">查看更多<i
                     class="el-icon-arrow-right el-icon--right"></i></el-button>
               </div>
               <div class="left-content">
@@ -790,6 +790,9 @@ export default {
       keyword: null,
       searchResults: [],
       hasOpenBar: false,
+      ifMajorDeclareCheck:false,
+      ifAssetsDeclareCheck:false,
+      maxTagKey: null
     }
   },
   computed: {
@@ -797,32 +800,36 @@ export default {
       'permission_menus',
       'userInfo'
     ]),
-    activeName: {
-      get() {
-        const maxTodo = new Map();
-        maxTodo.set("major", this.majorTodoTotal);
-        maxTodo.set("personal", this.personalTodoTotal);
-        maxTodo.set("assets", this.assetsTodoTotal);
-        maxTodo.set("majorCheck", this.majorDeclareCheckNum);
-        maxTodo.set("assetsDeclareCheckList", this.assetsDeclareCheckNum);
-        let maxKey = [...maxTodo.entries()].reduce((maxKey, [key, value]) => {
-          return maxKey && maxTodo.get(maxKey) > value ? maxKey : key;
-        }, 0);
-        return maxKey;
-      },
-      set() { }
-
-    }
 
   },
   watch: {
+    majorTodoTotal:{
+      immediate: true,
+      handler(newv) {
+          this.getToDoMaxNum();
+      }
+    },
     permission_menus: {
       immediate: true, // immediate选项可以开启首次赋值监听
       deep: true,
       handler(newv) {
         this.meunNames = this.permission_menus.map(item => item.name);
+        const admin = this.permission_menus.filter(item => item.pcUrl === '/administration');
+        if (admin.length > 0) {
+          const adminType =admin[0].children.map(item => {
+            return item.menuCode;
+          });
+
+            if (adminType.includes('_views_administration_major_declare_check_list')) {
+              this.ifMajorDeclareCheck = true;
+            }
+            if (adminType.includes('_views_administration_assets_declare_check_list')) {
+              this.ifAssetsDeclareCheck = true;
+            }
+        }
       }
     },
+  
     keyword: {
       handler(newv) {
         if (newv) {
@@ -859,13 +866,29 @@ export default {
     this.getBusinessTotalNum();
     this.majorDeclareTodoList();
     this.assetsDeclareTodoList();
+    this.getToDoMaxNum();
   },
 
   methods: {
     handleClick(tab, event) {
     },
-
+    getToDoMaxNum(){
+        const maxTodo = new Map();
+        maxTodo.set("major", this.majorTodoTotal);
+        maxTodo.set("personal", this.personalTodoTotal);
+        maxTodo.set("assets", this.assetsTodoTotal);
+        maxTodo.set("majorCheck", this.majorDeclareCheckNum);
+        maxTodo.set("assetsDeclareCheckList", this.assetsDeclareCheckNum);
+        let maxKey = [...maxTodo.entries()].reduce((maxKey, [key, value]) => {
+          return maxKey && maxTodo.get(maxKey) > value ? maxKey : key;
+        }, 0);
+        this.maxTagKey = maxKey;
+    },
     jumpDir(path) {
+      if (path==='/administration'){
+        const admin = this.permission_menus.filter(item => item.pcUrl === path);
+        path = admin[0].children[0].pcUrl;
+      }
       this.$router.push({ path: path, query: {} });
     },
     getMajorTodoList() {