From eb34c78d650608b3f196984d5d6ad9e4ecb3a948 Mon Sep 17 00:00:00 2001 From: zhl Date: Fri, 8 Mar 2019 13:01:01 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B7=B3=E8=BD=AC=E6=94=AF=E4=BB=98=E5=B0=8F?= =?UTF-8?q?=E7=A8=8B=E5=BA=8F=E6=A0=B9=E6=8D=AE=E9=85=8D=E7=BD=AE=E6=9D=A5?= =?UTF-8?q?=E7=A1=AE=E5=AE=9A=E6=98=AF=E5=BC=80=E5=8F=91=E7=89=88=E8=BF=98?= =?UTF-8?q?=E6=98=AF=E6=AD=A3=E5=BC=8F=E7=89=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/common/global.js | 2 +- src/components/z-action-sheet.wpy | 5 +++-- src/pages/gameInfo.wpy | 6 ++++-- src/pages/index.wpy | 6 ++++-- 4 files changed, 12 insertions(+), 7 deletions(-) diff --git a/src/common/global.js b/src/common/global.js index 6f1c21b..9e91e42 100644 --- a/src/common/global.js +++ b/src/common/global.js @@ -1,4 +1,4 @@ -const env = 'test'; +const env = 'test'; //product, test export default { env: env, apiBase: env === 'test'? 'https://ghost-test.kingsome.cn' : 'https://ghost.kingsome.cn', diff --git a/src/components/z-action-sheet.wpy b/src/components/z-action-sheet.wpy index 5727673..5570392 100644 --- a/src/components/z-action-sheet.wpy +++ b/src/components/z-action-sheet.wpy @@ -58,7 +58,7 @@ app-id="wx815bf59d472c0a63" path="/pages/product?{{config.params}}" extra-data="" - version="develop" + version="{{config.payVer}}" >促销开通 取消 @@ -73,7 +73,8 @@ hide: true, goldTitle: '', params: '', - showBuy: false + showBuy: false, + payVer: 'develop' } } data = { diff --git a/src/pages/gameInfo.wpy b/src/pages/gameInfo.wpy index 3a09a23..1965f53 100644 --- a/src/pages/gameInfo.wpy +++ b/src/pages/gameInfo.wpy @@ -100,9 +100,10 @@ hide: true, goldTitle: '金币开通', params: '', - showBuy: false + showBuy: false, + payVer: 'develop' }, - vip: false + vip: false, }; methods = { imageTap: function(index) { @@ -146,6 +147,7 @@ }; onLoad(params) { + this.zActionSheetCfg.payVer = g.env === 'product' ? 'release' : 'develop'; this.vip = this.$parent.isVip(); this.id = decodeURIComponent(params.id); this.showAll = this.$parent.showAll(); diff --git a/src/pages/index.wpy b/src/pages/index.wpy index 6b00ce4..d83ae39 100644 --- a/src/pages/index.wpy +++ b/src/pages/index.wpy @@ -17,7 +17,7 @@ app-id="wx815bf59d472c0a63" path="/pages/buyvip?{{vip_params}}" extra-data="" - version="develop" + version="{{payVer}}" > {{vip_btn_title}} @@ -88,7 +88,8 @@ vipImg: image.vip_s, vip_btn_title: '激活', vip_params: '', - showBuy: false + showBuy: false, + payVer: 'develop' }; methods = { @@ -122,6 +123,7 @@ async onLoad(options) { let self = this; + this.payVer = global.env === 'product' ? 'release' : 'develop'; if (!this.$parent.checkClientLogin()) { this.getAllData(); this.vip_params = `token=${this.$parent.getGlobalDate('gameToken')}`;