Commit 79976dad authored by caotao's avatar caotao

1.修改获取区域公司与经销商的接口返回。

parent b08c6e09
...@@ -364,11 +364,18 @@ public class JpStationController extends BaseController { ...@@ -364,11 +364,18 @@ public class JpStationController extends BaseController {
@ApiOperation(httpMethod = "GET",value = "查询当前登录人权限区域公司", notes = "查询当前登录人权限区域公司") @ApiOperation(httpMethod = "GET",value = "查询当前登录人权限区域公司", notes = "查询当前登录人权限区域公司")
@GetMapping(value = "/getRegion") @GetMapping(value = "/getRegion")
@UserLimits @UserLimits
public ResponseModel< List<DropDown>> getRegion() { public ResponseModel<List<Map<String,String>>> getRegion() {
List<DropDown> list= jpStationMapper.getRegion(); List<DropDown> list= jpStationMapper.getRegion();
List<Map<String,String>> result = new ArrayList<>();
return ResponseHelper.buildResponse(list); list.forEach(dropDown -> {
Map<String,String> item = new HashMap<>();
item.put("name",dropDown.getName());
item.put("value",dropDown.getOrgCode());
result.add(item);
});
return ResponseHelper.buildResponse(result);
} }
...@@ -377,9 +384,16 @@ public class JpStationController extends BaseController { ...@@ -377,9 +384,16 @@ public class JpStationController extends BaseController {
@ApiOperation(httpMethod = "GET",value = "查询当前登录人权限经销商", notes = "查询当前登录人权限经销商") @ApiOperation(httpMethod = "GET",value = "查询当前登录人权限经销商", notes = "查询当前登录人权限经销商")
@GetMapping(value = "/getDealer") @GetMapping(value = "/getDealer")
@UserLimits @UserLimits
public ResponseModel<List<DropDown>> getDealer(String regionalCompaniesCode ) { public ResponseModel<List<Map<String,String>>> getDealer(String regionalCompaniesCode ) {
List<DropDown> list= jpStationMapper.getDealer(regionalCompaniesCode); List<DropDown> list= jpStationMapper.getDealer(regionalCompaniesCode);
return ResponseHelper.buildResponse(list); List<Map<String,String>> result = new ArrayList<>();
list.forEach(dropDown -> {
Map<String,String> item = new HashMap<>();
item.put("name",dropDown.getName());
item.put("value",dropDown.getOrgCode());
result.add(item);
});
return ResponseHelper.buildResponse(result);
} }
//电站发电量统计 //电站发电量统计
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment