| | |
| | | @ApiOperation(value = "中台水库-查询该行政区下的水库", notes = "中台水库-查询该行政区下的水库") |
| | | @GetMapping(value = "/getListByRegion") |
| | | public R getListByRegion(@ApiIgnore @RequestParam Map<String, Object> obj,Query query) { |
| | | String code = obj.get("code").toString(); |
| | | if (code.substring(0,4).indexOf("00") > -1) { |
| | | obj.put("code",code.substring(0,2)); |
| | | } else if (code.substring(0,6).indexOf("00") > -1) { |
| | | obj.put("code",code.substring(0,4)); |
| | | } |
| | | // List<AttResBase> list = attResBaseService.getListByRegion(obj); |
| | | IPage<AttResBase> pageList = attResBaseService.getListByRegion(Condition.getPage(query),obj); |
| | | return R.data(pageList); |
| | | } |
| | |
| | | return R.data(attResBaseService.updateResBaseByGuid(attResBase)); |
| | | } |
| | | |
| | | /** |
| | | * 根据水库编码获取行政区数据 |
| | | * @param guid |
| | | * @return |
| | | */ |
| | | @GetMapping(value = "/getWaterRegionInfoByResGuid") |
| | | public R getWaterRegionInfoByResGuid(String guid) { |
| | | return R.data(attResBaseService.getWaterRegionInfoByResGuid(guid)); |
| | | } |
| | | |
| | | } |