Commit 53822a5f by 程智春

Merge branch 'nativehome_tst' of http://code.mayi888.com/chengmo/mayi-mp-shop into nativehome_tst

parents d9f50ec4 da0249b7
...@@ -17,7 +17,7 @@ module.exports = merge(prodEnv, {//zjgyl ...@@ -17,7 +17,7 @@ module.exports = merge(prodEnv, {//zjgyl
// BASE_URL:"'http://192.168.1.146:3005'", // BASE_URL:"'http://192.168.1.146:3005'",
// BASE_URL:"'http://192.168.1.127:3000'", // BASE_URL:"'http://192.168.1.127:3000'",
BASE_URL:"'https://test-m-shop.mayi888.cn'", BASE_URL:"'https://test-m-shop.mayi888.cn'",
// BASE_URL:"'http://172.16.1.48:3004'", // BASE_URL:"'http://192.168.137.1:3004'",
OLSHOP_URL:'"https://test-m-shop.mayi888.cn/innerApi/shopApiService"', OLSHOP_URL:'"https://test-m-shop.mayi888.cn/innerApi/shopApiService"',
// OLSHOP_URL:'"https://shop.mayi888.com/innerApi/shopApiService"', // OLSHOP_URL:'"https://shop.mayi888.com/innerApi/shopApiService"',
......
{ {
"description": "项目配置文件。", "description": "项目配置文件。",
"setting": { "setting": {
"urlCheck": false, "urlCheck": false,
"es6": true, "es6": true,
"enhance": true, "enhance": true,
"postcss": true, "postcss": true,
"minified": true, "minified": true,
"newFeature": true, "newFeature": true,
"coverView": true, "coverView": true,
"nodeModules": true, "nodeModules": true,
"autoAudits": true, "autoAudits": true,
"showShadowRootInWxmlPanel": false, "showShadowRootInWxmlPanel": false,
"scopeDataCheck": false, "scopeDataCheck": false,
"uglifyFileName": true, "uglifyFileName": true,
"checkInvalidKey": true, "checkInvalidKey": true,
"checkSiteMap": true, "checkSiteMap": true,
"uploadWithSourceMap": true, "uploadWithSourceMap": true,
"useMultiFrameRuntime": true, "useMultiFrameRuntime": true,
"useApiHook": true, "useApiHook": true,
"useApiHostProcess": true, "useApiHostProcess": true,
"babelSetting": { "babelSetting": {
"ignore": [], "ignore": [],
"disablePlugins": [], "disablePlugins": [],
"outputPath": "" "outputPath": ""
}, },
"bundle": false, "bundle": false,
"useIsolateContext": true, "useIsolateContext": true,
"useCompilerModule": true, "useCompilerModule": true,
"userConfirmedUseCompilerModuleSwitch": false, "userConfirmedUseCompilerModuleSwitch": false,
"userConfirmedBundleSwitch": false, "userConfirmedBundleSwitch": false,
"packNpmManually": false, "packNpmManually": false,
"packNpmRelationList": [], "packNpmRelationList": [],
"minifyWXSS": true "minifyWXSS": true
}, },
"miniprogramRoot": "dist/wx/", "miniprogramRoot": "dist/wx/",
"compileType": "miniprogram", "compileType": "miniprogram",
"appid": "wx8a509d2f2ac15903", "appid": "wx8a509d2f2ac15903",
"projectname": "mayi-mp-shop", "projectname": "mayi-mp-shop",
"simulatorType": "wechat", "simulatorType": "wechat",
"simulatorPluginLibVersion": {}, "simulatorPluginLibVersion": {},
"libVersion": "2.15.0", "libVersion": "2.15.0",
"condition": { "condition": {
"search": { "plugin": {
"list": [] "list": []
}, },
"conversation": { "game": {
"list": [] "list": []
}, },
"plugin": { "gamePlugin": {
"list": [] "list": []
}, },
"game": { "miniprogram": {
"currentL": -1, "list": [
"list": [] {
}, "id": 0,
"gamePlugin": { "name": "pages/index/main",
"list": [] "pathName": "pages/index/main",
}, "query": "",
"miniprogram": { "scene": null
"list": [ },
{ {
"id": 0, "id": -1,
"name": "pages/index/main", "name": "pages/login/main",
"pathName": "pages/index/main", "pathName": "pages/login/main",
"query": "", "query": "",
"scene": null "scene": null
}, },
{ {
"id": -1, "id": 2,
"name": "pages/login/main", "name": "pages/index/main",
"pathName": "pages/login/main", "pathName": "pages/index/main",
"query": "", "query": "scene=pid_6141",
"scene": null "scene": 1047
}, },
{ {
"id": 2, "name": "pages/tabBar1/main",
"name": "pages/index/main", "pathName": "pages/tabBar1/main",
"pathName": "pages/index/main", "query": "",
"query": "scene=pid_6141", "scene": null
"scene": 1047 },
} {
] "name": "pages/tabBar4/main",
} "pathName": "pages/tabBar4/main",
} "scene": null
}
]
}
}
} }
\ No newline at end of file
...@@ -11,6 +11,7 @@ export default { ...@@ -11,6 +11,7 @@ export default {
process.env.NODE_ENV == "development" || process.env.NODE_ENV == "development" ||
JSON.stringify(extConfig) == "{}" JSON.stringify(extConfig) == "{}"
) { ) {
// extConfig = { mixid: "jordan", shopid: 471 };
extConfig = { mixid: "antgood", shopid: 67 }; extConfig = { mixid: "antgood", shopid: 67 };
} }
console.log("1444444444", extConfig.mixid); console.log("1444444444", extConfig.mixid);
......
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
"pages/tabBar1/main", "pages/tabBar1/main",
"pages/tabBar2/main", "pages/tabBar2/main",
"pages/tabBar3/main", "pages/tabBar3/main",
"pages/tabBar4/main",
"pages/changeAdr/main" "pages/changeAdr/main"
], ],
"tabBar": { "tabBar": {
...@@ -31,6 +32,9 @@ ...@@ -31,6 +32,9 @@
}, },
{ {
"pagePath": "pages/tabBar3/main" "pagePath": "pages/tabBar3/main"
},
{
"pagePath": "pages/tabBar4/main"
} }
] ]
}, },
......
...@@ -220,6 +220,7 @@ export default { ...@@ -220,6 +220,7 @@ export default {
}else { }else {
this.mpApp.themeColorCallBack=(res)=>{ this.mpApp.themeColorCallBack=(res)=>{
this.themeColor = res this.themeColor = res
} }
} }
......
import cart from "@/api/cart" import cart from "@/api/cart"
// 登录白名单 name
export const noLoginList = ["index", "media-video", "goods-goodsInfo", "goods-commodityMenu", "goodsSearch-goodsSearch", "chooseStores", "activty-receivingGift", "activty", "login-register", "login-phoneLogin", "login-authInformation", "login-forgetPassWord", "login-accountLogin", "login-wxRegister", "pay-payList", "comment-evaluateList", "goods-commonProblemList", "article-articlePage", "article-articleList", "goods-posters", "liveBroadcast", "liveBroadcast-list", "personalCenter-coupon-getCoupon", "buyerShow-showDetail", "goods-addGoodsList", "personalCenter-CDkey-exchange", "giftCards-linkReceive", "giftCoupon-preview", "smartForm", "shopCart-shareShopCart", "groupBuying-beInvite", "brandTopics", 'personalCenter-spokesmanCenter', 'personalCenter-spokesmanCenter-mine-spokesmanHomePage','liveBroadcast-lived', 'personalCenter-spokesmanCenter-mine-getBusinessCard','changeAdr'];
// path
export const noLoginListPath = noLoginList.map(item=>{
item=item.replace(/-/g,'/')
item='/'+item
item=="/index" && (item="/")
return item
})
// 主题色 // 主题色
export let themeColor = { export let themeColor = {
"--main-color": "#ffffff", "--main-color": "#ffffff",
...@@ -19,13 +30,21 @@ export function $themeToLink(data, option) { ...@@ -19,13 +30,21 @@ export function $themeToLink(data, option) {
// 点击底部栏 // 点击底部栏
if (option) { if (option) {
let parseLink = getUrlofLink(data); let parseLink = getUrlofLink(data);
let isTabbarIndex = checkTabbarPage(parseLink); let aa=noLoginListPath.includes(parseLink) || parseLink.substr(0,7)=="/goods/"
console.log(parseLink,aa,'parseLinkparseLinkparseLink',parseLink,noLoginListPath)
if (!aa && !wx.getStorageSync("sessionid")) {
let url = `/pages/login/main?back=${parseLink}`;
wx.navigateTo({url});
return
}
// 替换首页位置 // 替换首页位置
let isTabbarIndex = checkTabbarPage(parseLink);
isTabbarIndex = isTabbarIndex == 0 ? checkTabbarPage('/') : isTabbarIndex isTabbarIndex = isTabbarIndex == 0 ? checkTabbarPage('/') : isTabbarIndex
wx.switchTab({ wx.switchTab({
url: parseLink == '/' ? '/pages/home/main' : `/pages/tabBar${isTabbarIndex}/main`, url: parseLink == '/' ? '/pages/home/main' : `/pages/tabBar${isTabbarIndex}/main`,
}) })
console.log(option, data) console.log(option, data,'---',parseLink == '/' ? '/pages/home/main' : `/pages/tabBar${isTabbarIndex}/main`)
return return
} }
...@@ -37,18 +56,6 @@ export function $themeToLink(data, option) { ...@@ -37,18 +56,6 @@ export function $themeToLink(data, option) {
} }
return return
} }
// 底部导航跳转
// let parseLink=getUrlofLink(data)
// let isTabbarIndex =checkTabbarPage(parseLink )
// if (isTabbarIndex>-1) {
// wx.switchTab({
// url: parseLink == '/' ? '/pages/home/main' : `/pages/tabBar${isTabbarIndex}/main`,
// })
// return
// }
// ----------------- // -----------------
if (type == 0) {//无链接 if (type == 0) {//无链接
return return
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment