From 2b6c540c6b20e04f8b2a05e6f0c22ba5d5016364 Mon Sep 17 00:00:00 2001
From: manailin <261030956@qq.com>
Date: 星期六, 24 九月 2022 14:09:50 +0800
Subject: [PATCH] Merge branch 'huacheng_test' of http://gitlab.nhys.cdnhxx.com/root/zhihuishequ into huacheng_test
---
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActServiceImpl.java | 29 ++++++++++++++++++++++-------
1 files changed, 22 insertions(+), 7 deletions(-)
diff --git a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActServiceImpl.java b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActServiceImpl.java
index ae82b0a..692a957 100644
--- a/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActServiceImpl.java
+++ b/springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComActServiceImpl.java
@@ -7,6 +7,8 @@
import javax.annotation.Resource;
+import com.panzhihua.common.model.vos.community.ComActPasswordVo;
+import com.panzhihua.service_community.util.MyAESUtil;
import org.springframework.beans.BeanUtils;
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
import org.springframework.stereotype.Service;
@@ -147,6 +149,13 @@
ComActVO comActVO = new ComActVO();
BeanUtils.copyProperties(comActDO, comActVO);
comActVO.setAreaName(comActDAO.selectAreaName(comActVO.getAreaCode()));
+ comActVO.setAccount(null);
+ comActVO.setPassword(null);
+ comActVO.setAddress(null);
+ comActVO.setContacts(null);
+ comActVO.setCreateAt(null);
+ comActVO.setState(null);
+ comActVO.setDistance(null);
return R.ok(comActVO);
}
@@ -231,9 +240,9 @@
* @return 社区列表
*/
@Override
- public R getCommunityAllList(String areaCode) {
+ public R getCommunityAllList(String appId) {
// 查询街道列表
- List<StreetAllAppletsVO> streetList = this.comActDAO.getStreetList(areaCode);
+ List<StreetAllAppletsVO> streetList = this.comActDAO.getStreetList(appId);
streetList.forEach(street -> {
// 查询街道下社区列表
List<CommunitySwitchAllAppletsVO> communityList =
@@ -243,8 +252,8 @@
street.setCount(communityList.size());
}
});
-// streetList = streetList.stream().sorted(Comparator.comparing(StreetAllAppletsVO::getCount).reversed())
-// .collect(Collectors.toList());
+ streetList = streetList.stream().sorted(Comparator.comparing(StreetAllAppletsVO::getCount).reversed())
+ .collect(Collectors.toList());
return R.ok(streetList);
}
@@ -256,8 +265,8 @@
* @return 社区列表
*/
@Override
- public R communitySwitchSearchList(String name,String areaCode) {
- return R.ok(this.comActDAO.getCommunityListByName(name,areaCode));
+ public R communitySwitchSearchList(String name,String appId) {
+ return R.ok(this.comActDAO.getCommunityListByName(name,appId));
}
/**
@@ -274,7 +283,13 @@
@Override
public R getCommunityPassword(Long communityId){
- return R.ok(comActDAO.getCommunityPassword(communityId));
+ ComActPasswordVo comActPasswordVo=comActDAO.getCommunityPassword(communityId);
+ try {
+ comActPasswordVo.setPassword(MyAESUtil.Decrypt(comActPasswordVo.getPassword(),"Ryo7M3n8loC5Abcd"));
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+ return R.ok(comActPasswordVo);
}
}
--
Gitblit v1.7.1