Forráskód Böngészése

Merge commit '80ed52f43ea130371b816788fa8edf39650ec0ca' into HEAD

gitadmin 7 hónapja
szülő
commit
1989f56490

+ 1 - 1
public/version.json

@@ -1,4 +1,4 @@
 {
-    "version": "2.2.492",
+    "version": "2.2.493",
     "message": "发现有新版本发布,确定更新系统?"
 }

+ 6 - 13
src/views/expenseManagement/expenseReimbursement/list.vue

@@ -211,9 +211,8 @@ import verifyModal from './verifyModal.vue'
 import previewModal from './previewModal.vue'
 import commonModal from '@/views/common/commonModal.vue'
 import expenseType from '@/views/common/expenseType.js'
-import { getBatchLastProcessInstance } from '@/api/financeBook'
 import customerService from '@/views/common/customerService'
-import { expenseAccountList, expenseAccountDelete, expenseAccountAgainEdit, expenseAcctDetailFindList, expenseAccountUpdateBatch } from '@/api/expenseManagement'
+import { expenseAccountList, expenseAccountDelete, expenseAccountAgainEdit, expenseAcctDetailFindList, expenseAccountUpdateBatch, getProcessInstance } from '@/api/expenseManagement'
 import baseDataModal from './baseDataModal.vue'
 export default {
   name: 'ExpenseReimbursementList',
@@ -330,31 +329,25 @@ export default {
       // 开始打印
       this.spinning = true
       const pageData = []
-      const businessSnList = []
+      let newSpListData = []
       // 循环获取
       for (let i = 0; i < rows.length; i++) {
         // 费用明细
         const fyListData = await expenseAcctDetailFindList({ expenseAccountSn: rows[i].expenseAccountSn }).then(res => res.data)
         // 审核明细,待提交状态不获取
         if (rows[i].state != 'WAIT_SUBMIT') {
-          businessSnList.push(rows[i].expenseAccountSn)
+          // 获取审核进度信息
+          newSpListData = await getProcessInstance({ 'businessType':'EXPENSES', 'businessSn': rows[i].expenseAccountSn }).then(res => res.data[0].opinionList || [])
         }
         // 组装数据
         pageData.push({
           printRemark: this.printRemark,
           expenseInfo: rows[i],
           fyListData: fyListData,
-          spListData: []
+          spListData: newSpListData
         })
       }
-      // 获取审核进度信息
-      const spListData = await getBatchLastProcessInstance({ 'businessType': 'EXPENSES', 'businessSnList': businessSnList }).then(res => res.data)
-      pageData.map(item => {
-        if (spListData) {
-          const sp = spListData[item.expenseInfo.expenseAccountSn]
-          item.spListData = sp ? sp.taskVOList : []
-        }
-      })
+      
       // 打开预览弹框
       this.showTipModal = true
       this.$nextTick(() => {

+ 12 - 13
src/views/salesManagement/receiptPrint/list.vue

@@ -155,7 +155,8 @@ import recordModal from './recordModal.vue'
 import printModel from './printModel.vue'
 import chooseWarehouse from '@/views/common/chooseWarehouse'
 import customerService from '@/views/common/customerService'
-import { financeBookDetailList, updateFinanceBookDetail, getBatchLastProcessInstance, checkPrintStatus } from '@/api/financeBook'
+import { financeBookDetailList, updateFinanceBookDetail, checkPrintStatus } from '@/api/financeBook'
+import { getProcessInstance } from '@/api/expenseManagement'
 export default {
   name: 'ReceiptPrintList',
   mixins: [commonMixin],
@@ -305,9 +306,8 @@ export default {
       }
 
       const retArr = []
-      const auditInfo = await getBatchLastProcessInstance({ 'businessType': 'FINANCE_BOOK', 'businessSnList': bookSns }).then(res => res.data)
-      console.log(auditInfo)
-      bookSns.map(item => {
+      for (let i = 0; i < bookSns.length; i++) {
+        const item = bookSns[i]
         // 授信明细,还款明细
         const rs = rows.filter(a => a.bookSn == item)
         let detailItemUseStr = ''
@@ -320,10 +320,11 @@ export default {
             detailPayUseStr += this.getUseDetailInfo(b.detailItemPayList)
           }
         })
+        const auditInfo = await getProcessInstance({ 'businessType': 'FINANCE_BOOK', 'businessSn': item }).then(res => (res.data[0] && res.data[0].opinionList) ? res.data[0].opinionList : [])
         // 审核信息
-        const auditStr = auditInfo ? this.getAuditInfo(auditInfo[item]) : ''
+        const auditStr = auditInfo ? this.getAuditInfo(auditInfo) : ''
         retArr.push({ audit: auditStr, detail: detailItemUseStr, payDetail: detailPayUseStr, subList: rs })
-      })
+      }
       this.handlePrint(retArr, 1, rows, bookSns)
     },
     // 获取授信西悉尼
@@ -337,10 +338,10 @@ export default {
     // 获取审核信息
     getAuditInfo (auditList) {
       let auditStr = ''
-      if (auditList && auditList.taskVOList) {
-        const auditLists = auditList.taskVOList.filter(item => item.userType == '审批人')
+      if (auditList && auditList.length) {
+        const auditLists = auditList.filter(item => item.processTaskType == '审批人')
         auditLists.map((a, i) => {
-          auditStr = auditStr + a.userName + '(' + a.state + ')' + (i == auditLists.length - 1 ? ';' : ',')
+          auditStr = auditStr + a.approvalName + '(' + a.approvalStateDictValue + ')' + (i == auditLists.length - 1 ? ';' : ',')
         })
       }
       return auditStr
@@ -365,10 +366,8 @@ export default {
             return
           }
         }
-
-        auditInfo = await getBatchLastProcessInstance({ 'businessType': 'FINANCE_BOOK', 'businessSnList': [list.bookSn] }).then(res => res.data)
+        auditInfo = await getProcessInstance({ 'businessType': 'FINANCE_BOOK', 'businessSn': list.bookSn }).then(res => (res.data[0] && res.data[0].opinionList) ? res.data[0].opinionList : [])
       }
-      console.log(auditInfo)
       this.spinning = true
       this.showTipModal = true
       let detailItemUseStr = ''
@@ -382,7 +381,7 @@ export default {
           detailPayUseStr = this.getUseDetailInfo(row.detailItemPayList)
         }
         // 审核信息
-        const auditStr = auditInfo ? this.getAuditInfo(auditInfo[list.bookSn]) : ''
+        const auditStr = auditInfo ? this.getAuditInfo(auditInfo) : ''
         this.$refs.printModel.getData(type ? row : [{ audit: auditStr, detail: detailItemUseStr, payDetail: detailPayUseStr, subList: [row] }], type ? list : [list])
       })
     },

+ 10 - 10
src/views/salesManagement/salesCollection/voucherModal.vue

@@ -114,7 +114,7 @@ import printModel from '../receiptPrint/printModel.vue'
 import detailModal from '@/views/financialManagement/financialCollection/detail.vue'
 import collectDetailModal from './detailModal.vue'
 import { settleReceiptFindBySn } from '@/api/settleReceipt.js'
-import { getBatchLastProcessInstance } from '@/api/financeBook'
+import { getProcessInstance } from '@/api/expenseManagement'
 export default {
   name: 'VoucherModal',
   mixins: [commonMixin],
@@ -192,10 +192,10 @@ export default {
     // 获取审核信息
     getAuditInfo (auditList) {
       let auditStr = ''
-      if (auditList && auditList.taskVOList) {
-        const auditLists = auditList.taskVOList.filter(item => item.userType == '审批人')
+      if (auditList && auditList.length) {
+        const auditLists = auditList.filter(item => item.processTaskType == '审批人')
         auditLists.map((a, i) => {
-          auditStr = auditStr + a.userName + '(' + a.state + ')' + (i == auditLists.length - 1 ? '。' : ';')
+          auditStr = auditStr + a.approvalName + '(' + a.approvalStateDictValue + ')' + (i == auditLists.length - 1 ? '。' : ';')
         })
       }
       return auditStr
@@ -216,10 +216,9 @@ export default {
         }
       })
       const retArr = []
-      const auditInfo = await getBatchLastProcessInstance({ 'businessType': 'FINANCE_BOOK', 'businessSnList': bookSns }).then(res => res.data)
-      console.log(bookSns, auditInfo)
-      bookSns.map(item => {
+      for (let i = 0; i < bookSns.length; i++) {
         // 授信明细
+        const item = bookSns[i]
         const rs = rows.filter(a => a.bookSn == item)
         let detailItemUseStr = ''
         rs.map(b => {
@@ -229,11 +228,12 @@ export default {
             })
           }
         })
+        const auditInfo = await getProcessInstance({ 'businessType': 'FINANCE_BOOK', 'businessSn': item }).then(res => (res.data[0] && res.data[0].opinionList) ? res.data[0].opinionList : [])
         // 审核信息
-        const auditStr = this.getAuditInfo(auditInfo[item])
+        const auditStr = this.getAuditInfo(auditInfo)
         retArr.push({ audit: auditStr, detail: detailItemUseStr, subList: rs })
-      })
-      console.log(retArr, '------------')
+      }
+
       if (retArr.length) {
         this.handlePrint(retArr, rows)
       } else {