Compare commits
3 Commits
dbe8e28237
...
7ccea276e8
| Author | SHA1 | Date | |
|---|---|---|---|
| 7ccea276e8 | |||
| 461b830d33 | |||
|
|
54728dec3e |
@ -337,6 +337,7 @@ public enum ResultCodeEnum {
|
|||||||
PARTICIPATION_FAILED(13010, "参与活动失败"),
|
PARTICIPATION_FAILED(13010, "参与活动失败"),
|
||||||
PARENT_NOT_FOUND(13011, "家长不存在"),
|
PARENT_NOT_FOUND(13011, "家长不存在"),
|
||||||
INVALID_ACTIVITY_STATUS(13012, "无效的活动状态"),
|
INVALID_ACTIVITY_STATUS(13012, "无效的活动状态"),
|
||||||
|
AGENT_NOT_FOUND(13013, "代理商不存在"),
|
||||||
PARENT_ALREADY_SIGN_UP(130121, "已经报名参加该活动"),
|
PARENT_ALREADY_SIGN_UP(130121, "已经报名参加该活动"),
|
||||||
UNAUTHORIZED_UPDATE_EMPLOYEE(13013, "无权限更新员工信息"),
|
UNAUTHORIZED_UPDATE_EMPLOYEE(13013, "无权限更新员工信息"),
|
||||||
DATA_REPEAT_ERROR(130014, "数据重复"),
|
DATA_REPEAT_ERROR(130014, "数据重复"),
|
||||||
|
|||||||
@ -3,8 +3,6 @@ package com.seer.teach.mp.admin.controller.req;
|
|||||||
import io.swagger.v3.oas.annotations.media.Schema;
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
||||||
import jakarta.validation.constraints.NotNull;
|
|
||||||
|
|
||||||
@Schema(name = "AgentEmployeeRelationReq", description = "代理商员工关联请求参数")
|
@Schema(name = "AgentEmployeeRelationReq", description = "代理商员工关联请求参数")
|
||||||
@Data
|
@Data
|
||||||
public class AgentEmployeeRelationReq {
|
public class AgentEmployeeRelationReq {
|
||||||
@ -12,11 +10,9 @@ public class AgentEmployeeRelationReq {
|
|||||||
@Schema(description = "关联ID")
|
@Schema(description = "关联ID")
|
||||||
private Integer id;
|
private Integer id;
|
||||||
|
|
||||||
@NotNull(message = "代理商ID不能为空")
|
|
||||||
@Schema(description = "代理商ID")
|
@Schema(description = "代理商ID")
|
||||||
private Integer agentId;
|
private Integer agentId;
|
||||||
|
|
||||||
@NotNull(message = "员工用户ID不能为空")
|
|
||||||
@Schema(description = "员工用户ID")
|
@Schema(description = "员工用户ID")
|
||||||
private Integer employeeUserId;
|
private Integer employeeUserId;
|
||||||
|
|
||||||
|
|||||||
@ -17,13 +17,11 @@ public class AgentEmployeeSaveReq {
|
|||||||
@NotNull(message = "员工名称不能为空")
|
@NotNull(message = "员工名称不能为空")
|
||||||
private String employeeName;
|
private String employeeName;
|
||||||
|
|
||||||
@Schema(description = "员工密码")
|
|
||||||
@NotNull(message = "员工密码不能为空")
|
|
||||||
private String password;
|
|
||||||
|
|
||||||
@Schema(description = "员工职位")
|
@Schema(description = "员工职位")
|
||||||
private String position;
|
private String position;
|
||||||
|
|
||||||
@Schema(description = "员工状态:0-禁用,1-启用")
|
@Schema(description = "员工状态:0-禁用,1-启用")
|
||||||
private Integer status = 1;
|
private Integer status = 1;
|
||||||
|
|
||||||
|
private String password;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -27,7 +27,7 @@ public interface IAdminAgentEmployeeRelationService {
|
|||||||
PageListBean<AgentEmployeeRelationResp> pageList(AgentEmployeeRelationQueryReq query);
|
PageListBean<AgentEmployeeRelationResp> pageList(AgentEmployeeRelationQueryReq query);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 创建或更新代理商员工关联(管理端)
|
* 更新代理商员工关联(管理端)
|
||||||
*
|
*
|
||||||
* @param request 关联请求对象
|
* @param request 关联请求对象
|
||||||
* @return 操作是否成功
|
* @return 操作是否成功
|
||||||
|
|||||||
@ -304,10 +304,8 @@ public class UserInfoServiceApiImpl implements UserInfoServiceApi {
|
|||||||
public Integer getUserIdByUserName(String userName) {
|
public Integer getUserIdByUserName(String userName) {
|
||||||
UserEntity userEntity = userService.getOne(new LambdaQueryWrapper<UserEntity>()
|
UserEntity userEntity = userService.getOne(new LambdaQueryWrapper<UserEntity>()
|
||||||
.eq(UserEntity::getUserName, userName));
|
.eq(UserEntity::getUserName, userName));
|
||||||
if (Objects.nonNull(userEntity)) {
|
AssertUtils.notNull(userEntity, ResultCodeEnum.USER_NOT_FOUND);
|
||||||
return userEntity.getId();
|
return userEntity.getId();
|
||||||
}
|
|
||||||
return null;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user