|
@@ -339,6 +339,7 @@ public class GroupRelationFrontServiceImpl implements GroupRelationFrontService
|
|
|
.gt(VipUser::getExpiryTime, now));
|
|
.gt(VipUser::getExpiryTime, now));
|
|
|
List<RenewalView> removeElements = null;
|
|
List<RenewalView> removeElements = null;
|
|
|
for (RenewalView ticket : list.getDataList()) {
|
|
for (RenewalView ticket : list.getDataList()) {
|
|
|
|
|
+ ticket.setCanReceiveGptApiQuota(false);
|
|
|
if (ticket.getSkuId() == null || ticket.getGoodsId() == null) {
|
|
if (ticket.getSkuId() == null || ticket.getGoodsId() == null) {
|
|
|
continue;
|
|
continue;
|
|
|
}
|
|
}
|
|
@@ -440,9 +441,7 @@ public class GroupRelationFrontServiceImpl implements GroupRelationFrontService
|
|
|
ticket.setIsComplete(orderDon.getStatus() == OrderDon.Status.complete ? true : false);
|
|
ticket.setIsComplete(orderDon.getStatus() == OrderDon.Status.complete ? true : false);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
- if (isGptApiQuotaSourceTicket(orderDon, ticket.getGoodsId(), ticket.getSkuNum())) {
|
|
|
|
|
- markGptApiQuotaReceiveStatus(userIds, ticket, orderDon);
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ markGptApiQuotaReceiveStatus(userIds, ticket, orderDon);
|
|
|
if (lang != null && !StrUtil.equals(UserPageLanguage.Language.zh_CN.name(), lang)) {
|
|
if (lang != null && !StrUtil.equals(UserPageLanguage.Language.zh_CN.name(), lang)) {
|
|
|
String languageSpecVal = backInfoTranslationsFrontService.getLanguageSpecVal(zhSkuId, lang);
|
|
String languageSpecVal = backInfoTranslationsFrontService.getLanguageSpecVal(zhSkuId, lang);
|
|
|
if (StrUtil.isNotBlank(languageSpecVal)) {
|
|
if (StrUtil.isNotBlank(languageSpecVal)) {
|
|
@@ -597,7 +596,9 @@ public class GroupRelationFrontServiceImpl implements GroupRelationFrontService
|
|
|
|
|
|
|
|
private void markGptApiQuotaReceiveStatus(List<Long> userIds, RenewalView ticket, OrderDon sourceOrder) {
|
|
private void markGptApiQuotaReceiveStatus(List<Long> userIds, RenewalView ticket, OrderDon sourceOrder) {
|
|
|
boolean yearQuota = isYearRechargeSku(ticket.getGoodsId(), ticket.getMonths(), ticket.getSkuNum());
|
|
boolean yearQuota = isYearRechargeSku(ticket.getGoodsId(), ticket.getMonths(), ticket.getSkuNum());
|
|
|
- ticket.setCanReceiveGptApiQuota(!hasReceivedGptApiQuota(userIds, ticket.getGoodsId(), yearQuota)
|
|
|
|
|
|
|
+ // PLUS 仅 skuNum == 1 的独立规格可领;与实际领取接口共用资格校验。
|
|
|
|
|
+ ticket.setCanReceiveGptApiQuota(isGptApiQuotaSourceTicket(sourceOrder, ticket.getGoodsId(), ticket.getSkuNum())
|
|
|
|
|
+ && !hasReceivedGptApiQuota(userIds, ticket.getGoodsId(), yearQuota)
|
|
|
&& (!yearQuota || hasNewGptApiQuotaPurchase(userIds, ticket.getGoodsId(), sourceOrder)));
|
|
&& (!yearQuota || hasNewGptApiQuotaPurchase(userIds, ticket.getGoodsId(), sourceOrder)));
|
|
|
}
|
|
}
|
|
|
|
|
|