修复管理员禁用的 BUG

This commit is contained in:
YunaiV 2020-07-14 21:03:46 +08:00
parent f8cfb32b13
commit ac9d5f32f7
3 changed files with 4 additions and 2 deletions

View File

@ -56,7 +56,7 @@ public class AdminController {
@PostMapping("/update-status")
@ApiOperation(value = "更新管理员状态")
@RequiresPermissions("system:admin:update-status")
public CommonResult<Boolean> updateUserStatus(AdminUpdateStatusDTO updateStatusDTO) {
public CommonResult<Boolean> updateAdminStatus(AdminUpdateStatusDTO updateStatusDTO) {
adminManager.updateAdminStatus(updateStatusDTO);
return success(true);
}

View File

@ -16,7 +16,7 @@ public class AdminUpdateStatusDTO {
@ApiModelProperty(value = "管理员编号", required = true, example = "1")
@NotNull(message = "管理员编号不能为空")
private Integer id;
private Integer adminId;
@ApiModelProperty(value = "状态", required = true, example = "1", notes = "见 CommonStatusEnum 枚举")
@NotNull(message = "状态不能为空")

View File

@ -11,6 +11,7 @@ import cn.iocoder.mall.systemservice.rpc.admin.vo.AdminVO;
import cn.iocoder.mall.systemservice.rpc.admin.vo.DepartmentVO;
import cn.iocoder.mall.systemservice.rpc.permission.vo.RoleVO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;
import java.util.List;
@ -24,6 +25,7 @@ public interface AdminConvert {
AdminUpdateDTO convert(AdminUpdateInfoDTO bean);
@Mapping(source = "adminId", target = "id")
AdminUpdateDTO convert(AdminUpdateStatusDTO bean);
AdminPageDTO convert(cn.iocoder.mall.managementweb.controller.admin.dto.AdminPageDTO bean);