Browse Source

人房统计

feature/teamB_zz_wgh
sunyuchao 3 years ago
parent
commit
05ec87c4c6
  1. 2
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerAgencyController.java
  2. 8
      epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java

2
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerAgencyController.java

@ -444,7 +444,7 @@ public class CustomerAgencyController {
* @Author sun
* @Description 获取当前组织及下级无效组织网格Id列表
**/
@GetMapping("getDelAgencyGridIdList/{agencyId}")
@PostMapping("getDelAgencyGridIdList/{agencyId}")
public Result<DelAgencyGridIdResultDTO> getDelAgencyGridIdList(@PathVariable("agencyId") String agencyId) {
return new Result<DelAgencyGridIdResultDTO>().ok(customerAgencyService.getDelAgencyGridIdList(agencyId));
}

8
epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java

@ -1857,15 +1857,19 @@ public class IcResiUserServiceImpl extends BaseServiceImpl<IcResiUserDao, IcResi
List<UserChartResultDTO> list = baseDao.userChart(formDTO.getOrgId(), formDTO.getOrgType(), formDTO.getAgencyIdList(), formDTO.getGridIdList());
//3.汇总数据
AtomicInteger userTotal = new AtomicInteger();
AtomicInteger czUserTotal = new AtomicInteger();
AtomicInteger ldUserTotal = new AtomicInteger();
list.forEach(l -> {
userTotal.addAndGet(l.getNum());
if ("0".equals(l.getIsFloating())) {
resultDTO.setCzUserTotal(l.getNum());
czUserTotal.addAndGet(l.getNum());
} else {
resultDTO.setLdUserTotal(l.getNum());
ldUserTotal.addAndGet(l.getNum());
}
});
resultDTO.setUserTotal(userTotal.get());
resultDTO.setCzUserTotal(czUserTotal.get());
resultDTO.setLdUserTotal(ldUserTotal.get());
resultDTO.setCzUserRatio(Double.valueOf((resultDTO.getUserTotal() == 0 || resultDTO.getCzUserTotal() > resultDTO.getUserTotal()) ? "0" : numberFormat.format(((float) resultDTO.getCzUserTotal() / (float) resultDTO.getUserTotal()) * 100)));
resultDTO.setLdUserRatio(Double.valueOf((resultDTO.getUserTotal() == 0 || resultDTO.getLdUserTotal() > resultDTO.getUserTotal()) ? "0" : numberFormat.format(((float) resultDTO.getLdUserTotal() / (float) resultDTO.getUserTotal()) * 100)));
resultDTO.setOrgId(formDTO.getOrgId());

Loading…
Cancel
Save