From 44d7a737dc0d63ad1dd7c52d45fc2233d1950173 Mon Sep 17 00:00:00 2001
From: lyfO_o <764716047@qq.com>
Date: 星期四, 09 六月 2022 09:56:08 +0800
Subject: [PATCH] Merge remote-tracking branch 'remotes/origin/shf' into master

---
 src/views/hiddenDangerRegistration/hiddenDangerAdd.vue |   25 +++++++++++++++++++------
 1 files changed, 19 insertions(+), 6 deletions(-)

diff --git a/src/views/hiddenDangerRegistration/hiddenDangerAdd.vue b/src/views/hiddenDangerRegistration/hiddenDangerAdd.vue
index bb4ff05..8835df8 100644
--- a/src/views/hiddenDangerRegistration/hiddenDangerAdd.vue
+++ b/src/views/hiddenDangerRegistration/hiddenDangerAdd.vue
@@ -385,6 +385,7 @@
         this.initWXY()
         this.initDangerRebound()
         this.id = this.$route.query.id;
+        this.route = this.$route.query.route;
         if( this.id!=null &&  this.id!=''){
             this.initInfo();
             this.addShow=false
@@ -571,9 +572,15 @@
 
 
       returnIndex(){
-          this.$router.push({
-              path:"/hiddenDangerRegistration"
-          })
+          if(this.route!=null){
+              this.$router.push({
+                  path:"/"+this.route
+              })
+          }else{
+              this.$router.push({
+                  path:"/hiddenDangerRegistration"
+              })
+          }
       },
     submitForm(formName) {
       this.$refs[formName].validate((valid) => {
@@ -613,9 +620,15 @@
                 editDanger(param).then(res=>{
                     if (res.data.ok==1){
                         this.$message({type:'success', message:"编辑成功", duration:3000})
-                        this.$router.push({
-                            path:"/hiddenDangerRegistration"
-                        })
+                        if(this.route!=null){
+                            this.$router.push({
+                                path:"/"+this.route
+                            })
+                        }else{
+                            this.$router.push({
+                                path:"/hiddenDangerRegistration"
+                            })
+                        }
                     }else {
                         this.$message({type:'error', message:res.data.msg, duration:3000})
                     }

--
Gitblit v1.9.2