Browse Source

feat: [模板] 签名组件cancal事件

lkf
memorylkf 3 months ago
parent
commit
6393c9315d
1 changed files with 9 additions and 1 deletions
  1. +9
    -1
      src/views/business/comps/template/dialog/EditSign.vue

+ 9
- 1
src/views/business/comps/template/dialog/EditSign.vue View File

@ -1,7 +1,7 @@
<template>
<div>
<!-- 签名弹窗 -->
<el-dialog :close-on-click-modal="false" :close-on-press-escape="false" :title="title" :visible.sync="open" width="500px" append-to-body>
<el-dialog :close-on-click-modal="false" :close-on-press-escape="false" :title="title" :visible.sync="open" width="500px" @close="close" append-to-body>
<el-form ref="formEditSignForm" :model="form" :rules="rules" label-width="120px">
<el-row>
<el-col :span="24">
@ -67,6 +67,7 @@ export default {
qmrMcEn:'',
qmrmm:'',
},
isChecked:false,
rules: {
qmrmm: [{
required: true,
@ -95,17 +96,24 @@ export default {
qmrMcEn:this.$store.getters.name,
qmrmm:'',
}
this.isChecked = false
this.resetForm("formEditSignForm")
this.open = true
},
cancel() {
this.open = false
},
close(){
if(!this.isChecked){
this.$emit('cancel')
}
},
save() {
this.$refs["formEditSignForm"].validate(valid => {
if (valid) {
this.$modal.loading()
public_checkPassword(this.form).then(response => {
this.isChecked = true
this.$emit('callback',this.form)
this.open = false
}).catch(()=>{

Loading…
Cancel
Save