| | |
| | | @ApiImplicitParam(name = "tier", value = "数据层级(2=区县,3=街道,4=社区)", required = true, dataType = "int"), |
| | | }) |
| | | @OperLog(operModul = "三个身边后台",operType = 0,businessType = "获取行政区划层级联动数据") |
| | | public R<List<Map<String, Object>>> getAdministrativeDivision(@PathVariable("id") String id, @PathVariable("tier") Integer tier){ |
| | | List<Map<String, Object>> list = new ArrayList<>(); |
| | | public R<List<Map<String, String>>> getAdministrativeDivision(@PathVariable("id") String id, @PathVariable("tier") Integer tier){ |
| | | List<Map<String, String>> list = new ArrayList<>(); |
| | | //区县 |
| | | if(2 == tier){ |
| | | list = systemUserService.getRegion("510400"); |
| | |
| | | * @param pcode |
| | | * @return |
| | | */ |
| | | List<Map<String, Object>> getRegion(@Param("pcode") String pcode); |
| | | List<Map<String, String>> getRegion(@Param("pcode") String pcode); |
| | | |
| | | /** |
| | | * 获取街道数据 |
| | | * @param areaCode |
| | | * @return |
| | | */ |
| | | List<Map<String, Object>> getStreet(@Param("areaCode") String areaCode); |
| | | List<Map<String, String>> getStreet(@Param("areaCode") String areaCode); |
| | | |
| | | |
| | | /** |
| | |
| | | * @param streetId |
| | | * @return |
| | | */ |
| | | List<Map<String, Object>> getCommunity(@Param("streetId") String streetId); |
| | | List<Map<String, String>> getCommunity(@Param("streetId") String streetId); |
| | | } |
| | |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.panzhihua.common.model.vos.sangeshenbian.SystemUserVo; |
| | | import com.panzhihua.sangeshenbian.model.entity.SystemUser; |
| | | import com.panzhihua.sangeshenbian.warpper.SystemUserList; |
| | | import com.panzhihua.sangeshenbian.warpper.SystemUserListVo; |
| | |
| | | |
| | | /** |
| | | * 获取行政区划数据 |
| | | * |
| | | * @param pcode |
| | | * @return |
| | | */ |
| | | List<Map<String, Object>> getRegion(String pcode); |
| | | List<Map<String, String>> getRegion(String pcode); |
| | | |
| | | |
| | | /** |
| | | * 获取街道数据 |
| | | * |
| | | * @param areaCode |
| | | * @return |
| | | */ |
| | | List<Map<String, Object>> getStreet(String areaCode); |
| | | List<Map<String, String>> getStreet(String areaCode); |
| | | |
| | | |
| | | /** |
| | | * 获取社区数据 |
| | | * |
| | | * @param streetId |
| | | * @return |
| | | */ |
| | | List<Map<String, Object>> getCommunity(String streetId); |
| | | List<Map<String, String>> getCommunity(String streetId); |
| | | } |
| | |
| | | import com.panzhihua.sangeshenbian.warpper.SystemUserListVo; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.Optional; |
| | |
| | | |
| | | /** |
| | | * 获取行政区划数据 |
| | | * |
| | | * @param pcode |
| | | * @return |
| | | */ |
| | | @Override |
| | | public List<Map<String, Object>> getRegion(String pcode) { |
| | | public List<Map<String, String>> getRegion(String pcode) { |
| | | return this.baseMapper.getRegion(pcode); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 获取街道数据 |
| | | * |
| | | * @param areaCode |
| | | * @return |
| | | */ |
| | | @Override |
| | | public List<Map<String, Object>> getStreet(String areaCode) { |
| | | public List<Map<String, String>> getStreet(String areaCode) { |
| | | return this.baseMapper.getStreet(areaCode); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 获取社区数据 |
| | | * |
| | | * @param streetId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public List<Map<String, Object>> getCommunity(String streetId) { |
| | | public List<Map<String, String>> getCommunity(String streetId) { |
| | | return this.baseMapper.getCommunity(streetId); |
| | | } |
| | | } |