lilei %!s(int64=2) %!d(string=hai) anos
pai
achega
37068e293c

+ 8 - 3
src/libs/JGPrint.js

@@ -168,10 +168,15 @@ export const jGPlPrint = function (data, type, callback, printLogParams, orginDa
   LODOP.On_Return = function (TaskID, Value) {
     console.log(TaskID, Value)
     // 已打印
-    if (Value && printLogParams) {
-      console.log('已打印,统计打印次数')
-      printLog(printLogParams, callback)
+    if (Value) {
+      if(printLogParams){
+        console.log('已打印,统计打印次数')
+        printLog(printLogParams, callback)
+      }else{
+        callback({status:200,message:'已打印'})
+      }
     } else {
+      // 取消打印
       callback()
     }
   }

+ 18 - 4
src/views/expenseManagement/expenseReimbursement/list.vue

@@ -252,10 +252,24 @@ export default {
     rowSelectionFun (obj) {
       this.rowSelectionInfo = obj || null
     },
-    printOk(res){
-      this.spinning = false
-      if(res&&res.status == 200){
-        this.$refs.table.refresh()
+    printOk(data){
+      if(data&&data.status == 200){
+        const rows = this.rowSelectionInfo && this.rowSelectionInfo.selectedRows || []
+        const ret = []
+        rows.map(item => {
+          ret.push({
+            id: item.id,
+            printStatus:"PASS"
+          })
+        })
+        expenseAccountUpdateBatch(ret).then(res => {
+          if(res.status == 200){
+            this.$refs.table.refresh()
+          }
+          this.spinning = false
+        })
+      }else{
+        this.spinning = false
       }
     },
     // 批量打印