|
|
|
@@ -1535,9 +1535,13 @@ public class WxBillAllServiceImpl implements WxBillAllService { |
|
|
|
pageInfo.getList().stream().forEach(e ->{ |
|
|
|
if(e.get("receivePay")==null){ |
|
|
|
e.put("receivePay",0); |
|
|
|
}else if(e.get("payOut")==null){ |
|
|
|
} |
|
|
|
if(e.get("payOut")==null){ |
|
|
|
e.put("payOut",0); |
|
|
|
} |
|
|
|
BigDecimal r = new BigDecimal(e.get("receivePay")==null?"0":e.get("receivePay").toString()); |
|
|
|
BigDecimal p = new BigDecimal(e.get("payOut")==null?"0":e.get("payOut").toString()); |
|
|
|
e.put("balance",r.subtract(p)); |
|
|
|
}); |
|
|
|
result.put("pageInfo", pageInfo); |
|
|
|
return result; |
|
|
|
@@ -1578,6 +1582,27 @@ public class WxBillAllServiceImpl implements WxBillAllService { |
|
|
|
excelService.exportExcel(list, null, name, OweMerchantVo.class, name + ".xlsx", response, false); |
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|
public void exportReceiveAndPayBillAsPage(WxBillAll record, HttpServletRequest request, HttpServletResponse response) { |
|
|
|
List<Map<String, Object>> data = wxBillAllMapper.getReceiveAndPayBillAsPage(record); |
|
|
|
List<WaitMerchantVo> list = new ArrayList<>(); |
|
|
|
for (Map<String, Object> map : data) { |
|
|
|
WaitMerchantVo oweMerchantVo = new WaitMerchantVo(); |
|
|
|
oweMerchantVo.setLinkPerson((String) map.get("manager")); |
|
|
|
oweMerchantVo.setName((String) map.get("merchantName")); |
|
|
|
oweMerchantVo.setLinkPhone((String) map.get("managerPhone")); |
|
|
|
|
|
|
|
oweMerchantVo.setRentReceivePay(new BigDecimal(subZeroAndDot(map.get("rentReceivePay").toString()))); |
|
|
|
oweMerchantVo.setPropertyReceivePay(new BigDecimal(subZeroAndDot(map.get("propertyReceivePay").toString()))); |
|
|
|
oweMerchantVo.setDepositReceivePay(new BigDecimal(subZeroAndDot(map.get("depositReceivePay").toString()))); |
|
|
|
oweMerchantVo.setOtherReceivePay(new BigDecimal(subZeroAndDot(map.get("otherReceivePay").toString()))); |
|
|
|
oweMerchantVo.setTotalReceivePay(new BigDecimal(subZeroAndDot(map.get("totalReceivePay").toString()))); |
|
|
|
list.add(oweMerchantVo); |
|
|
|
} |
|
|
|
String name = "商户列表"; |
|
|
|
excelService.exportExcel(list, null, name, ReceivedAndPayVo.class, name + ".xlsx", response, false); |
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|
public void exportWaitMerchant(WxBillAll record, HttpServletRequest request, HttpServletResponse response) { |
|
|
|
List<Map<String, Object>> data = wxBillAllMapper.getOweBillAsPage(record); |
|
|
|
|