Commit 78f3f9d1 authored by dragondean@qq.com's avatar dragondean@qq.com

合并完善订单新建后重置表单

parent 1104af2a
<template>
<div class="app-container">
<el-form ref="form" :model="form" :rules="rules" label-position="left" inline :disabled="updateChannel">
<!--初始化过程中不渲染页面,利用此特性在新建订单后重新初始化表单(字典选择组件默认值)-->
<el-form v-if="!initing" ref="form" :model="form" :rules="rules" label-position="left" inline>
<el-card v-if="form.applyStatus == 1" class="mb-10">
<div slot="header" class="card-title">{{$t('以下信息修改审核中')}}</div>
<el-table :data="form.applyInfoList">
......@@ -1256,14 +1256,17 @@ export default {
// 添加的提交
createOrder(data).then(response => {
this.$modal.msgSuccess(this.$t("新增成功"));
this.initing = true
// 重置数据
this.form = {...makeDefaultFormData()}
this.routerList = []
this.addProduct()
this.$nextTick(() =>{
this.$refs.form.clearValidate()
this.$redirect('success?orderId=' + response.data)
this.initing = false
this.$nextTick(() => {
this.$refs.form.clearValidate
this.$redirect('success?orderId=' + response.data)
})
})
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment