Forráskód Böngészése

返回跳转调整

wangtao 3 éve
szülő
commit
26d3cc6a8b

BIN
src/assets/image/function/icon11.png


+ 18 - 4
src/views/amount/index.vue

@@ -1,7 +1,7 @@
 <template>
   <div class="mianBox" v-if="order">
     <van-row class="headerBox"  >
-      <van-icon name="arrow-left" @click="$router.go(-1)" v-if="erp"/>
+      <van-icon name="arrow-left" @click="fanhuiBtn" v-if="erp"/>
       {{title}}
     </van-row>
     <template v-if="erp">
@@ -332,13 +332,19 @@ export default {
     userNoAlert(){
       Toast("当前账户初始流程中,请耐心等待或联系管理人员查询")
     },
-    getQueryVariable(variable){//参数获取
+    getQueryVariable(variable){//参数获取 设定微信进入参数
       //window.location.search.substring(1);
       var query = window.location.hash.substring(3);
       var vars = query.split("&");
+      if(vars[2]){ //判定微信端进入
+        localStorage.setItem("passageway","weixin")
+      }else{
+        localStorage.removeItem("passageway")
+      }
       for (var i=0;i<vars.length;i++) {
         var pair = vars[i].split("=");
         if(pair[0] == variable || pair[0] =="mount?token"){
+          
           if(vars[1] != "classify"){
             localStorage.removeItem("classify")
           }
@@ -667,6 +673,14 @@ export default {
         (this.state6 = "color:#fff;background: #F22E3C;"),
         (this.money = 300);
     },
+    //返回上级或app目录页
+    fanhuiBtn(){
+      if(localStorage.getItem("passageway")){
+        this.$router.go(-1)
+      }else{
+        window.location.href = "https://smartpark.caih.com/h5/#/home/feature?isApp=true"
+      }
+    }
   },
 };
 </script>
@@ -776,9 +790,9 @@ export default {
      .van-button {
       margin-top:20px;
       width: 350px;
-      height: 50px;
+      height: 40px;
       border-radius: 10px;
-      font-size: 18px;
+      font-size: 16px;
     }
   }
   .recharge2{

+ 58 - 0
src/views/field/index.vue

@@ -0,0 +1,58 @@
+<template>
+  <div class="mianBox">
+    <van-row class="headerBox"  >
+      <van-icon name="arrow-left" @click="$router.go(-1)"/>
+      消费场所预约
+    </van-row>
+    
+    <van-loading
+        size="24px"
+        v-if="loadingErp"
+        color="#fff"
+        vertical
+        style="z-index: 999999; position: fixed; top: 40%; left: 0; right: 0;color:rgba(242, 46, 60, 1) !important"
+        >加载中...</van-loading
+      >
+      <van-overlay  style="z-index: 100; position: fixed" />
+  </div>
+</template>
+<script>
+import axios from "axios";
+import { Field, NumberKeyboard, Dialog, Toast } from "vant";
+import { returnFloat } from '@/assets/js/common.js'
+export default {
+  data() {
+    return {
+      loadingErp:false,
+      erp:false,
+      noerp:false,
+    };
+  },
+
+  components: {
+    [Field.name]: Field,
+    [NumberKeyboard.name]: NumberKeyboard,
+    [Dialog.name]: Dialog,
+    [Toast.name]: Toast,
+  },
+  created() {
+    
+  },
+  mouted(){
+  }
+};
+</script>
+<style lang="scss" scoped>
+
+.mianBox {
+  width: 100vw;
+  height: 100vh;
+  color: #000;
+  box-sizing: border-box;
+  background-color: #F5F5F5;
+  font-family: "Helvetica Neue", Helvetica, STHeiTi, sans-serif;
+  letter-spacing: 1px;
+  overflow: hidden;
+  position: fixed;
+}
+</style>

+ 5 - 1
src/views/home/index.vue

@@ -49,6 +49,10 @@
             <van-image :src="require('../../assets/image/function/icon10.png')" />
             <div class="title">综合安防</div>
           </van-col>
+          <!-- <van-col span="6" class="function"  v-if="people57 == '1'">
+            <van-image :src="require('../../assets/image/function/icon11.png')" />
+            <div class="title">预约场地</div>
+          </van-col> -->
         </van-row>
       </van-row>
       <van-row class="record">
@@ -351,7 +355,7 @@ export default {
     },
     //一卡通充值
     ykt(){
-      this.$router.push({ path: `/amount?token=${localStorage.getItem('cipher57')}&classify`})
+      this.$router.push({ path: `/amount?token=${localStorage.getItem('cipher57')}&classify=''&passageway='weixin'`}) //passageway检测微信进入会app进入
     },
     //世茂
     sm(url){

+ 5 - 8
src/views/result/index.vue

@@ -7,7 +7,7 @@
         <div v-if="result">
             <img src="../../assets/image/success.png" alt="" class="result">
             <van-row class="text">支付完成</van-row>
-            <van-button   type="danger" @click="$router.go(-1)" class="fanhui">返 回</van-button>
+            <van-button   type="danger" @click="fanhui()" class="fanhui">返 回</van-button>
         </div>
         <div v-if="!result">
             <img src="../../assets/image/fail.png" alt="" class="result">
@@ -36,7 +36,7 @@ export default {
   },
   methods: {
     fanhui(){
-        // window.location.href = ""
+      window.location.href = localStorage.getItem("amount57")
     }
   }
 }
@@ -57,20 +57,17 @@ export default {
   .result{
       width:30%;
       margin:50px 35% 0;
-
   }
   .text{
     font-size: 16px;
     margin:10px auto;
   }
   .fanhui{
-    //   width: calc(100% - 40px);
-    //   position: absolute;
-    //   bottom:20px;
-    //   left:20px;
       width:100%;
       margin-top:60px;
-      font-size: 18px;
+      height: 40px;
+      border-radius: 10px;
+      font-size: 16px;
       
   }
 }