From 8b42b5f96832145ba6cbb2aedd52a4e43e0e2d34 Mon Sep 17 00:00:00 2001 From: weiwei Date: Wed, 19 Feb 2025 09:03:39 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BC=80=E5=90=AF=E8=B6=85=E5=B8=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env | 4 +-- src/pages.json | 64 ++++++++++++++++++------------------- src/sheep/utils/isDevEnv.ts | 3 +- 3 files changed, 35 insertions(+), 36 deletions(-) diff --git a/.env b/.env index 1b2aa12..ed43361 100644 --- a/.env +++ b/.env @@ -42,6 +42,4 @@ VITE_APP_DEV_SERVICE = http://220.191.229.171:8090/api # 线上 #VITE_APP_PROD_SERVICE = http://59.202.170.152:81/api # VITE_APP_PROD_SERVICE = https://stgl.pj.gov.cn/api VITE_APP_PROD_SERVICE = http://220.191.229.171:8090/api -# ******************** end 生产环境 end ******************** -# VITE_DEV_ENV = dev -VITE_DEV_ENV = prod +# ******************** end 生产环境 end ******************** \ No newline at end of file diff --git a/src/pages.json b/src/pages.json index b13d4ed..91a538a 100644 --- a/src/pages.json +++ b/src/pages.json @@ -16,13 +16,13 @@ "disableScroll": true } }, - // { - // "path": "pages/tabbar/shop", - // "style": { - // "navigationBarTitleText": "商店", - // "disableScroll": true - // } - // }, + { + "path": "pages/tabbar/shop", + "style": { + "navigationBarTitleText": "超市", + "disableScroll": true + } + }, { "path": "pages/tabbar/order", "style": { @@ -43,25 +43,25 @@ "root": "pages/order", "pages": [] }, - // { - // "root": "pages/shop", - // "pages": [ - // { - // "path": "detail", - // "style": { - // "navigationBarTitleText": "", - // "disableScroll": true - // } - // }, - // { - // "path": "product-detail", - // "style": { - // "navigationBarTitleText": "", - // "disableScroll": true - // } - // } - // ] - // }, + { + "root": "pages/shop", + "pages": [ + { + "path": "detail", + "style": { + "navigationBarTitleText": "", + "disableScroll": true + } + }, + { + "path": "product-detail", + "style": { + "navigationBarTitleText": "", + "disableScroll": true + } + } + ] + }, { "root": "pages/apply", "pages": [ @@ -273,12 +273,12 @@ "iconPath": "static/tabbar/home.png", "selectedIconPath": "static/tabbar/home-select.png" }, - // { - // "pagePath": "pages/tabbar/shop", - // "text": "超市", - // "iconPath": "static/tabbar/shop.png", - // "selectedIconPath": "static/tabbar/shop-select.png" - // }, + { + "pagePath": "pages/tabbar/shop", + "text": "超市", + "iconPath": "static/tabbar/shop.png", + "selectedIconPath": "static/tabbar/shop-select.png" + }, { "pagePath": "pages/tabbar/order", "text": "订单", diff --git a/src/sheep/utils/isDevEnv.ts b/src/sheep/utils/isDevEnv.ts index 9e624c5..a081bbe 100644 --- a/src/sheep/utils/isDevEnv.ts +++ b/src/sheep/utils/isDevEnv.ts @@ -1 +1,2 @@ -export default () => import.meta.env.VITE_DEV_ENV === "dev" +// export default () => import.meta.env.VITE_DEV_ENV === "dev" +export default () => process.env.NODE_ENV === "development"