配置:去除stable服env的特殊处理

This commit is contained in:
luying
2021-12-08 14:59:01 +08:00
parent b51a2839da
commit 02c2096704
14 changed files with 66 additions and 75 deletions
@@ -261,22 +261,21 @@ export function _getActivities() {
export async function checkActivityEditable(activities: ActivityModelType[]) {
let now = new Date();
if(pinus.app.get('env') == 'production') {
for(let activity of activities) {
if(!activity || (activity.beginTime < now && activity.endTime > now)) {
if(activity.type == ACTIVITY_TYPE.SIGN_IN || activity.type == ACTIVITY_TYPE.SIGN_IN_VIP) {
// 签到活动的不显示期内也可以编辑
let signInObj = new SignInData(activity, 0);
if(signInObj.beginTime < now.getTime() && signInObj.endTime > now.getTime() ) {
return false;
}
} else {
for(let activity of activities) {
if(!activity || (activity.beginTime < now && activity.endTime > now)) {
if(activity.type == ACTIVITY_TYPE.SIGN_IN || activity.type == ACTIVITY_TYPE.SIGN_IN_VIP) {
// 签到活动的不显示期内也可以编辑
let signInObj = new SignInData(activity, 0);
if(signInObj.beginTime < now.getTime() && signInObj.endTime > now.getTime() ) {
return false;
}
} else {
return false;
}
}
}
return true;
}