修改动态加载js

This commit is contained in:
zpc 2024-07-24 23:42:42 +08:00
parent 81fc7653c8
commit d17288b578
2 changed files with 6 additions and 2 deletions

View File

@ -463,7 +463,7 @@ export default {
if (res.status == 1) {
let _data = res.data;
wx.config({
debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来若要查看传入的参数可以在pc端打开参数信息会通过log打出仅在pc端时才会打印。
debug: true, // 开启调试模式,调用的所有api的返回值会在客户端alert出来若要查看传入的参数可以在pc端打开参数信息会通过log打出仅在pc端时才会打印。
appId: _data.appId,
timestamp: _data.timestamp,
nonceStr: _data.noncestr,

View File

@ -176,6 +176,8 @@ Vue.prototype.req = function(param, backpage, backtype) {
}
})
}
// #ifdef H5
function loadScript(url) {
var script = document.createElement('script');
script.type = 'text/javascript';
@ -184,6 +186,8 @@ function loadScript(url) {
}
loadScript('https://res.wx.qq.com/open/js/jweixin-1.6.0.js');
// #endif
Vue.prototype.onBridgeReady = function(data) {
var x = {
@ -206,7 +210,7 @@ Vue.prototype.onBridgeReady = function(data) {
}
// 测试
// const baseUrl = ''
const baseUrl = 'http://101.43.1.207'
const baseUrl = 'http://api.zpc-xy.com/'
// 正式
// const baseUrl = 'https://xinglanmh.shequtuangou.vip'