瀏覽代碼

登录提示

dev_czc
HolyKnightIX 2 年之前
父節點
當前提交
026b2458d5
共有 2 個文件被更改,包括 24 次插入23 次删除
  1. +15
    -18
      ext.json
  2. +9
    -5
      pages/index/index.js

+ 15
- 18
ext.json 查看文件

@@ -4,26 +4,23 @@
"configUrl": "https://b.malls.iformall.com",
"datatowerurl": "https://mobile.malls.iformall.com"
},
"name": "吾悦广场集团版商户端",
"weappId": "ttb8a1ce1c279e948801",
"appVersion": "Btest.5.1.0"
"name": "滨江购物广场商家版",
"weappId": "tt61cc1771fef34a7701",
"appVersion": "B.5.1.0"
},
"debug": false,
"tabBar": {
"list": [
{
"text": "首页",
"iconPath": "assets/images/home-n.png",
"pagePath": "pages/main/main",
"selectedIconPath": "assets/images/home-y.png"
},
{
"text": "我的",
"iconPath": "assets/images/user-n.png",
"pagePath": "pages/user/user",
"selectedIconPath": "assets/images/user-y.png"
}
],
"list": [{
"text": "首页",
"iconPath": "assets/images/home-n.png",
"pagePath": "pages/main/main",
"selectedIconPath": "assets/images/home-y.png"
}, {
"text": "我的",
"iconPath": "assets/images/user-n.png",
"pagePath": "pages/user/user",
"selectedIconPath": "assets/images/user-y.png"
}],
"color": "#9F9F9F",
"selectedColor": "#52a0fd",
"backgroundColor": "#fff"
@@ -32,7 +29,7 @@
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#52A0FD"
},
"extAppid": "ttb8a1ce1c279e948801",
"extAppid": "tt61cc1771fef34a7701",
"extEnable": true,
"permission": {
"scope.userLocation": {


+ 9
- 5
pages/index/index.js 查看文件

@@ -128,10 +128,8 @@ Page({
if (pwd != '') {
Common.userLogin(phone, pwd, app.globalData.latitude, app.globalData.longitude)
.then(res => {
const logined = res.data.logined
const merchantList = res.data.merchantList
// 当logined为true时,正常进入商户
if (logined) {
if (res.data && res.data.logined == true) {
if (res.code == 200) {
HttpBasics.setBUserId(res.data.bUserId);
tt.setStorageSync("phone", phone);
@@ -176,12 +174,18 @@ Page({
})
}
// 当logined为false时,选择商户
} else {
} else if (res.data && res.data.logined == false) {
tt.setStorageSync("phone", phone);
tt.setStorageSync("pwd", pwd);
this.setData({
ifShowShop: true,
merchantList: merchantList
merchantList: res.data.merchantList
})
} else {
tt.showToast({
image: './../../assets/images/fail.png',
title: res.message,
icon: "none"
})
}
})


Loading…
取消
儲存