Explorar el Código

upload

soldDate
HolyKnightIX hace 1 año
padre
commit
3c89a4056c
Se han modificado 2 ficheros con 18 adiciones y 10 borrados
  1. +15
    -7
      pages/main/index.js
  2. +3
    -3
      project.config.json

+ 15
- 7
pages/main/index.js Ver fichero

@@ -106,7 +106,7 @@ Page({
if (options.couponChannelId || options.orderId || options.id) {
that.userStatus(options);
} else {
that.userStatus();
that.userStatus(options);
}
} else {
// 由于 token 是网络请求,可能会在 Page.onLoad 之后才返回
@@ -117,7 +117,7 @@ Page({
if (options.couponChannelId || options.orderId || options.id) {
that.userStatus(options);
} else {
that.userStatus();
that.userStatus(options);
}
}
}
@@ -128,10 +128,11 @@ Page({
*/
userStatus: function (options) {
var that = this;
console.log(options, 'userStatus');
if (options && (options.couponChannelId || options.orderId || options.id)) {
that.checkuserstatus(options);
} else {
that.checkuserstatus();
that.checkuserstatus(options);
}
},
/**
@@ -153,6 +154,7 @@ Page({
// },

checkuserstatus(options) {
console.log(options, 'checkuserstatus');
let that = this;
if (options && options.couponChannelId && options.type == 'orderAffirm') {
tt.redirectTo({
@@ -171,12 +173,18 @@ Page({
})
}
} else {
let dataX = {
token: app.globalData.token,
}

if (options && options.tenantId) {
dataX.mallTenantId = options.tenantId
}

console.log(dataX, 'dataX');
Http.get({
url: config.api.checkUserStatus,
data: {
token: app.globalData.token,
mallTenantId: options.tenantId
}
dataX
})
.then(res => {
// res = JSON.parse('{"code":11004,"message":"用户昵称未授权,请跳转到用户昵称授权页!","data":{}}')


+ 3
- 3
project.config.json Ver fichero

@@ -17,13 +17,13 @@
"projectname": "tt富茂C",
"condition": {
"miniprogram": {
"current": 1678330099779,
"current": 1678508631604,
"list": [
{
"id": 1676969626961,
"id": 1678508631604,
"name": "pages/main/index",
"pathName": "pages/main/index",
"query": "type=md&id=758855991052394496&tenantId=1032",
"query": "type=uc&tenantId=1033",
"scene": "990001",
"launchFrom": "scan",
"location": "qr_code"


Cargando…
Cancelar
Guardar