Browse Source

完善车辆销售台账--下载是确定按钮的重复点击限制

zhanglei
yunuo970428 2 years ago
parent
commit
a8d0ad96e3
  1. 11
      anrui-scm/anrui-scm-ui/src/views/cheliang/cheliangxiaoshou/cheliangxiaoshouguanli.vue

11
anrui-scm/anrui-scm-ui/src/views/cheliang/cheliangxiaoshou/cheliangxiaoshouguanli.vue

@ -204,8 +204,8 @@
</el-row>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button size="small" type="primary" @click="handleConfirm">确定</el-button>
<el-button size="small" @click="dialogVisible = false">取消</el-button>
<el-button size="small" :disabled="visibleDisabled" type="primary" @click="handleConfirm">确定</el-button>
<el-button size="small" :disabled="visibleDisabled" @click="dialogVisible = false">取消</el-button>
</span>
</el-dialog>
<chelaingxiaoshouInfo v-show="viewState == 2" ref="divInfo" @doback="resetState"/>
@ -237,6 +237,7 @@ export default {
btndisabled: false,
viewState: 1,
dialogVisible: false,
visibleDisabled: false,
printSid: '',
print: '',
btnList: [
@ -390,6 +391,7 @@ export default {
this.dialogVisible = true
},
handleConfirm() {
this.visibleDisabled = true
createPdf({ xsckdSid: this.printSid, printerType: this.print }).then((resp) => {
if (resp.success && resp.data.pdfPath !== '') {
var xhr = new XMLHttpRequest()
@ -414,7 +416,12 @@ export default {
xhr.send()
this.dialogVisible = false
this.printSid = ''
this.visibleDisabled = false
} else {
this.visibleDisabled = false
}
}).catch(() => {
this.visibleDisabled = false
})
},
toInfo(row) {

Loading…
Cancel
Save