Explorar o código

借用详情编辑后刷新页面

qymljy %!s(int64=2) %!d(string=hai) anos
pai
achega
19e900badc

+ 7 - 2
src/HDrpManagement/toolBorrowingMag/modules/edit.vue

@@ -5,7 +5,8 @@
     :visible.sync="drawer"
     direction="rtl"
     append-to-body
-    size="80%">
+    size="80%"
+    @close="onClose">
     <div slot="title">
       <div class="flex-align-center">
         <p><span style="font-size:14px">合计:</span><span style="color:red;font-size:16px;"><b>¥&nbsp;{{tool.formatAmount(data.amount,2)}}</b></span></p>
@@ -199,7 +200,7 @@
       </div>
     </div>
     <div class="fixed__btn__panel">
-      <el-button size="small" @click="drawer = false" class="normal-btn-width">取 消</el-button>
+      <el-button size="small" @click="onClose" class="normal-btn-width">取 消</el-button>
       <el-button size="small" type="primary" @click="onSubmit" class="normal-btn-width">保存修改</el-button>
     </div>
   </el-drawer>
@@ -361,6 +362,10 @@ export default {
     },
     addMoreProduct () {
       this.setcol === 12?this.setcol = 24 : this.setcol = 12
+    },
+    onClose(){
+      this.drawer = false
+      this.$emit('onSuccess')
     }
   },
   mounted () {

+ 2 - 1
src/SDrpManagement/salerToolBorrowing/detail/index.vue

@@ -19,7 +19,7 @@
           <el-button v-if="tool.checkAuth($route.name,'submit')" :disabled="mainData.status !== '新建'"  type="primary" size="mini" @click="onSubmit('提交')">提 交</el-button>
       </div>
       <div slot="slot0" >
-        <toolList ref="tool" :data="mainData" @queryDetail="queryMainData"></toolList>
+        <toolList ref="tool" :data="mainData" @queryDetail="queryMainData" @closeTool="onEditSuccess"></toolList>
       </div>
       <div slot="slot1" >
       </div>
@@ -30,6 +30,7 @@
 <script>
 import toolList from './tabs/toolList.vue'
 import confirmDate from '../modules/confirmDate.vue'
+import {mapGetters} from "vuex";
 
 export default {
   name: "detail",

+ 7 - 3
src/SDrpManagement/salerToolBorrowing/modules/edit.vue

@@ -5,7 +5,8 @@
     :visible.sync="drawer"
     direction="rtl"
     append-to-body
-    size="80%">
+    size="80%"
+    @close="onClose">
     <div slot="title">
       <div class="flex-align-center">
         <p><span style="font-size:14px">合计:</span><span style="color:red;font-size:16px;"><b>¥&nbsp;{{tool.formatAmount(data.amount,2)}}</b></span></p>
@@ -198,7 +199,7 @@
       </div>
     </div>
     <div class="fixed__btn__panel">
-      <el-button size="small" @click="drawer = false" class="normal-btn-width">取 消</el-button>
+      <el-button size="small" @click="onClose" class="normal-btn-width">取 消</el-button>
       <el-button size="small" type="primary" @click="onSubmit" class="normal-btn-width">保存修改</el-button>
     </div>
   </el-drawer>
@@ -361,7 +362,10 @@ export default {
     addMoreProduct () {
       this.setcol === 12?this.setcol = 24 : this.setcol = 12
     },
-    
+    onClose(){
+      this.drawer = false
+      this.$emit('onSuccess')
+    }
   },
   mounted () {
   }

+ 8 - 2
src/SDrpManagement/toolBorrowing/modules/edit.vue

@@ -5,7 +5,8 @@
     :visible.sync="drawer"
     direction="rtl"
     append-to-body
-    size="80%">
+    size="80%"
+    @close="onClose">
     <div slot="title">
       <div class="flex-align-center">
         <p ><span style="font-size:14px">订单合计:</span><span style="color:red;font-size:16px;"><b>¥&nbsp;{{tool.formatAmount(data.amount,2)}}</b></span></p>
@@ -211,7 +212,7 @@
       </div>
     </div>
     <div class="fixed__btn__panel">
-      <el-button size="small" @click="drawer = false" class="normal-btn-width">取 消</el-button>
+      <el-button size="small" @click="onClose" class="normal-btn-width">取 消</el-button>
       <el-button size="small" type="primary" @click="onSubmit" class="normal-btn-width">保存修改</el-button>
     </div>
   </el-drawer>
@@ -382,6 +383,11 @@ export default {
         // this.drawer = false
       })
     },
+    onClose(){
+      console.log("取消111")
+      this.drawer = false
+      this.$emit('onSuccess')
+    },
     onDelSuccess () {
       this.$refs.addpro.listData()
       this.$emit('onSuccess')