diff --git a/src/views/inout/InvoiceRegCkeck.vue b/src/views/inout/InvoiceRegCkeck.vue index 87415b9..b9d819e 100644 --- a/src/views/inout/InvoiceRegCkeck.vue +++ b/src/views/inout/InvoiceRegCkeck.vue @@ -314,7 +314,6 @@ export default { limit: 10, startTime: null, endTime: null, - invCode: this.$store.getters.locInvCode }, corpLoading: false, @@ -601,6 +600,7 @@ export default { }, getCodeDetailLists() { + debugger this.filterQuery.invoiceEncode = this.inputQuery.invoiceEncode this.filterQuery.vueType = 'supInvoice' this.codeDetailLoading = true @@ -713,22 +713,26 @@ export default { this.$message.error('发票编码不能为空!') return } - //查询发票编码有没有重复 - checkInvoiceCode({invoiceEncode:this.inputQuery.invoiceEncode}) - .then((response) => { - if (response.code === 20000) { - this.invoiceSelectRegByOrderVisible = true - } else { + if(this.list.length==0){ + //查询发票编码有没有重复 + checkInvoiceCode({invoiceEncode:this.inputQuery.invoiceEncode}) + .then((response) => { + if (response.code === 20000) { + this.invoiceSelectRegByOrderVisible = true + } else { + this.$message.error(response.message) + } + }) + .catch((response) => { this.$message.error(response.message) - } - }) - .catch((response) => { - this.$message.error(response.message) - }) + }) + }else{ + this.invoiceSelectRegByOrderVisible = true + } }, closeAcceptDialog(){ this.invoiceSelectRegByOrderVisible = false - this.getCodeDetailLists() + this.getCodeDetailLists() }, delectSub(row){ deleteInvoiceByOrderFk({billNo:row.billNo,invoiceEncode:this.inputQuery.invoiceEncode}) @@ -787,7 +791,7 @@ export default { } if(this.curInvoice.id!=null){ this.inputQuery=this.curInvoice - this.getOrderDetail(); + this.getOrderDetail(); } } }