diff --git a/src/views/basic-dictionary/BirthPlace.vue b/src/views/basic-dictionary/BirthPlace.vue index 54d3467..dbacd29 100644 --- a/src/views/basic-dictionary/BirthPlace.vue +++ b/src/views/basic-dictionary/BirthPlace.vue @@ -94,7 +94,7 @@ > - { @@ -420,15 +424,26 @@ export default { //新增弹框 add() { - this.form = { ...this.curRow }; + this.dialogVisible = true; this.title = 1; this.form = {}; + this.resetFields(); + this.getFocus(); + }, + + getFocus(){ this.$nextTick(() => { this.$refs.refinput.focus(); - }); + }); + }, + + resetFields(){ + this.$nextTick(() => { + this.$refs.form.resetFields(); + }); }, - // + getlist() { nativeplacelist(this.pages).then((res) => { this.initTableData = [...res.data.items];