From dea2325896c7f8bd7df5107569b71d15fede79c7 Mon Sep 17 00:00:00 2001
From: xiaogang <905166056@qq.com>
Date: 星期四, 22 九月 2022 20:11:55 +0800
Subject: [PATCH] 1、优化图片异步上传2、bug修复3、合同bug修复4、车场相关问题

---
 service-user/src/main/java/com/java110/user/cmd/user/QueryStaffInfosCmd.java |   37 -------------------------------------
 1 files changed, 0 insertions(+), 37 deletions(-)

diff --git a/service-user/src/main/java/com/java110/user/cmd/user/QueryStaffInfosCmd.java b/service-user/src/main/java/com/java110/user/cmd/user/QueryStaffInfosCmd.java
index 92030c3..1350bdd 100644
--- a/service-user/src/main/java/com/java110/user/cmd/user/QueryStaffInfosCmd.java
+++ b/service-user/src/main/java/com/java110/user/cmd/user/QueryStaffInfosCmd.java
@@ -89,9 +89,6 @@
     @Autowired
     private IOrgStaffRelInnerServiceSMO iOrgStaffRelInnerServiceSMO;
 
-
-
-
     @Override
     public void validate(CmdEvent event, ICmdDataFlowContext context, JSONObject reqJson) throws CmdException {
         Assert.hasKeyAndValue(reqJson, "page", "璇锋眰鎶ユ枃涓湭鍖呭惈page鑺傜偣");
@@ -107,8 +104,6 @@
     public void doCmd(CmdEvent event, ICmdDataFlowContext context, JSONObject reqJson) throws CmdException {
         UserDto userDto = BeanConvertUtil.covertBean(reqJson, UserDto.class);
         String userId = context.getReqHeaders().get("user-id");
-
-
         // 鍒ゆ柇鏄笉鏄鐞嗗憳锛岀鐞嗗憳鍙嶉 鐗╀笟 鐨勬墍瑙掕壊
         UserDto userDto1 = new UserDto();
         userDto1.setUserId(userId);
@@ -139,11 +134,8 @@
                 }
             }
         }
-
         int count = userInnerServiceSMOImpl.getStaffCount(userDto);
-
         List<ApiStaffDataVo> staffs = new ArrayList<>();
-
         if (count > 0) {
             List<ApiStaffDataVo> staffList = BeanConvertUtil.covertBeanList(userInnerServiceSMOImpl.getStaffs(userDto), ApiStaffDataVo.class);
             for (ApiStaffDataVo apiStaffDataVo : staffList) {
@@ -165,15 +157,11 @@
         } else {
             staffs = new ArrayList<>();
         }
-
         ApiStaffVo apiStaffVo = new ApiStaffVo();
-
         apiStaffVo.setTotal(count);
         apiStaffVo.setRecords((int) Math.ceil((double) count / (double) reqJson.getInteger("row")));
         apiStaffVo.setStaffs(staffs);
-
         ResponseEntity<String> responseEntity = new ResponseEntity<String>(JSONObject.toJSONString(apiStaffVo), HttpStatus.OK);
-
         context.setResponseEntity(responseEntity);
     }
 
@@ -181,12 +169,10 @@
         if (staffs == null || staffs.size() < 1) {
             return;
         }
-
         List<String> staffIds = new ArrayList<>();
         for (ApiStaffDataVo apiStaffDataVo : staffs) {
             staffIds.add(apiStaffDataVo.getUserId());
         }
-
         OrgDto orgDto = new OrgDto();
         orgDto.setStoreId(storeId);
         List<OrgDto> orgDtos = orgV1InnerServiceSMOImpl.queryOrgs(orgDto);
@@ -197,11 +183,9 @@
         orgStaffRelDto.setStaffIds(staffIds.toArray(new String[staffIds.size()]));
         orgStaffRelDto.setStoreId(storeId);
         List<OrgStaffRelDto> orgStaffRels = orgStaffRelV1InnerServiceSMOImpl.queryOrgStaffRels(orgStaffRelDto);
-
         if (orgStaffRels == null || orgStaffRels.size() < 1) {
             return;
         }
-
         for (ApiStaffDataVo apiStaffDataVo : staffs) {
             for (OrgStaffRelDto tmpOrgStaffRelDto : orgStaffRels) {
                 if (!apiStaffDataVo.getUserId().equals(tmpOrgStaffRelDto.getStaffId())) {
@@ -217,19 +201,14 @@
                 apiStaffDataVo.setParentTwoOrgId(orgs.get(0).getParentOrgId());
             }
         }
-
         for (ApiStaffDataVo apiStaffDataVo : staffs) {
             if (StringUtil.isEmpty(apiStaffDataVo.getOrgId())) {
                 continue;
             }
             apiStaffDataVo.setParentOrgId(apiStaffDataVo.getOrgId());
-
             findParents(apiStaffDataVo, orgDtos, null, 0);
-
         }
-
     }
-
 
     private void findParents(ApiStaffDataVo apiStaffDataVo, List<OrgDto> orgDtos, OrgDto curOrgDto, int orgDeep) {
         for (OrgDto orgDto : orgDtos) {
@@ -237,14 +216,11 @@
             if (!apiStaffDataVo.getParentOrgId().equals(orgDto.getOrgId())) { // 浠栬嚜宸辫烦杩�
                 continue;
             }
-
             //濡傛灉鍒颁竴绾� 灏辩粨鏉�
             if (OrgDto.ORG_LEVEL_STORE.equals(apiStaffDataVo.getOrgLevel())) {
                 continue;
             }
-
             apiStaffDataVo.setParentOrgId(orgDto.getParentOrgId());
-
             if (StringUtil.isEmpty(apiStaffDataVo.getOrgName())) {
                 apiStaffDataVo.setOrgName(orgDto.getOrgName());
                 continue;
@@ -252,25 +228,19 @@
             apiStaffDataVo.setOrgName(orgDto.getOrgName() + " / " + apiStaffDataVo.getOrgName());
             apiStaffDataVo.setOrgLevel(orgDto.getOrgLevel());
         }
-
         if (curOrgDto != null && OrgDto.ORG_LEVEL_STORE.equals(curOrgDto.getOrgLevel())) {
             return;
         }
-
         if (curOrgDto != null && curOrgDto.getParentOrgId().equals(curOrgDto.getOrgId())) {
             return;
         }
-
         if (curOrgDto != null && "-1".equals(curOrgDto.getParentOrgId())) {
             return;
         }
-
         orgDeep += 1;
-
         if (orgDeep > 20) {
             return;
         }
-
         findParents(apiStaffDataVo, orgDtos, curOrgDto, orgDeep);
     }
 
@@ -280,7 +250,6 @@
      * @param staffs
      */
     private void refreshInitials(List<ApiStaffDataVo> staffs) {
-
         for (ApiStaffDataVo staffDataVo : staffs) {
             if (StringUtil.isEmpty(staffDataVo.getName())) {
                 continue;
@@ -313,7 +282,6 @@
                     orgDto1.setOrgId(orgDto.getParentOrgId());
                     List<OrgDto> orgDtoList1 = orgV1InnerServiceSMOImpl.queryOrgs(orgDto1);
                     findCompany(haveOrgList, orgDtoList1);
-
                     //涓嬩竴涓骇鍒�
                     if (!"2".equals(orgDto.getOrgLevel())) {
                         OrgDto orgDto3 = new OrgDto();
@@ -323,13 +291,8 @@
                             haveOrgList.add(orgDto4.getOrgId());
                         }
                     }
-
                 }
-
             }
         }
-
-
     }
-
 }

--
Gitblit v1.8.0