diff --git a/src/views/mtm/routepack_form.vue b/src/views/mtm/routepack_form.vue index bf566638..c100314f 100644 --- a/src/views/mtm/routepack_form.vue +++ b/src/views/mtm/routepack_form.vue @@ -302,20 +302,20 @@ export default { form.name = that.form.name; form.material = that.form.material; if (that.form.id) { - that.$API.mtm.routepack.update - .req(that.form.id, that.form) - .then((res) => { - that.routepack = res.id; - that.query.routepack = res.id; - that.apiObj = that.$API.mtm.route.list; - that.active = 1; - that.getDEGdatas(); - }); + that.$API.mtm.routepack.update.req(that.form.id, that.form).then((res) => { + that.routepack = res.id; + that.query.routepack = res.id; + that.form.material_name = res.material_name; + that.apiObj = that.$API.mtm.route.list; + that.active = 1; + that.getDEGdatas(); + }); } else { that.$API.mtm.routepack.create.req(form).then((res) => { this.active = 1; that.form.id = res.id; that.routepack = res.id; + that.form.material_name = res.material_name; }); } that.materials.forEach((item) => {