Compare commits

..

No commits in common. "7961d4a5a2fa3f3e3ae8bf3df91797c46092231d" and "17698bf1b8293538b1971cceced3c4c2f649cb19" have entirely different histories.

2 changed files with 7 additions and 11 deletions

View File

@ -374,9 +374,6 @@ export default {
//
verifyCode: '',
//
isGroupBuyValid: true
};
},
computed: {
@ -595,7 +592,7 @@ export default {
//
const currentTime = new Date().getTime();
this.isGroupBuyValid = true;
let isGroupBuyValid = true;
//
for (let supplierId in this.supplierGroups) {
@ -604,18 +601,18 @@ export default {
const activityInfo = item.commodity_goods_info.group_buy_activity_info;
// isGroupBuyValidfalse
if (!activityInfo) {
this.isGroupBuyValid = false;
isGroupBuyValid = false;
break;
}
const startTime = new Date(activityInfo.start_time).getTime();
const endTime = new Date(activityInfo.end_time).getTime();
if (!(currentTime >= startTime && currentTime <= endTime)) {
this.isGroupBuyValid = false;
isGroupBuyValid = false;
break;
}
}
if (!this.isGroupBuyValid) break;
if (!isGroupBuyValid) break;
}
// isafterSaletrue
@ -656,7 +653,7 @@ export default {
const params = {
user_id: uni.getStorageSync('userId'),
// shopCarListisAdvertrue
order_cate : this.carList.some(item => item.isAdver === true) ? 3 : (this.isGroupBuyValid ? 2 : 1),
order_cate : this.carList.some(item => item.isAdver === true) ? 3 : (isGroupBuyValid ? 2 : 1),
goods_list: Object.keys(this.supplierGroups).map(supplierId => {
const group = this.supplierGroups[supplierId];
const firstItem = group[0];
@ -718,7 +715,7 @@ export default {
success: (payRes) => {
const params = {
order_id: orderId,
from: this.carList.some(item => item.isAdver === true) ? 3 : (this.isGroupBuyValid ? 2 : 1),
from: this.carList.some(item => item.isAdver === true) ? 3 : (isGroupBuyValid ? 2 : 1),
group_buy_activity_id: this.group_buy_activity_id,
adver_id: this.carList.some(item => item.isAdver === true) ? this.carList.find(item => item.isAdver === true).adver_id : ''
}

View File

@ -55,8 +55,7 @@ const getCurrentEnvironment = () => {
// 获取当前环境配置
const currentEnv = getCurrentEnvironment();
console.log("🚀 ~ currentEnv:", currentEnv)
const envConfig = environments[currentEnv] || environments.production;
const envConfig = environments[currentEnv] || environments.development;
export const RequsetUrl = envConfig.apiUrl; // 请求地址前缀
export const picUrl = envConfig.picUrl; // 图片地址前缀