fea: 环境可配置项
This commit is contained in:
@@ -1,16 +1,18 @@
|
||||
<template>
|
||||
<view class="mild-shopping">
|
||||
<web-view
|
||||
ref="webview"
|
||||
:webview-styles="webviewStyles"
|
||||
:src="webviewUrl"
|
||||
@message="handlePostMessage"
|
||||
@onPostMessage="handlePostMessage"
|
||||
></web-view></view>
|
||||
<view class="mild-shopping">
|
||||
<web-view
|
||||
ref="webview"
|
||||
:webview-styles="webviewStyles"
|
||||
:src="webviewUrl"
|
||||
@message="handlePostMessage"
|
||||
@onPostMessage="handlePostMessage"
|
||||
></web-view
|
||||
></view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { TOKEN_NAME, USER_DATA, getStorageFun } from "@/utils/auth.js";
|
||||
import { MILD_BASE_URL } from "@/utils/config.js";
|
||||
// 全局变量
|
||||
let wv; // 计划创建的webview
|
||||
|
||||
@@ -23,14 +25,16 @@ export default {
|
||||
},
|
||||
},
|
||||
wvNode: null,
|
||||
// webviewUrl:'https://agent.o.tbmall.xin/',//中台测试
|
||||
webviewUrl:'https://agent.tbmall.xin',
|
||||
webviewUrl: "",
|
||||
// webviewUrl:'https://agent.o.tbmall.xin/',//中台测试
|
||||
// webviewUrl:'https://agent.tbmall.xin',
|
||||
// webviewUrl: "http://192.168.1.29:8004/",
|
||||
};
|
||||
},
|
||||
|
||||
onShow() {
|
||||
// #ifdef APP-PLUS
|
||||
this.webviewUrl = MILD_BASE_URL;
|
||||
this.initWebview();
|
||||
// #endif
|
||||
},
|
||||
@@ -43,7 +47,7 @@ export default {
|
||||
const currentWebview = this.$scope.$getAppWebview();
|
||||
setTimeout(() => {
|
||||
wv = currentWebview.children()[0];
|
||||
console.log(
|
||||
console.log(
|
||||
"TOKEN_NAME-1",
|
||||
getStorageFun(TOKEN_NAME),
|
||||
getStorageFun(USER_DATA)
|
||||
@@ -112,7 +116,7 @@ export default {
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.mild-shopping{
|
||||
.mild-shopping {
|
||||
padding-top: var(--status-bar-height);
|
||||
}
|
||||
</style>
|
||||
|
||||
+7
-3
@@ -1,9 +1,13 @@
|
||||
// export const BASE_URL="https://frontend.jdns360.com/api"; // 正式环境
|
||||
// export const BASE_URL="http://cl55un59859.vicp.fun:24346"; // 测试环境
|
||||
|
||||
export const BASE_URL = "https://api.tbmall.xin"; //生产
|
||||
// export const BASE_URL ='http://api.hm.a-d.work:6880' // 测试
|
||||
// export const BASE_URL ='https://api.o.tbmall.xin'; // 本地测试
|
||||
|
||||
// export const BASE_URL = "https://api.tbmall.xin"; //生产
|
||||
// export const MILD_BASE_URL = "https://agent.tbmall.xin/"; //中台生产
|
||||
|
||||
export const BASE_URL ='https://api.o.tbmall.xin'; // 本地测试
|
||||
export const MILD_BASE_URL = "https://agent.o.tbmall.xin/"; //中台测试
|
||||
|
||||
|
||||
export const SHARE_URL = 'https://h.tbmall.xin';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user