|
@@ -35,6 +35,23 @@ public class DeviceAlgorithmChargingHisController {
|
|
|
return deviceAlgorithmChargingHistoryService.pageByTopMerc(page);
|
|
|
}
|
|
|
|
|
|
+ @PostMapping("pageByTopMercCount")
|
|
|
+ @ApiOperation("加盟商-服务费管理-设备激活费佣金统计")
|
|
|
+ public R<Integer> pageByTopMercCount(@RequestBody @Validated DeviceAlgorithmChargingHistoryDto.PageByTopMerc page) {
|
|
|
+ page.getPage().setSize(-1);
|
|
|
+ page.setCurMercId(MercAuthUtils.getMercId());
|
|
|
+ PageBean<DeviceAlgorithmChargingHistoryDto.PageByTopMercVO> pageVoPageBean = R.feignCheckData(deviceAlgorithmChargingHistoryService.pageByTopMerc(page));
|
|
|
+ List<DeviceAlgorithmChargingHistoryDto.PageByTopMercVO> records = pageVoPageBean.getRecords();
|
|
|
+ int totalAgentMoney = 0;
|
|
|
+ if (CollUtil.isNotEmpty(records)) {
|
|
|
+ for (DeviceAlgorithmChargingHistoryDto.PageByTopMercVO r : records) {
|
|
|
+ totalAgentMoney += r.getAgentMoney();
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return R.ok(totalAgentMoney);
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
@ApiOperation("加盟商-服务费管理-设备激活费明细导出")
|
|
|
@PostMapping("exportPageByTopMerc")
|
|
|
public void exportPageByTopMerc(HttpServletResponse response, @RequestBody @Valid DeviceAlgorithmChargingHistoryDto.PageByTopMerc page) throws IOException {
|