|
@@ -194,21 +194,28 @@ public class GiftOrderService {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
int holdDays;
|
|
int holdDays;
|
|
|
- if (asset.getSource() == AssetSource.GIFT) {
|
|
|
|
|
- LocalDateTime localDateTime = asset.getCreatedAt();
|
|
|
|
|
- LocalDateTime gift_change_time = LocalDateTime
|
|
|
|
|
- .parse(sysConfigService.getString("gift_change_time"), DateTimeFormatter
|
|
|
|
|
- .ofPattern("yyyy-MM-dd HH:mm:ss"));
|
|
|
|
|
- if (localDateTime.isBefore(gift_change_time)) {
|
|
|
|
|
- holdDays = 20;
|
|
|
|
|
- } else {
|
|
|
|
|
- holdDays = sysConfigService.getInt("gift_days");
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ if (asset.getType().equals(CollectionType.DOMAIN)) {
|
|
|
|
|
+ holdDays = sysConfigService.getInt("domain_gift");
|
|
|
} else {
|
|
} else {
|
|
|
- if (ObjectUtils.isEmpty(asset.getHoldDays())) {
|
|
|
|
|
- holdDays = sysConfigService.getInt("hold_days");
|
|
|
|
|
|
|
+ if (asset.getSource() == AssetSource.GIFT) {
|
|
|
|
|
+
|
|
|
|
|
+ LocalDateTime localDateTime = asset.getCreatedAt();
|
|
|
|
|
+ LocalDateTime gift_change_time = LocalDateTime
|
|
|
|
|
+ .parse(sysConfigService.getString("gift_change_time"), DateTimeFormatter
|
|
|
|
|
+ .ofPattern("yyyy-MM-dd HH:mm:ss"));
|
|
|
|
|
+ if (localDateTime.isBefore(gift_change_time)) {
|
|
|
|
|
+ holdDays = 20;
|
|
|
|
|
+ } else {
|
|
|
|
|
+ holdDays = sysConfigService.getInt("gift_days");
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
} else {
|
|
} else {
|
|
|
- holdDays = asset.getHoldDays();
|
|
|
|
|
|
|
+ if (ObjectUtils.isEmpty(asset.getHoldDays())) {
|
|
|
|
|
+ holdDays = sysConfigService.getInt("hold_days");
|
|
|
|
|
+ } else {
|
|
|
|
|
+ holdDays = asset.getHoldDays();
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|