下架支持附件

This commit is contained in:
wangliwen 2022-07-21 09:40:55 +08:00
parent 7632d92ac2
commit 162b016d36
6 changed files with 17 additions and 2 deletions

View File

@ -190,6 +190,7 @@ public class ResourceMountController {
throw new RuntimeException("该资源已发起下架");
}
dto.setUndercarriageReason(tResourceUndercarriageApplyDTO.getReason());
dto.setUndercarriageEnclosure(tResourceUndercarriageApplyDTO.getEnclosure());
dto.setDelFlag(ResourceEntityDelFlag.NORMAL.getFlag()); // 设置为正常
String userId = SecurityUser.getUserId().toString();
Optional<SysUserDTO> userDTO = Optional.ofNullable(sysUserService.get(Long.valueOf(userId)));

View File

@ -103,6 +103,8 @@ public class ResourceDTO extends AuditingBaseDTO implements Serializable {
private String undercarriageReason;
@ApiModelProperty(value = "提起下架人员姓名")
private String undercarriageUserName;
@ApiModelProperty(value = "下架附件")
private String undercarriageEnclosure;
@ApiModelProperty(value = "总体评价")
private Integer total;

View File

@ -134,6 +134,12 @@ public class ResourceEntity extends BaseEntity {
*/
private String undercarriageUserName;
/**
* 下架附件
*/
private String undercarriageEnclosure;
@TableField(value = "info_list", typeHandler = FastjsonTypeHandler.class)
private List<AttrEntity> infoList;

View File

@ -24,4 +24,6 @@ public class TResourceUndercarriageApplyDTO extends AuditingBaseDTO implements S
private List<Map<String, String>> resource;
@ApiModelProperty(value = "下架原因")
private String reason;
@ApiModelProperty(value = "下架附件")
private String enclosure;
}

View File

@ -0,0 +1 @@
alter table `tb_data_resource` ADD COLUMN `undercarriage_enclosure` longtext NULL comment '下架附件';

View File

@ -33,6 +33,7 @@
<result property="enclosure" column="enclosure"/>
<result property="undercarriageReason" column="undercarriage_reason"/>
<result property="undercarriageUserName" column="undercarriage_user_name"/>
<result property="undercarriageEnclosure" column="undercarriage_enclosure"/>
<result property="infoList" column="info_list"
typeHandler="com.baomidou.mybatisplus.extension.handlers.FastjsonTypeHandler"/>
<result property="applyNumber" column="apply_number"/>
@ -68,6 +69,7 @@
<result property="enclosure" column="enclosure"/>
<result property="undercarriageReason" column="undercarriage_reason"/>
<result property="undercarriageUserName" column="undercarriage_user_name"/>
<result property="undercarriageEnclosure" column="undercarriage_enclosure"/>
<!-- 自定义字段 -->
<result property="deptName" column="deptName"/>
<result property="isCollect" column="isCollect"/>
@ -1436,7 +1438,8 @@
</select>
<select id="selectDevelopDocResource" resultType="java.util.Map">
SELECT tdr.id, tdr.name as title, tdr.type, tda.attr_value as doc FROM tb_data_resource tdr right join tb_data_attr tda on tdr.id=tda.data_resource_id
SELECT tdr.id, tdr.name as title, tdr.type, tda.attr_value as doc FROM tb_data_resource tdr right join
tb_data_attr tda on tdr.id=tda.data_resource_id
where tdr.del_flag != 1 and tda.attr_type='技术文档'
</select>