Browse Source

开发环境不允许跳转

shish 4 years ago
parent
commit
bcd040b42a

+ 5 - 0
ghsApp/src/admin/home/mall.vue

@@ -19,6 +19,7 @@
 import { mainGetMallPoster } from '@/api/main/index'
 import { mainGetMallPoster } from '@/api/main/index'
 import { getWeixinId } from "@/api/invite/index";
 import { getWeixinId } from "@/api/invite/index";
 import { mapGetters } from "vuex";
 import { mapGetters } from "vuex";
+import { CURRENT_ENV } from '@/config'
 export default {
 export default {
   data() {
   data() {
     return {
     return {
@@ -74,6 +75,10 @@ export default {
         })
         })
         // #endif
         // #endif
         // #ifdef APP-PLUS
         // #ifdef APP-PLUS
+        if(CURRENT_ENV == 'dev'){
+          that.$msg("开发环境不允许跳转")
+          return false
+        }
         if(plus.runtime.isApplicationExist({pname:'com.tencent.mm',action:'weixin://'})){
         if(plus.runtime.isApplicationExist({pname:'com.tencent.mm',action:'weixin://'})){
           plus.share.getServices(function(s){
           plus.share.getServices(function(s){
             var sweixin
             var sweixin

+ 5 - 0
ghsApp/src/admin/item/list.vue

@@ -56,6 +56,7 @@ import productMins from "@/mixins/product";
 import { mapGetters } from "vuex";
 import { mapGetters } from "vuex";
 import { getWeixinId } from "@/api/invite/index";
 import { getWeixinId } from "@/api/invite/index";
 import { generatePriceTable,generateBarcodeTable,print } from '@/api/product'
 import { generatePriceTable,generateBarcodeTable,print } from '@/api/product'
+import { CURRENT_ENV } from '@/config'
 export default {
 export default {
 	name: "item_list",
 	name: "item_list",
 	components: {
 	components: {
@@ -266,6 +267,10 @@ export default {
 			})
 			})
 			// #endif
 			// #endif
 			// #ifdef APP-PLUS
 			// #ifdef APP-PLUS
+			if(CURRENT_ENV == 'dev'){
+				that.$msg("开发环境不允许跳转")
+				return false
+			}
 			if(plus.runtime.isApplicationExist({pname:'com.tencent.mm',action:'weixin://'})){
 			if(plus.runtime.isApplicationExist({pname:'com.tencent.mm',action:'weixin://'})){
 				var sweixin
 				var sweixin
 				plus.share.getServices(function(s){
 				plus.share.getServices(function(s){

+ 5 - 0
hdApp/src/admin/cg/mall.vue

@@ -17,6 +17,7 @@
 import { mainGetMallPoster } from '@/api/main/index'
 import { mainGetMallPoster } from '@/api/main/index'
 import { getWeixinId } from "@/api/invite/index";
 import { getWeixinId } from "@/api/invite/index";
 import { mapGetters } from "vuex";
 import { mapGetters } from "vuex";
+import { CURRENT_ENV } from '@/config'
 export default {
 export default {
   data() {
   data() {
     return {
     return {
@@ -75,6 +76,10 @@ export default {
       // #endif
       // #endif
       // #ifdef APP-PLUS
       // #ifdef APP-PLUS
       let that = this
       let that = this
+			if(CURRENT_ENV == 'dev'){
+				that.$msg("开发环境不允许跳转")
+				return false
+			}
       if(plus.runtime.isApplicationExist({pname:'com.tencent.mm',action:'weixin://'})){
       if(plus.runtime.isApplicationExist({pname:'com.tencent.mm',action:'weixin://'})){
         plus.share.getServices(function(s){
         plus.share.getServices(function(s){
           var sweixin
           var sweixin

+ 5 - 0
hdApp/src/admin/home/workbench.vue

@@ -77,6 +77,7 @@ import { getShopInfo } from "@/utils/auth";
 import { consoleIndex } from "@/api/workbench";
 import { consoleIndex } from "@/api/workbench";
 import NotLogin from "@/components/not-login";
 import NotLogin from "@/components/not-login";
 import autoUpdateMixins from "@/mixins/autoUpdate";
 import autoUpdateMixins from "@/mixins/autoUpdate";
+import { CURRENT_ENV } from '@/config'
 export default {
 export default {
   name: "workbench",
   name: "workbench",
   components: { NotLogin },
   components: { NotLogin },
@@ -154,6 +155,10 @@ export default {
       // #endif
       // #endif
       // #ifdef APP-PLUS
       // #ifdef APP-PLUS
       let that = this
       let that = this
+		if(CURRENT_ENV == 'dev'){
+			that.$msg("开发环境不允许跳转")
+			return false
+		}
       if(plus.runtime.isApplicationExist({pname:'com.tencent.mm',action:'weixin://'})){
       if(plus.runtime.isApplicationExist({pname:'com.tencent.mm',action:'weixin://'})){
         plus.share.getServices(function(s){
         plus.share.getServices(function(s){
           var sweixin
           var sweixin