Commit 23472276 authored by 李腾威's avatar 李腾威

修改接口

parent d7542d99
...@@ -11,8 +11,10 @@ import com.yeejoin.amos.boot.module.jcs.api.vo.OrgPersonFormVo; ...@@ -11,8 +11,10 @@ import com.yeejoin.amos.boot.module.jcs.api.vo.OrgPersonFormVo;
import com.yeejoin.amos.boot.module.jcs.api.vo.OrgPersonVo; import com.yeejoin.amos.boot.module.jcs.api.vo.OrgPersonVo;
import com.yeejoin.amos.boot.module.jcs.api.vo.OrgUsrFormVo; import com.yeejoin.amos.boot.module.jcs.api.vo.OrgUsrFormVo;
import com.yeejoin.amos.boot.module.jcs.api.vo.OrgUsrVo; import com.yeejoin.amos.boot.module.jcs.api.vo.OrgUsrVo;
import org.springframework.web.bind.annotation.PathVariable;
import javax.servlet.http.HttpServletRequest;
import java.util.Collection; import java.util.Collection;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -141,5 +143,5 @@ public interface IOrgUsrService { ...@@ -141,5 +143,5 @@ public interface IOrgUsrService {
OrgDepartmentFormVo selectDepartmentById(Long id) throws Exception; OrgDepartmentFormVo selectDepartmentById(Long id) throws Exception;
List<Map<String, Object>> selectForShowByListId(List<Long> ids) throws Exception;
} }
...@@ -201,12 +201,7 @@ public class OrgPersonController { ...@@ -201,12 +201,7 @@ public class OrgPersonController {
@RequestMapping(value = "/showPersonList/{ids}", method = RequestMethod.GET) @RequestMapping(value = "/showPersonList/{ids}", method = RequestMethod.GET)
@ApiOperation(httpMethod = "GET", value = "获取人员列表详情(map类型)", notes = "获取人员详情") @ApiOperation(httpMethod = "GET", value = "获取人员列表详情(map类型)", notes = "获取人员详情")
public ResponseModel selectForShowByListId(HttpServletRequest request, @PathVariable List<Long> ids) throws Exception { public ResponseModel selectForShowByListId(HttpServletRequest request, @PathVariable List<Long> ids) throws Exception {
List<Map<String, Object>> personResult = new ArrayList<>(); return ResponseHelper.buildResponse(iOrgUsrService.selectForShowByListId(ids)
for (int i = 0; i < ids.size(); i++) { );
OrgUsr orgUsr = iOrgUsrService.getById(ids.get(i));
Map<String, Object> result = iOrgUsrService.selectForShowById(orgUsr, ids.get(i));
personResult.add(result);
}
return ResponseHelper.buildResponse(personResult);
} }
} }
...@@ -575,4 +575,15 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp ...@@ -575,4 +575,15 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp
BeanUtils.copyProperties(orgUsr, orgDepartmentFormVo); BeanUtils.copyProperties(orgUsr, orgDepartmentFormVo);
return orgDepartmentFormVo; return orgDepartmentFormVo;
} }
@Override
public List<Map<String, Object>> selectForShowByListId(List<Long> ids) throws Exception {
List<Map<String, Object>> personResult = new ArrayList<>();
for (int i = 0; i < ids.size(); i++) {
OrgUsr orgUsr = getById(ids.get(i));
Map<String, Object> result = selectForShowById(orgUsr, ids.get(i));
personResult.add(result);
}
return personResult;
}
} }
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