|
@@ -682,4 +682,40 @@ public class RecruitmentApiController {
|
|
|
|
|
|
return msgResult;
|
|
|
}
|
|
|
+
|
|
|
+ @PostMapping("getCompanyList")
|
|
|
+ @ApiOperation(value = "企业名录")
|
|
|
+ @ApiImplicitParams({
|
|
|
+ @ApiImplicitParam(name = "companyName", value = "公司名", required = false, paramType = "query"),
|
|
|
+ })
|
|
|
+ public MessageResult<Map> getCompanyList(
|
|
|
+ String token,String companyName,
|
|
|
+ @RequestParam(value="pageIndex",defaultValue="1") int pageIndex,
|
|
|
+ @RequestParam(value="pageSize",defaultValue="10") int pageSize,
|
|
|
+ @RequestAttribute String subject) {
|
|
|
+ System.out.println(subject);
|
|
|
+
|
|
|
+ MessageResult<Map> msgResult = new MessageResult<>();
|
|
|
+
|
|
|
+ Map<String,Object> searchParams = new HashMap<>();
|
|
|
+
|
|
|
+ List<Sort> sortList = new ArrayList<>();
|
|
|
+ sortList.add(new Sort("create_time","desc"));
|
|
|
+
|
|
|
+ if (StringUtils.isNotEmpty(companyName)) {
|
|
|
+ searchParams.put("companyName",companyName+"%");
|
|
|
+ }
|
|
|
+
|
|
|
+ Page<Company> page = companyService.pageSearch(searchParams,pageIndex,pageSize,true,sortList);
|
|
|
+
|
|
|
+ for (Company company:page) {
|
|
|
+ company.setScaleName(dataDictionaryService.getName(company.getScale()));
|
|
|
+ company.setIndustry(dataDictionaryService.getName(company.getIndustry()));
|
|
|
+ }
|
|
|
+
|
|
|
+ msgResult.setResult(true);
|
|
|
+ msgResult.setData(PojoUtils.pageWrapper(page));
|
|
|
+
|
|
|
+ return msgResult;
|
|
|
+ }
|
|
|
}
|