Commit 6a7f3830 authored by 赵啸非's avatar 赵啸非

添加排号与评价统计报表

parent 33289246
......@@ -44,7 +44,7 @@ public class PhQueueStatServiceImpl extends AbstractCRUDServiceImpl<PhQueueStatD
public Rest<Void> updateSitePhStat(PhQueueStatEntity entity, Context context) {
Calendar calendar = Calendar.getInstance();
calendar.set(entity.getYear(), entity.getMonth()-1, entity.getDay());
calendar.set(entity.getYear(), entity.getMonth() - 1, entity.getDay());
SimpleDateFormat date = new SimpleDateFormat("yyyy-MM-dd");//yyyy-年,MM-月,dd-日,HH-时,mm-分,ss-秒
String currentDate = date.format(calendar.getTime());
......@@ -116,6 +116,7 @@ public class PhQueueStatServiceImpl extends AbstractCRUDServiceImpl<PhQueueStatD
Map<String, List<PhQueueEntity>> collect = phQueueEntities.stream().collect(Collectors.groupingBy(x -> x.getSectionName()));
collect.entrySet().stream().forEach(item -> {
String sectionName = item.getKey();
if (ObjectUtils.isEmpty(sectionName)) return;
List<PhQueueEntity> value = item.getValue();
Double intAvg = value.stream().mapToInt(e -> e.getWaitTime()).average().orElse(0D);
......@@ -161,6 +162,7 @@ public class PhQueueStatServiceImpl extends AbstractCRUDServiceImpl<PhQueueStatD
Map<String, List<PhQueueEntity>> collect = phQueueEntities.stream().collect(Collectors.groupingBy(x -> x.getSectionName()));
collect.entrySet().stream().forEach(item -> {
String hallName = item.getKey();
if(ObjectUtils.isEmpty(hallName)) return;
List<PhQueueEntity> value = item.getValue();
Double intAvg = value.stream().mapToInt(e -> e.getWaitTime()).average().orElse(0D);
log.info("更新站点评价统计数据,站点名称:{},日期:{},大厅:{},评价数量:{}", entity.getSiteName(), currentDate, entity.getHallName(), phQueueEntities.size());
......@@ -205,6 +207,7 @@ public class PhQueueStatServiceImpl extends AbstractCRUDServiceImpl<PhQueueStatD
Map<String, List<PhQueueEntity>> collect = phQueueEntities.stream().collect(Collectors.groupingBy(x -> x.getSectionName()));
collect.entrySet().stream().forEach(item -> {
String bussiness = item.getKey();
if(ObjectUtils.isEmpty(bussiness)) return;
List<PhQueueEntity> value = item.getValue();
Double intAvg = value.stream().mapToInt(e -> e.getWaitTime()).average().orElse(0D);
log.info("更新站点评价统计数据,站点名称:{},日期:{},业务:{},评价数量:{}", entity.getSiteName(), currentDate, entity.getBusiness(), phQueueEntities.size());
......@@ -248,6 +251,7 @@ public class PhQueueStatServiceImpl extends AbstractCRUDServiceImpl<PhQueueStatD
Map<String, List<PhQueueEntity>> collect = phQueueEntities.stream().collect(Collectors.groupingBy(x -> x.getSectionName()));
collect.entrySet().stream().forEach(item -> {
String window = item.getKey();
if(ObjectUtils.isEmpty(window))return;
List<PhQueueEntity> value = item.getValue();
Double intAvg = value.stream().mapToInt(e -> e.getWaitTime()).average().orElse(0D);
log.info("更新站点评价统计数据,站点名称:{},日期:{},业务:{},评价数量:{}", entity.getSiteName(), currentDate, entity.getBusiness(), phQueueEntities.size());
......
......@@ -57,7 +57,7 @@ Content-Type: application/json
{
"taketimeStart": "2023-04-01",
"taketimeEnd": "2023-04-03"
"taketimeEnd": "2023-04-01"
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment