| | |
| | | parent_code as parentId, |
| | | name, |
| | | remark aoiCode |
| | | FROM blade_region where district_code = '361102000000' |
| | | FROM blade_region where district_code like concat('361102','%') |
| | | union all |
| | | ( |
| | | select |
| | |
| | | name, |
| | | aoi_code aoiCode |
| | | from jczz_district |
| | | where is_deleted = 0 |
| | | where is_deleted = 0 and community_code like concat('361102','%') |
| | | <if test="district.districtIdList!=null and district.districtIdList.size() > 0"> |
| | | and id in |
| | | <foreach collection="district.districtIdList" item="item" separator ="," open="(" close=")"> |
| | |
| | | and jr.community_code like concat('%',#{rotation.regionCode},'%') |
| | | </if> |
| | | |
| | | <if test="rotation.rotationRange != null and rotation.rotationRange != ''"> and jr.rotation_range = #{rotation.rotationRange}</if> |
| | | <if test="rotation.rotationRange != null and rotation.rotationRange != ''">and jr.rotation_range = |
| | | #{rotation.rotationRange} |
| | | </if> |
| | | <if test="rotation.articleId != null "> and jr.article_id = #{rotation.articleId}</if> |
| | | <if test="rotation.publicFlag != null "> and jr.public_flag = #{rotation.publicFlag}</if> |
| | | |
| | |
| | | and (jr.rotation_range like |
| | | <foreach collection="rotation.districtIdList" separator=" or jr.rotation_range like" item="id">'%${id}%' |
| | | </foreach> |
| | | ) |
| | | ) or jr.rotation_range is null |
| | | </if> |
| | | |
| | | <if test="isAdministrator==2"> |
| | |
| | | </if> |
| | | <if test="rotation.roleName=='inhabitant'"> |
| | | and jr.type = 3 |
| | | <if test="rotation.districtIdList == null "> |
| | | and jr.rotation_range is null |
| | | </if> |
| | | </if> |
| | | </when> |
| | | <otherwise> |
| | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.springblade.common.param.CommonParamSet; |
| | | import org.springblade.common.utils.AuthUtils; |
| | | import org.springblade.common.utils.RoleUtil; |
| | | import org.springblade.common.utils.SpringUtils; |
| | | import org.springblade.core.secure.utils.AuthUtil; |
| | |
| | | if (rotationVOList.size() == 0) { |
| | | // 如果没有对应的轮播图,则采用系统默认的 |
| | | rotation.setType(3); |
| | | rotation.setPublicFlag(2); |
| | | rotation.setDistrictIdList(null); |
| | | rotationVOList = baseMapper.selectRotationPage(page, |
| | | rotation, |
| | | 1, |
| | |
| | | import org.apache.logging.log4j.util.Strings; |
| | | import org.springblade.common.cache.SysCache; |
| | | import org.springblade.common.node.TreeStringNode; |
| | | import org.springblade.common.utils.AuthUtils; |
| | | import org.springblade.common.utils.NodeTreeUtil; |
| | | import org.springblade.core.log.exception.ServiceException; |
| | | import org.springblade.core.secure.utils.AuthUtil; |
| | |
| | | @Override |
| | | public List<TreeStringNode> getTree(RegionParamVO region) { |
| | | List<String> regionChildCodesList = SysCache.getRegionChildCodesByDeptId(AuthUtil.getDeptId(),null); |
| | | Integer isAdministrator = AuthUtil.isAdministrator()==true?1:2; |
| | | Integer isAdministrator = AuthUtils.isAdministratorOrAdmin(AuthUtil.getUserRole()) == true ? 1 : 2; |
| | | if (null!=region.getDeptNature()){ |
| | | // 公安 |
| | | if (region.getDeptNature()==1){ |
| | |
| | | |
| | | /** |
| | | * Ancestors 字段处理 |
| | | * |
| | | * @param region |
| | | */ |
| | | private void setAncestors(Region region) { |
| | |
| | | |
| | | /** |
| | | * 查询下级区域(拼接网格) |
| | | * |
| | | * @param regionCode |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 获取民警下级区域 |
| | | * |
| | | * @param regionCode |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 获取综治下级区域 |
| | | * |
| | | * @param regionCode |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 获取某个父节点下面的所有子节点 |
| | | * |
| | | * @param regionList |
| | | * @param parentCode |
| | | * @param list |