Commit 5bcdefb0 authored by 赵啸非's avatar 赵啸非

修改评价统计更新与组合查询

parent 90f73fe8
......@@ -12,6 +12,7 @@ import com.mortals.framework.util.ThreadPool;
import com.mortals.framework.web.BaseCRUDJsonBodyMappingController;
import com.mortals.xhx.base.system.param.service.ParamService;
import com.mortals.xhx.common.code.GroupListEnum;
import com.mortals.xhx.common.key.RedisKey;
import com.mortals.xhx.common.pdu.RespData;
import com.mortals.xhx.common.pdu.site.SitePdu;
import com.mortals.xhx.feign.site.ISiteFeign;
......@@ -29,10 +30,7 @@ import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.*;
import java.util.stream.Collectors;
/**
......@@ -66,6 +64,7 @@ public class PhQueueStatController extends BaseCRUDJsonBodyMappingController<PhQ
//通过站点 查询存在的部门 大厅等
Object siteId = model.get("siteId");
if (!ObjectUtils.isEmpty(siteId)) {
/*
PhQueueStatQuery queueStatQuery = new PhQueueStatQuery();
queueStatQuery.setSiteId((Long) siteId);
List<PhQueueStatEntity> phQueueStatEntities = this.service.find(queueStatQuery, context);
......@@ -74,7 +73,20 @@ public class PhQueueStatController extends BaseCRUDJsonBodyMappingController<PhQ
Map<String, String> windowFromnumMap = phQueueStatEntities.stream().filter(f -> !ObjectUtils.isEmpty(f.getWindowFromnum())).collect(Collectors.toMap(PhQueueStatEntity::getWindowFromnum, PhQueueStatEntity::getWindowFromnum, (k1, k2) -> k2));
Map<String, String> bussinessMap = phQueueStatEntities.stream().filter(f -> !ObjectUtils.isEmpty(f.getBusiness())).collect(Collectors.toMap(PhQueueStatEntity::getBusiness, PhQueueStatEntity::getBusiness, (k1, k2) -> k2));
this.addDict(model, "sectionNameList", sectionNameMap);
*/
Map<String, String> sectionNameMap = cacheService.hgetAll(RedisKey.KEY_SITE_QUEUE_SECTIONNAME_CHCHE + siteId);
Map<String, String> hallNameMap = cacheService.hgetAll(RedisKey.KEY_SITE_QUEUE_HALLNAME_CHCHE + siteId);
Map<String, String> windowFromnumMap = cacheService.hgetAll(RedisKey.KEY_SITE_QUEUE_WINDOW_CHCHE + siteId);
Map<String, String> bussinessMap = cacheService.hgetAll(RedisKey.KEY_SITE_QUEUE_BUSNIESS_CHCHE + siteId);
Map<String, Integer> m1 = sectionNameMap.entrySet().stream()
.sorted((e1, e2) -> Integer.compare(Integer.parseInt(e1.getValue()), Integer.parseInt(e2.getValue())))
.collect(Collectors.toMap(Map.Entry::getKey,
y->Integer.parseInt(y.getValue()),(e1, e2) -> e1,
LinkedHashMap::new));
this.addDict(model, "sectionNameList", m1);
this.addDict(model, "hallNameList", hallNameMap);
this.addDict(model, "windowFromnumList", windowFromnumMap);
this.addDict(model, "businessList", bussinessMap);
......
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