修复秒杀活动时间段为一个时。不显示问题。修复可能会出现的es代码编译问题。improve code
This commit is contained in:
parent
36ce7593a9
commit
6d014a01bc
@ -25,15 +25,6 @@ spring:
|
||||
admin:
|
||||
client:
|
||||
url: http://192.168.0.116:8000
|
||||
# mongodb
|
||||
data:
|
||||
mongodb:
|
||||
uri: 192.168.0.116:27017
|
||||
database: lilishop
|
||||
username: root
|
||||
password: lilishop
|
||||
authentication-database: admin
|
||||
# replica-set-name: mongoreplset
|
||||
cache:
|
||||
type: redis
|
||||
# Redis
|
||||
@ -191,7 +182,6 @@ logging:
|
||||
cn.lili: info
|
||||
# org.hibernate: debug
|
||||
# org.springframework: debug
|
||||
# org.springframework.data.mongodb.core: debug
|
||||
file:
|
||||
# 指定路径
|
||||
path: logs
|
||||
|
@ -124,8 +124,6 @@ public class WalletPlugin implements Payment {
|
||||
//获取支付收银参数
|
||||
CashierParam cashierParam = cashierSupport.cashierParam(payParam);
|
||||
this.callBack(payParam, cashierParam);
|
||||
} catch (Exception e) {
|
||||
throw e;
|
||||
} finally {
|
||||
lock.unlock();
|
||||
}
|
||||
|
@ -338,7 +338,7 @@ public class SeckillApplyServiceImpl extends ServiceImpl<SeckillApplyMapper, Sec
|
||||
Arrays.sort(hoursSored);
|
||||
for (int i = 0; i < hoursSored.length; i++) {
|
||||
SeckillTimelineVO tempTimeline = new SeckillTimelineVO();
|
||||
boolean hoursSoredHour = (hoursSored[i] >= hour || ((i + 1) < hoursSored.length && hoursSored[i + 1] > hour));
|
||||
boolean hoursSoredHour = (hoursSored[i] >= hour || ((i + 1) < hoursSored.length && hoursSored[i + 1] > hour) || hoursSored.length == 1);
|
||||
if (hoursSoredHour) {
|
||||
SimpleDateFormat format = new SimpleDateFormat(DatePattern.NORM_DATE_PATTERN);
|
||||
String date = format.format(new Date());
|
||||
|
@ -240,7 +240,8 @@ public class EsGoodsSearchServiceImpl implements EsGoodsSearchService {
|
||||
|
||||
String brandName = "";
|
||||
if (brandBuckets.get(i).getAggregations() != null && brandBuckets.get(i).getAggregations().get(ATTR_BRAND_NAME) != null) {
|
||||
brandName = this.getAggregationsBrandOptions(brandBuckets.get(i).getAggregations().get(ATTR_BRAND_NAME));
|
||||
ParsedStringTerms aggregation = brandBuckets.get(i).getAggregations().get(ATTR_BRAND_NAME);
|
||||
brandName = this.getAggregationsBrandOptions(aggregation);
|
||||
if (StringUtils.isEmpty(brandName)) {
|
||||
continue;
|
||||
}
|
||||
@ -250,7 +251,8 @@ public class EsGoodsSearchServiceImpl implements EsGoodsSearchService {
|
||||
if (brandUrlBuckets != null && !brandUrlBuckets.isEmpty() &&
|
||||
brandUrlBuckets.get(i).getAggregations() != null &&
|
||||
brandUrlBuckets.get(i).getAggregations().get(ATTR_BRAND_URL) != null) {
|
||||
brandUrl = this.getAggregationsBrandOptions(brandUrlBuckets.get(i).getAggregations().get(ATTR_BRAND_URL));
|
||||
ParsedStringTerms aggregation = brandUrlBuckets.get(i).getAggregations().get(ATTR_BRAND_URL);
|
||||
brandUrl = this.getAggregationsBrandOptions(aggregation);
|
||||
if (StringUtils.isEmpty(brandUrl)) {
|
||||
continue;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user