Selaa lähdekoodia

Merge branch 'develop_yh63' of http://git.chelingzhu.com/jianguan-web/jg-ocs-html into develop_yh64

lilei 1 päivä sitten
vanhempi
commit
dc5f4027a9

+ 12 - 0
src/api/verifyAccountChange.js

@@ -153,4 +153,16 @@ export const verifyAccountChangeExport = (params) => {
       'module': encodeURIComponent('人工录入单导出')
     }
   })
+}
+
+// 查询被引用单据
+export const verifyAccountChangeDeleteValid = (params) => {
+  return axios({
+    url: `/verifyAccountChange/deleteValid/${params.sn}`,
+    data: params,
+    method: 'post',
+    headers: {
+      'module': encodeURIComponent('人工录入单查询被引用对账单')
+    }
+  })
 }

+ 5 - 3
src/views/financialManagement/manualEntryForm/list.vue

@@ -133,7 +133,7 @@ import rangeDate from '@/views/common/rangeDate.vue'
 import baseModal from './baseModal.vue'
 import verifyModal from './verifyModal.vue'
 import chooseDepartUserModal from './chooseDepartUserModal.vue'
-import { verifyAccountChangeList, verifyAcountBillSubmit, verifyAccountChangeDel, verifyAccountChangeExport } from '@/api/verifyAccountChange.js'
+import { verifyAccountChangeList, verifyAcountBillSubmit, verifyAccountChangeDel, verifyAccountChangeExport, verifyAccountChangeDeleteValid } from '@/api/verifyAccountChange.js'
 export default {
   name: 'ManualEntryFormList',
   mixins: [commonMixin],
@@ -256,11 +256,13 @@ export default {
       this.itemSn = row.changeSn
     },
     // 删除
-    handleDel (row) {
+    async handleDel (row) {
       const _this = this
+      const hasDzd = await verifyAccountChangeDeleteValid({ sn: row.changeSn })
+      const str = hasDzd.data.length ? '已被对账单【' + hasDzd.data.toString() + '】引用,会同时删除该引用,' : ''
       this.$confirm({
         title: '提示(' + row.dealerName + ')',
-        content: <div style="font-size:14px;"><div>调账单号:{row.changeNo}</div><div>确定删除吗?</div></div>,
+        content: <div style="font-size:14px;"><div>调账单号:{row.changeNo}</div><div>{str}确定删除吗?</div></div>,
         centered: true,
         closable: true,
         onOk () {