@@ -2,8 +2,8 @@ var extConfig = wx.getExtConfigSync ? wx.getExtConfigSync() : {}; | |||||
var appId = extConfig.appId; | var appId = extConfig.appId; | ||||
var config = { | var config = { | ||||
// url: "https://ciformall.youlane.cn/C/api", | // url: "https://ciformall.youlane.cn/C/api", | ||||
// url:"https://c.malls.iformall.com/C/api", | |||||
url:'https://ctest.malls.iformall.com/C/api', | |||||
url:"https://c.malls.iformall.com/C/api", | |||||
// url:'https://ctest.malls.iformall.com/C/api', | |||||
// url:'http://10.100.33.68:7000/C/api', | // url:'http://10.100.33.68:7000/C/api', | ||||
// url: 'http://202.165.179.86:4000/C/api', | // url: 'http://202.165.179.86:4000/C/api', | ||||
api: { | api: { | ||||
@@ -203,7 +203,7 @@ var config = { | |||||
}, | }, | ||||
weapp: { | weapp: { | ||||
AppId: "wx649b3be73c1afe47" | |||||
AppId: "wx30caec1cc16c4634" | |||||
}, | }, | ||||
ErrorCode: { | ErrorCode: { | ||||
@@ -54,17 +54,15 @@ Page({ | |||||
let that = this; | let that = this; | ||||
wx.scanCode({ | wx.scanCode({ | ||||
success: (res) => { | success: (res) => { | ||||
console.log(JSON.parse(res.result).merchant_id_scan) | |||||
let merchant_id_scan = JSON.parse(res.result).merchant_id_scan; | |||||
if(merchant_id_scan){ | |||||
console.log(res.result.indexOf('merchant_id_scan')) | |||||
if(res.result.indexOf('merchant_id_scan')!=-1){ | |||||
Http.get({ | Http.get({ | ||||
url: config.api.findByCode, | url: config.api.findByCode, | ||||
data: { | data: { | ||||
merchantCode: merchant_id_scan, | |||||
merchantCode: JSON.parse(res.result).merchant_id_scan, | |||||
} | } | ||||
}) | }) | ||||
.then(res => { | .then(res => { | ||||
console.log(res); | |||||
if (res.code == 200) { | if (res.code == 200) { | ||||
let merChantDetail = JSON.stringify(res.data); | let merChantDetail = JSON.stringify(res.data); | ||||
if (merChantDetail && e.currentTarget.dataset.cardid && e.currentTarget.dataset.remainingamount) { | if (merChantDetail && e.currentTarget.dataset.cardid && e.currentTarget.dataset.remainingamount) { | ||||
@@ -13,7 +13,7 @@ | |||||
}, | }, | ||||
"compileType": "miniprogram", | "compileType": "miniprogram", | ||||
"libVersion": "2.0.9", | "libVersion": "2.0.9", | ||||
"appid": "wx649b3be73c1afe47", | |||||
"appid": "wx30caec1cc16c4634", | |||||
"projectname": "C", | "projectname": "C", | ||||
"isGameTourist": false, | "isGameTourist": false, | ||||
"condition": { | "condition": { | ||||