Commit 70f7492f authored by Edwise's avatar Edwise 🍷

1

parent 644643d9
...@@ -9,7 +9,7 @@ cloud.init({ ...@@ -9,7 +9,7 @@ cloud.init({
App({ App({
env, env,
requestType: 'cloud', // yapi,cloud: 云函数 requestType: 'cloud', // yapi,cloud: 云函数
requestType: 'local', // yapi,cloud: 云函数 // requestType: 'local', // yapi,cloud: 云函数
cloudName: 'jn', // 主云函数项目名 tmallCat cloudName: 'jn', // 主云函数项目名 tmallCat
// cloudName: 'bubbleSurviva', // 主云函数项目名 tmallCat // cloudName: 'bubbleSurviva', // 主云函数项目名 tmallCat
cloud, cloud,
...@@ -31,7 +31,7 @@ App({ ...@@ -31,7 +31,7 @@ App({
*/ */
handleQuery(query) { handleQuery(query) {
const { activityId } = query; const { activityId } = query;
this.activityId = activityId || '5f8022919da671f3b6d5fb14'; this.activityId = activityId || '5f8550a3964f97be3647a635';
} }
}); });
...@@ -49,7 +49,7 @@ Component({ ...@@ -49,7 +49,7 @@ Component({
let str1 = ''; let str1 = '';
if(isWin){ if(isWin){
str = '恭喜您PK成功'; str = '恭喜您PK成功';
str1 = '体感温度高达'+warms+'℃,是最高温队伍' str1 = '体感温度高达'+app.curGameWars+'℃,是最高温队伍'
}else{ }else{
str = '很遗憾PK失败' str = '很遗憾PK失败'
} }
......
...@@ -29,6 +29,7 @@ const checkSystem = async () => { ...@@ -29,6 +29,7 @@ const checkSystem = async () => {
} }
Page({ Page({
favoredStatus:false,
data: { data: {
indexPrize: [{ indexPrize: [{
id:1, id:1,
...@@ -189,18 +190,30 @@ Page({ ...@@ -189,18 +190,30 @@ Page({
} = userInfo; } = userInfo;
app.nickName = nickName; app.nickName = nickName;
app.avatar = avatar; app.avatar = avatar;
const favoredStatus = await checkShopFavoredStatus(3035493001).catch(err => { // const favoredStatus = await checkShopFavoredStatus(3035493001).catch(err => {
console.log('查询关注店铺状态失败', err); // console.log('查询关注店铺状态失败', err);
}); // });
my.tb.checkShopFavoredStatus({
id: 702037595,
success: (res) => {
if(res.isFavor){
this.favoredStatus = true
}else{
this.favoredStatus = false;
}
}
})
// this.judgeDoHelp(); // this.judgeDoHelp();
this.login(favoredStatus); console.log("关注店铺",this.favoredStatus)
this.login();
} }
}, },
/** /**
* 登录接口 * 登录接口
*/ */
async login(isFollow) { async login() {
my.showLoading(); my.showLoading();
const { const {
nickName, nickName,
...@@ -212,7 +225,7 @@ Page({ ...@@ -212,7 +225,7 @@ Page({
} = await API.login({ } = await API.login({
userNick: nickName, userNick: nickName,
avatar, avatar,
isFollow:isFollow, isFollow:this.favoredStatus,
inviteId:app.inviteId, inviteId:app.inviteId,
inviteStep:app.step inviteStep:app.step
}).catch(res => { }).catch(res => {
......
...@@ -124,7 +124,7 @@ export const checkShopFavoredStatus = async sellerId => { ...@@ -124,7 +124,7 @@ export const checkShopFavoredStatus = async sellerId => {
} }
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
my.tb.checkShopFavoredStatus({ my.tb.checkShopFavoredStatus({
id: +sellerId, id: sellerId,
success: res => { success: res => {
resolve(res.isFavor); resolve(res.isFavor);
}, },
......
This diff is collapsed.
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