Commit 7161b2be by chenwq

url从配置获取

1 parent 0161f6a9
// pages/h5AuthPhone/h5AuthPhone.js
import api from '../../api/api.js'
const IMG_URL = 'https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat/'
import {
setConfigInfo
} from '~/store/index'
const app = getApp()
Page({
/**
......@@ -17,7 +21,6 @@ Page({
onShow(options) {
// this.init()
// console.log(options);
},
onLoad(options) {
console.log(options, '-------');
......@@ -26,7 +29,7 @@ Page({
})
this.login()
},
jumpH5(target) {
async jumpH5(target) {
const { routeObj } = this.data
routeObj.authphone = target.phone
let str = ''
......@@ -35,7 +38,9 @@ Page({
str = str + (str ? '&' : '?') + item + '=' + routeObj[item]
}
})
const url = 'https://scrm.glsx.com.cn/glsx-bi-report/#/' + routeObj.h5Page + str
// 获取配置服务数据
let baseConfigData = await setConfigInfo(app.globalData)
const url = (baseConfigData.jumpBIUrl || 'https://scrm.glsx.com.cn/glsx-bi-report/#/') + routeObj.h5Page + str
console.log(url, 'url')
wx.navigateTo({
url: `/pages/webView/webView?url=${encodeURIComponent(url)}`
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!