科室和医案收集里的科室列表一致
This commit is contained in:
@@ -1,5 +1,6 @@
|
|||||||
package com.peanut.modules.common.entity;
|
package com.peanut.modules.common.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableField;
|
||||||
import com.baomidou.mybatisplus.annotation.TableId;
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
import com.baomidou.mybatisplus.annotation.TableLogic;
|
import com.baomidou.mybatisplus.annotation.TableLogic;
|
||||||
import com.baomidou.mybatisplus.annotation.TableName;
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
@@ -22,7 +23,7 @@ public class TaihuTalent implements Serializable {
|
|||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
//科室
|
//科室
|
||||||
private String department;
|
private Integer deptLabelId;
|
||||||
|
|
||||||
//职称
|
//职称
|
||||||
private String title;
|
private String title;
|
||||||
@@ -52,4 +53,7 @@ public class TaihuTalent implements Serializable {
|
|||||||
|
|
||||||
@TableLogic
|
@TableLogic
|
||||||
private Integer delFlag;
|
private Integer delFlag;
|
||||||
|
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String department;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,12 +4,10 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|||||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
import com.github.yulichang.wrapper.MPJLambdaWrapper;
|
import com.github.yulichang.wrapper.MPJLambdaWrapper;
|
||||||
import com.peanut.common.utils.R;
|
import com.peanut.common.utils.R;
|
||||||
import com.peanut.modules.common.entity.CourseEntity;
|
import com.peanut.modules.common.entity.*;
|
||||||
import com.peanut.modules.common.entity.CourseToTaihumed;
|
|
||||||
import com.peanut.modules.common.entity.CourseToTalent;
|
|
||||||
import com.peanut.modules.common.entity.TaihuTalent;
|
|
||||||
import com.peanut.modules.common.service.CourseToTaihumedService;
|
import com.peanut.modules.common.service.CourseToTaihumedService;
|
||||||
import com.peanut.modules.common.service.CourseToTalentService;
|
import com.peanut.modules.common.service.CourseToTalentService;
|
||||||
|
import com.peanut.modules.common.service.MedicalRecordsLabelService;
|
||||||
import com.peanut.modules.common.service.TaihuTalentService;
|
import com.peanut.modules.common.service.TaihuTalentService;
|
||||||
import com.peanut.modules.common.to.ParamTo;
|
import com.peanut.modules.common.to.ParamTo;
|
||||||
import com.peanut.modules.master.service.CourseService;
|
import com.peanut.modules.master.service.CourseService;
|
||||||
@@ -38,6 +36,8 @@ public class TaihuTalentController {
|
|||||||
private CourseToTalentService courseToTalentService;
|
private CourseToTalentService courseToTalentService;
|
||||||
@Autowired
|
@Autowired
|
||||||
private CourseToTaihumedService courseToTaihumedService;
|
private CourseToTaihumedService courseToTaihumedService;
|
||||||
|
@Autowired
|
||||||
|
private MedicalRecordsLabelService medicalRecordsLabelService;
|
||||||
|
|
||||||
|
|
||||||
//太湖英才课程列表
|
//太湖英才课程列表
|
||||||
@@ -108,7 +108,10 @@ public class TaihuTalentController {
|
|||||||
//太湖英才列表
|
//太湖英才列表
|
||||||
@RequestMapping("/getTaihuTalents")
|
@RequestMapping("/getTaihuTalents")
|
||||||
public R getTaihuTalents(@RequestBody Map<String,Object> params){
|
public R getTaihuTalents(@RequestBody Map<String,Object> params){
|
||||||
LambdaQueryWrapper<TaihuTalent> wrapper = new LambdaQueryWrapper<>();
|
MPJLambdaWrapper<TaihuTalent> wrapper = new MPJLambdaWrapper<>();
|
||||||
|
wrapper.leftJoin(MedicalRecordsLabel.class,MedicalRecordsLabel::getId,TaihuTalent::getDeptLabelId);
|
||||||
|
wrapper.selectAll(TaihuTalent.class);
|
||||||
|
wrapper.selectAs(MedicalRecordsLabel::getTitle,TaihuTalent::getDepartment);
|
||||||
wrapper.like(StringUtils.isNotEmpty(params.get("name").toString()),TaihuTalent::getName,params.get("name"));
|
wrapper.like(StringUtils.isNotEmpty(params.get("name").toString()),TaihuTalent::getName,params.get("name"));
|
||||||
wrapper.like(StringUtils.isNotEmpty(params.get("region").toString()),TaihuTalent::getRegion,params.get("region"));
|
wrapper.like(StringUtils.isNotEmpty(params.get("region").toString()),TaihuTalent::getRegion,params.get("region"));
|
||||||
wrapper.orderByDesc(TaihuTalent::getCreateTime);
|
wrapper.orderByDesc(TaihuTalent::getCreateTime);
|
||||||
@@ -145,6 +148,7 @@ public class TaihuTalentController {
|
|||||||
@RequestMapping("/taihuTalentInfo")
|
@RequestMapping("/taihuTalentInfo")
|
||||||
public R taihuTalentInfo(@RequestBody Map<String,Object> params){
|
public R taihuTalentInfo(@RequestBody Map<String,Object> params){
|
||||||
TaihuTalent taihuTalent = taihuTalentService.getById(params.get("id").toString());
|
TaihuTalent taihuTalent = taihuTalentService.getById(params.get("id").toString());
|
||||||
|
taihuTalent.setDepartment(medicalRecordsLabelService.getById(taihuTalent.getDeptLabelId()).getTitle());
|
||||||
return R.ok().put("taihuTalent",taihuTalent);
|
return R.ok().put("taihuTalent",taihuTalent);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -4,10 +4,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|||||||
import com.github.yulichang.wrapper.MPJLambdaWrapper;
|
import com.github.yulichang.wrapper.MPJLambdaWrapper;
|
||||||
import com.peanut.common.utils.R;
|
import com.peanut.common.utils.R;
|
||||||
import com.peanut.modules.common.entity.*;
|
import com.peanut.modules.common.entity.*;
|
||||||
import com.peanut.modules.common.service.MedicalRecordsService;
|
import com.peanut.modules.common.service.*;
|
||||||
import com.peanut.modules.common.service.TaihuTalentService;
|
|
||||||
import com.peanut.modules.common.service.UserCertificateLabelService;
|
|
||||||
import com.peanut.modules.common.service.UserCertificateService;
|
|
||||||
import com.peanut.modules.master.service.CourseService;
|
import com.peanut.modules.master.service.CourseService;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.apache.commons.lang.StringUtils;
|
import org.apache.commons.lang.StringUtils;
|
||||||
@@ -33,15 +30,18 @@ public class TaihuTalentController {
|
|||||||
private CourseService courseService;
|
private CourseService courseService;
|
||||||
@Autowired
|
@Autowired
|
||||||
private MedicalRecordsService medicalRecordsService;
|
private MedicalRecordsService medicalRecordsService;
|
||||||
|
@Autowired
|
||||||
|
private MedicalRecordsLabelService medicalRecordsLabelService;
|
||||||
|
|
||||||
//太湖英才列表
|
//太湖英才列表
|
||||||
@RequestMapping("/getTaihuTalents")
|
@RequestMapping("/getTaihuTalents")
|
||||||
public R getTaihuTalents(@RequestBody Map<String,Object> params){
|
public R getTaihuTalents(@RequestBody Map<String,Object> params){
|
||||||
LambdaQueryWrapper<TaihuTalent> wrapper = new LambdaQueryWrapper<>();
|
MPJLambdaWrapper<TaihuTalent> wrapper = new MPJLambdaWrapper<>();
|
||||||
|
wrapper.leftJoin(MedicalRecordsLabel.class,MedicalRecordsLabel::getId,TaihuTalent::getDeptLabelId);
|
||||||
|
wrapper.selectAll(TaihuTalent.class);
|
||||||
|
wrapper.selectAs(MedicalRecordsLabel::getTitle,TaihuTalent::getDepartment);
|
||||||
wrapper.like(StringUtils.isNotEmpty(params.get("name").toString()),TaihuTalent::getName,params.get("name"));
|
wrapper.like(StringUtils.isNotEmpty(params.get("name").toString()),TaihuTalent::getName,params.get("name"));
|
||||||
if (params.containsKey("department")){
|
wrapper.eq(StringUtils.isNotEmpty(params.get("deptLabelId").toString()),TaihuTalent::getDeptLabelId,params.get("deptLabelId"));
|
||||||
wrapper.like(StringUtils.isNotEmpty(params.get("department").toString()),TaihuTalent::getDepartment,params.get("department"));
|
|
||||||
}
|
|
||||||
wrapper.like(StringUtils.isNotEmpty(params.get("region").toString()),TaihuTalent::getRegion,params.get("region"));
|
wrapper.like(StringUtils.isNotEmpty(params.get("region").toString()),TaihuTalent::getRegion,params.get("region"));
|
||||||
wrapper.orderByAsc(TaihuTalent::getCreateTime);
|
wrapper.orderByAsc(TaihuTalent::getCreateTime);
|
||||||
List<TaihuTalent> list = taihuTalentService.list(wrapper);
|
List<TaihuTalent> list = taihuTalentService.list(wrapper);
|
||||||
@@ -68,6 +68,7 @@ public class TaihuTalentController {
|
|||||||
@RequestMapping("/taihuTalentInfo")
|
@RequestMapping("/taihuTalentInfo")
|
||||||
public R taihuTalentInfo(@RequestBody Map<String,Object> params){
|
public R taihuTalentInfo(@RequestBody Map<String,Object> params){
|
||||||
TaihuTalent taihuTalent = taihuTalentService.getById(params.get("id").toString());
|
TaihuTalent taihuTalent = taihuTalentService.getById(params.get("id").toString());
|
||||||
|
taihuTalent.setDepartment(medicalRecordsLabelService.getById(taihuTalent.getDeptLabelId()).getTitle());
|
||||||
List<UserCertificateLabel> labels = userCertificateLabelService.list(new LambdaQueryWrapper<UserCertificateLabel>()
|
List<UserCertificateLabel> labels = userCertificateLabelService.list(new LambdaQueryWrapper<UserCertificateLabel>()
|
||||||
.eq(UserCertificateLabel::getPid,0));
|
.eq(UserCertificateLabel::getPid,0));
|
||||||
List<UserCertificateLabel> filterLabels = new ArrayList<>();
|
List<UserCertificateLabel> filterLabels = new ArrayList<>();
|
||||||
|
|||||||
Reference in New Issue
Block a user