记录资源下架发起人姓名
This commit is contained in:
parent
dd261257b8
commit
d0ae226585
|
@ -20,6 +20,9 @@ import io.renren.modules.resourceMountApply.dto.TResourceBatchMountApplyDTO;
|
||||||
import io.renren.modules.resourceMountApply.dto.TResourceMountApplyDTO;
|
import io.renren.modules.resourceMountApply.dto.TResourceMountApplyDTO;
|
||||||
import io.renren.modules.resourceMountApply.dto.TResourceUndercarriageApplyDTO;
|
import io.renren.modules.resourceMountApply.dto.TResourceUndercarriageApplyDTO;
|
||||||
import io.renren.modules.resourceMountApply.service.TResourceMountApplyService;
|
import io.renren.modules.resourceMountApply.service.TResourceMountApplyService;
|
||||||
|
import io.renren.modules.security.user.SecurityUser;
|
||||||
|
import io.renren.modules.sys.dto.SysUserDTO;
|
||||||
|
import io.renren.modules.sys.service.SysUserService;
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.codehaus.jackson.map.ObjectMapper;
|
import org.codehaus.jackson.map.ObjectMapper;
|
||||||
|
@ -51,6 +54,8 @@ public class ResourceMountController {
|
||||||
private TResourceMountApplyService tResourceMountApplyService;
|
private TResourceMountApplyService tResourceMountApplyService;
|
||||||
@Autowired
|
@Autowired
|
||||||
private ResourceService resourceService;
|
private ResourceService resourceService;
|
||||||
|
@Autowired
|
||||||
|
private SysUserService sysUserService;
|
||||||
|
|
||||||
private static String apply_key = "resourcemountapply"; // 资源上架
|
private static String apply_key = "resourcemountapply"; // 资源上架
|
||||||
|
|
||||||
|
@ -139,6 +144,11 @@ public class ResourceMountController {
|
||||||
resourceDTO.ifPresent(dto -> {
|
resourceDTO.ifPresent(dto -> {
|
||||||
dto.setUndercarriageReason(tResourceUndercarriageApplyDTO.getReason());
|
dto.setUndercarriageReason(tResourceUndercarriageApplyDTO.getReason());
|
||||||
dto.setDelFlag(ResourceEntityDelFlag.UNDERCARRIAGE_REVIEW.getFlag()); // 设置为下架审核中
|
dto.setDelFlag(ResourceEntityDelFlag.UNDERCARRIAGE_REVIEW.getFlag()); // 设置为下架审核中
|
||||||
|
String userId = SecurityUser.getUserId().toString();
|
||||||
|
Optional<SysUserDTO> userDTO = Optional.ofNullable(sysUserService.get(Long.valueOf(userId)));
|
||||||
|
userDTO.ifPresent(user -> {
|
||||||
|
dto.setUndercarriageUserName(user.getRealName());
|
||||||
|
});
|
||||||
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class);
|
||||||
resourceService.update(dto);
|
resourceService.update(dto);
|
||||||
});
|
});
|
||||||
|
|
|
@ -14,7 +14,6 @@ import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiImplicitParam;
|
import io.swagger.annotations.ApiImplicitParam;
|
||||||
import io.swagger.annotations.ApiImplicitParams;
|
import io.swagger.annotations.ApiImplicitParams;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.util.StringUtils;
|
import org.springframework.util.StringUtils;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
@ -24,6 +23,7 @@ import java.util.Map;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 任务管理
|
* 任务管理
|
||||||
|
*
|
||||||
* @author Jone
|
* @author Jone
|
||||||
*/
|
*/
|
||||||
@RestController
|
@RestController
|
||||||
|
@ -38,6 +38,7 @@ public class ActTaskController {
|
||||||
/**
|
/**
|
||||||
* 获取用户任务列表
|
* 获取用户任务列表
|
||||||
* 根据用户ID或角色组获取任务信息
|
* 根据用户ID或角色组获取任务信息
|
||||||
|
*
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@GetMapping("page")
|
@GetMapping("page")
|
||||||
|
@ -57,6 +58,7 @@ public class ActTaskController {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 我的待办列表
|
* 我的待办列表
|
||||||
|
*
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@GetMapping("myToDoTaskPage")
|
@GetMapping("myToDoTaskPage")
|
||||||
|
@ -138,6 +140,7 @@ public class ActTaskController {
|
||||||
actTaskService.completeTask(taskId, comment);
|
actTaskService.completeTask(taskId, comment);
|
||||||
return new Result();
|
return new Result();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 带参数的任务处理
|
* 带参数的任务处理
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -98,6 +98,8 @@ public class ResourceDTO implements Serializable {
|
||||||
private String enclosure;
|
private String enclosure;
|
||||||
@ApiModelProperty(value = "下架理由")
|
@ApiModelProperty(value = "下架理由")
|
||||||
private String undercarriageReason;
|
private String undercarriageReason;
|
||||||
|
@ApiModelProperty(value = "提起下架人员姓名")
|
||||||
|
private String undercarriageUserName;
|
||||||
|
|
||||||
public String getDelFlagTip() {
|
public String getDelFlagTip() {
|
||||||
if (this.delFlag != null) {
|
if (this.delFlag != null) {
|
||||||
|
|
|
@ -125,4 +125,10 @@ public class ResourceEntity extends BaseEntity {
|
||||||
* 下架理由
|
* 下架理由
|
||||||
*/
|
*/
|
||||||
private String undercarriageReason;
|
private String undercarriageReason;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 提起下架人员
|
||||||
|
*/
|
||||||
|
private String undercarriageUserName;
|
||||||
}
|
}
|
Loading…
Reference in New Issue