From 04aa2bfc5c843e769b6875f38ab0fc78793d38cb Mon Sep 17 00:00:00 2001 From: Sum1Dream <418471657@qq.com> Date: Wed, 6 Apr 2022 11:08:02 +0800 Subject: [PATCH] 1 --- .../java/com/bweb/controller/HighOrderController.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/hai-bweb/src/main/java/com/bweb/controller/HighOrderController.java b/hai-bweb/src/main/java/com/bweb/controller/HighOrderController.java index 1651da61..4dfc4e1e 100644 --- a/hai-bweb/src/main/java/com/bweb/controller/HighOrderController.java +++ b/hai-bweb/src/main/java/com/bweb/controller/HighOrderController.java @@ -835,9 +835,12 @@ public class HighOrderController { @RequestMapping(value = "/TyOrderStatistics", method = RequestMethod.POST) @ResponseBody @ApiOperation(value = "团油订单统计") - public ResponseData TyOrderStatistics(@RequestBody JSONObject object) { + public ResponseData TyOrderStatistics(@RequestBody JSONObject object,HttpServletRequest request) { try { + SessionObject sessionObject = userCenter.getSessionObject(request); + UserInfoModel userInfoModel = (UserInfoModel) sessionObject.getObject(); + Map map = new HashMap<>(); Map mapSam = new HashMap<>(); Map mapOrg = new HashMap<>(); @@ -866,7 +869,7 @@ public class HighOrderController { salesmanIds.setLength(0); // 查询业务员 mapOrg.put("tyAgentId" , object.getInteger("agentId")); - List salesmanList = highTySalesmanService.getSalesmanList(mapSam); + List salesmanList = highTySalesmanService.getSalesmanList(mapOrg); for (HighTySalesman salesman: salesmanList) { salesmanIds.append(salesman.getId()).append(","); } @@ -877,6 +880,8 @@ public class HighOrderController { salesmanIds.setLength(0); salesmanIds.append(object.getInteger("gasSalesmanId")); + } else if (!(userInfoModel.getSecRole().getRoleType() == 5 && userInfoModel.getSecUser().getAdminFlag() ==1)){ + salesmanIds.append(0); } if (salesmanIds.length() == 0) {