diff --git a/.env b/.env index 1b4d3ca..07cad84 100644 --- a/.env +++ b/.env @@ -1,4 +1,3 @@ # 邮储奶茶活动 VITE_YCNC_APPID = '2vikrqptiia9pe9bf5ztrd' -VITE_YCNC_SECRET = '6fpfwdkgcggyk0yf2yb6bt' -VITE_TEST_TOKEN = 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjdXN0Tm8iOiIzOTY3ODA2ODcwMjIyIiwiZXhwIjoxNzE5NTQxNzA5LCJpZCI6IjIifQ.cDjKKYYTYOPPYUh8XidADpxr8xZ_WXbZ9b1pZt1Kzm4' \ No newline at end of file +VITE_YCNC_SECRET = '6fpfwdkgcggyk0yf2yb6bt' \ No newline at end of file diff --git a/.env.development b/.env.development index 3a4f862..42e242b 100644 --- a/.env.development +++ b/.env.development @@ -1,6 +1,3 @@ -#请求url前缀 -# 中信建投 -# VITE_BASE_URL = 'http://zxjt.test.86698.cn' # 兴业优酷 # VITE_BASE_URL = 'http://192.168.110.50:8083' # 邮储奶茶活动 diff --git a/.env.production b/.env.production index 09a51e5..92c0495 100644 --- a/.env.production +++ b/.env.production @@ -1,9 +1,10 @@ -#请求url前缀 -# 中信建投 -# VITE_BASE_URL = 'https://zxjt.86698.cn' # 兴业优酷 # VITE_BASE_URL = 'http://192.168.110.50:8083' + + # 邮储奶茶活动(测试环境) -VITE_BASE_URL = 'http://milk.api.test.86698.cn' +# VITE_BASE_URL = 'http://milk.api.test.86698.cn' +# VITE_MERCH_CODE = '100610100019029' # 邮储奶茶活动(正式环境) -# VITE_BASE_URL = 'https://milk.api.cdlsxd.cn' \ No newline at end of file +VITE_BASE_URL = 'https://milk.api.cdlsxd.cn' +VITE_MERCH_CODE = '100510102210712' \ No newline at end of file diff --git a/index.html b/index.html index f141d48..460fc65 100644 --- a/index.html +++ b/index.html @@ -15,55 +15,56 @@
+ - + diff --git a/src/pages/ycnc/config.js b/src/pages/ycnc/config.js index 6833500..0ab0545 100644 --- a/src/pages/ycnc/config.js +++ b/src/pages/ycnc/config.js @@ -1,16 +1,9 @@ -// import MX from '../../static/ycnc/bg-mxbc.png' -// import BW from '../../static/ycnc/bg-bwcj.png' -// import NX from '../../static/ycnc/bg-nxdc.png' -// import CoCo from '../../static/ycnc/bg-coco.png' -// import CBD from '../../static/ycnc/bg-cbd.png' -// import CYYS from '../../static/ycnc/bg-cyys.png' - import MX from '/static/ycnc/bg-mxbc.png' import BW from '/static/ycnc/bg-bwcj.png' import NX from '/static/ycnc/bg-nxdc.png' import CoCo from '/static/ycnc/bg-coco.png' import CBD from '/static/ycnc/bg-cbd.png' -import CYYS from '/static/ycnc/bg-cyys.png' +// import CYYS from '/static/ycnc/bg-cyys.png' const config = { "MX":{ @@ -38,11 +31,11 @@ const config = { src:CBD, height:584, }, - "CYYS":{ - name:'茶颜悦色', - src:CYYS, - height:974, - }, + // "CYYS":{ + // name:'茶颜悦色', + // src:CYYS, + // height:974, + // }, } export const stateConfig = { diff --git a/src/pages/ycnc/hooks/usePay.js b/src/pages/ycnc/hooks/usePay.js index 441be8c..65b689e 100644 --- a/src/pages/ycnc/hooks/usePay.js +++ b/src/pages/ycnc/hooks/usePay.js @@ -20,7 +20,7 @@ export default function usePay(){ BackLink:encodeURIComponent(`${window.location.origin}/#/pages/ycnc/orderDetail?order_no=${order_no}`), psbcmcc:'LSXD', TxnDt:dayjs(Date.now()).format('YYYY-MM-DD'), - MercCode:'100610100019029' + MercCode:import.meta.env.VITE_MERCH_CODE } const params = { Plain:handleParams(Plain), diff --git a/src/pages/ycnc/index.vue b/src/pages/ycnc/index.vue index 6271a4e..1a83c9f 100644 --- a/src/pages/ycnc/index.vue +++ b/src/pages/ycnc/index.vue @@ -70,8 +70,6 @@ onMounted(async ()=>{ queryProducts(); - // let testToken = import.meta.env.VITE_TEST_TOKEN - // window.localStorage.setItem('token',testToken) const token = window.localStorage.getItem('token') || ''; if(!token){ console.log('进入登录过程'); diff --git a/src/static/ycnc/bg-cyys.png b/src/static/ycnc/bg-cyys.png deleted file mode 100644 index 0e59d4f..0000000 Binary files a/src/static/ycnc/bg-cyys.png and /dev/null differ diff --git a/src/utils/utils.js b/src/utils/utils.js index 9f77d96..6549d4b 100644 --- a/src/utils/utils.js +++ b/src/utils/utils.js @@ -3,7 +3,7 @@ export const getQueryString = (name) => { let urlStr = window.location.href.split('?')[1] const urlSearchParams = new URLSearchParams(urlStr) const result = Object.fromEntries(urlSearchParams.entries()) - return result[name] + return name ? result[name] : result } //是否iOS设备