Commit 57c9cccb authored by Edwise's avatar Edwise 🍷

123

parent 11c7b018
...@@ -18,9 +18,9 @@ const { ...@@ -18,9 +18,9 @@ const {
} = tbcc.tb; } = tbcc.tb;
let updateact = 1;//请求 let updateact = 1;//请求
let gameatime = 100;//活动倒计时,100, let gameatime = 100;//活动倒计时,100,
const toolwarm = 10;//升温道具+温度值 const toolwarm = 1;//升温道具+温度值
const taskwarm = 1;//任务+温度值 const taskwarm = 1;//任务+温度值
const invitewarm = 1;//邀请+温度值 const invitewarm = 2;//邀请+温度值
let gtoolcd = 5;// let gtoolcd = 5;//
const paple1 = "cloud://F03F0071205084B1A58F9C560010C076//paple3.svga"; const paple1 = "cloud://F03F0071205084B1A58F9C560010C076//paple3.svga";
......
...@@ -17,7 +17,8 @@ const { ...@@ -17,7 +17,8 @@ const {
getAuthUserInfo, getAuthUserInfo,
navigateToOutside, navigateToOutside,
getSystemInfo, getSystemInfo,
checkShopFavoredStatus checkShopFavoredStatus,
getServerTime,
} = tbcc.tb; } = tbcc.tb;
const snowSrc = "cloud://B975D7429522C2AA89E6FD651523DC57//snow.svga"; const snowSrc = "cloud://B975D7429522C2AA89E6FD651523DC57//snow.svga";
const fireSrc = "cloud://F03F0071205084B1A58F9C560010C076//fire.svga" const fireSrc = "cloud://F03F0071205084B1A58F9C560010C076//fire.svga"
...@@ -203,17 +204,20 @@ Page({ ...@@ -203,17 +204,20 @@ Page({
// const favoredStatus = await checkShopFavoredStatus(3035493001).catch(err => { // const favoredStatus = await checkShopFavoredStatus(3035493001).catch(err => {
// console.log('查询关注店铺状态失败', err); // console.log('查询关注店铺状态失败', err);
// }); // });
my.tb.checkShopFavoredStatus({ this.favoredStatus = await checkShopFavoredStatus(3035493001).catch(r=>{
id: 3035493001, console.log("关注不对劲")
success: (res) => {
if (res.isFavor) {
this.favoredStatus = true
} else {
this.favoredStatus = false;
}
}
}) })
// my.tb.checkShopFavoredStatus({
// id: 3035493001,
// success: (res) => {
// if (res.isFavor) {
// this.favoredStatus = true
// } else {
// this.favoredStatus = false;
// }
// }
// })
// this.judgeDoHelp(); // this.judgeDoHelp();
console.log("关注店铺", this.favoredStatus) console.log("关注店铺", this.favoredStatus)
...@@ -264,6 +268,15 @@ Page({ ...@@ -264,6 +268,15 @@ Page({
}) || {}; }) || {};
if (success) { if (success) {
const nowTime = await getServerTime().catch(()=>{});
if(nowTime&&data.startTime>nowTime){
my.hideLoading();
my.showToast({
content: '活动未开始',
duration: 5000,
});
return;
}
this.gameConfigList = data.gameConfigList; this.gameConfigList = data.gameConfigList;
// my.hideLoading(); // my.hideLoading();
app.activityInfo = data; app.activityInfo = data;
......
...@@ -117,7 +117,7 @@ export const favorShop = async sellerId => { ...@@ -117,7 +117,7 @@ export const favorShop = async sellerId => {
* @param {number} sellerId 店铺归属的卖家Id * @param {number} sellerId 店铺归属的卖家Id
* @returns {boolean} 关注状态 * @returns {boolean} 关注状态
*/ */
export const checkShopFavoredStatus = async sellerId => { export const checkShopFavoredStatus = async (sellerId) => {
if (!sellerId) { if (!sellerId) {
console.error('checkShopFavoredStatus: 请传入卖家Id'); console.error('checkShopFavoredStatus: 请传入卖家Id');
return false; return false;
......
This source diff could not be displayed because it is too large. You can view the blob instead.
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