Merge remote-tracking branch 'origin/tsg' into tsg
commit
ae26aa6669
|
|
@ -71,7 +71,7 @@ public class PersonnelPlanLogController extends AbstractCommonFileController{
|
|||
throw new IllegalArgumentException("当前培训日期标题名称重复");
|
||||
}
|
||||
|
||||
if (planService.lambdaQuery().eq(PersonnelPlan::getId, dto.getPlanId()).count() == 0) {
|
||||
if (Objects.nonNull(dto.getPlanId()) && planService.lambdaQuery().eq(PersonnelPlan::getId, dto.getPlanId()).count() == 0) {
|
||||
throw new IllegalArgumentException("培训计划不存在");
|
||||
}
|
||||
dto.setId(IdWorker.getId());
|
||||
|
|
@ -100,7 +100,7 @@ public class PersonnelPlanLogController extends AbstractCommonFileController{
|
|||
if (query.count() > 0){
|
||||
throw new IllegalArgumentException("当前培训日期标题名称重复");
|
||||
}
|
||||
if (planService.lambdaQuery().eq(PersonnelPlan::getId, dto.getPlanId()).count() == 0) {
|
||||
if (Objects.nonNull(dto.getPlanId()) && planService.lambdaQuery().eq(PersonnelPlan::getId, dto.getPlanId()).count() == 0) {
|
||||
throw new IllegalArgumentException("培训计划不存在");
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -52,7 +52,7 @@ public class PersonnelPlanLog extends CommUpdate implements Serializable {
|
|||
@TableField(value="plan_id")
|
||||
@Schema(description="培训计划主键")
|
||||
@JsonSerialize(using = ToStringSerializer.class)
|
||||
@NotNull(message = "培训计划不能为空",groups = {Insert.class, Update.class})
|
||||
// @NotNull(message = "培训计划不能为空",groups = {Insert.class, Update.class})
|
||||
private Long planId;
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in New Issue