fix:工艺步骤序号自动填充
This commit is contained in:
parent
371326913e
commit
641731dceb
|
|
@ -320,6 +320,7 @@ const defaultForm = {
|
||||||
};
|
};
|
||||||
export default {
|
export default {
|
||||||
props: {
|
props: {
|
||||||
|
count: { type: Number, default : 0 },
|
||||||
routepack: { type: String, default: "" },
|
routepack: { type: String, default: "" },
|
||||||
},
|
},
|
||||||
emits: ["success", "closed"],
|
emits: ["success", "closed"],
|
||||||
|
|
@ -455,8 +456,14 @@ export default {
|
||||||
},
|
},
|
||||||
//显示
|
//显示
|
||||||
open(mode = "add") {
|
open(mode = "add") {
|
||||||
this.mode = mode;
|
let that = this;
|
||||||
this.visible = true;
|
that.mode = mode;
|
||||||
|
that.visible = true;
|
||||||
|
that.$nextTick(() => {
|
||||||
|
if(that.count){
|
||||||
|
that.form.sort = that.count+1;
|
||||||
|
}
|
||||||
|
})
|
||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
//表单注入数据
|
//表单注入数据
|
||||||
|
|
|
||||||
|
|
@ -185,6 +185,7 @@
|
||||||
<save-dialog
|
<save-dialog
|
||||||
v-if="dialog.save"
|
v-if="dialog.save"
|
||||||
ref="saveDialog"
|
ref="saveDialog"
|
||||||
|
:count = "count"
|
||||||
:routepack="routepack"
|
:routepack="routepack"
|
||||||
@success="handleSaveSuccess"
|
@success="handleSaveSuccess"
|
||||||
@closed="dialog.save = false"
|
@closed="dialog.save = false"
|
||||||
|
|
@ -337,6 +338,9 @@ export default {
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
table_add() {
|
table_add() {
|
||||||
|
let that = this;
|
||||||
|
that.count = this.$refs.tables.total;
|
||||||
|
console.log("count",that.count);
|
||||||
this.dialog.save = true;
|
this.dialog.save = true;
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.$refs.saveDialog.open("add");
|
this.$refs.saveDialog.open("add");
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue