后台-myApi-diamondStat拆分两个时区
This commit is contained in:
@@ -618,12 +618,18 @@ public class MyApiService {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
public void diamondStat(String date) {
|
public void diamondStatAr(String date) {
|
||||||
List<Integer> partitionIds = List.of(PartitionEnum.ARAB.getId(), PartitionEnum.TURKEY.getId());
|
List<Integer> partitionIds = List.of(PartitionEnum.ARAB.getId(), PartitionEnum.TURKEY.getId());
|
||||||
Date now = DateTimeUtil.convertStrToDate(date, DateTimeUtil.DEFAULT_DATE_PATTERN);
|
Date now = DateTimeUtil.convertStrToDate(date, DateTimeUtil.DEFAULT_DATE_PATTERN);
|
||||||
diamondStatService.stat(partitionIds, now);
|
diamondStatService.stat(partitionIds, now);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void diamondStatEn(String date) {
|
||||||
|
List<Integer> partitionIds = List.of(PartitionEnum.ENGLISH.getId(), PartitionEnum.CHINESE.getId(), PartitionEnum.ENGLISH2.getId());
|
||||||
|
Date now = DateTimeUtil.convertStrToDate(date, DateTimeUtil.DEFAULT_DATE_PATTERN);
|
||||||
|
diamondStatService.stat(partitionIds, now);
|
||||||
|
}
|
||||||
|
|
||||||
public void dauStat(String date) {
|
public void dauStat(String date) {
|
||||||
Date now = DateTimeUtil.convertStrToDate(date, DateTimeUtil.DEFAULT_DATE_PATTERN);
|
Date now = DateTimeUtil.convertStrToDate(date, DateTimeUtil.DEFAULT_DATE_PATTERN);
|
||||||
String yesterday = DateTimeUtil.convertDate(DateTimeUtil.addDays(now, -1), DateTimeUtil.DEFAULT_DATE_PATTERN);
|
String yesterday = DateTimeUtil.convertDate(DateTimeUtil.addDays(now, -1), DateTimeUtil.DEFAULT_DATE_PATTERN);
|
||||||
|
@@ -220,12 +220,21 @@ public class MyApiController {
|
|||||||
return BusiResult.success();
|
return BusiResult.success();
|
||||||
}
|
}
|
||||||
|
|
||||||
@GetMapping("/diamondStat")
|
@GetMapping("/diamondStatAr")
|
||||||
public BusiResult<Void> diamondStat(Long roomId, String date) {
|
public BusiResult<Void> diamondStatAr(Long roomId, String date) {
|
||||||
if (null == roomId || !roomId.equals(603L)) {
|
if (null == roomId || !roomId.equals(603L)) {
|
||||||
throw new AdminServiceException(BusiStatus.PARAMERROR);
|
throw new AdminServiceException(BusiStatus.PARAMERROR);
|
||||||
}
|
}
|
||||||
myApiService.diamondStat(date);
|
myApiService.diamondStatAr(date);
|
||||||
|
return BusiResult.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/diamondStatEn")
|
||||||
|
public BusiResult<Void> diamondStatEn(Long roomId, String date) {
|
||||||
|
if (null == roomId || !roomId.equals(603L)) {
|
||||||
|
throw new AdminServiceException(BusiStatus.PARAMERROR);
|
||||||
|
}
|
||||||
|
myApiService.diamondStatEn(date);
|
||||||
return BusiResult.success();
|
return BusiResult.success();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user