资源挂载加入资源id标志

This commit is contained in:
wangliwen 2022-05-17 17:39:56 +08:00
parent ae454b942a
commit b49f52b121
4 changed files with 56 additions and 39 deletions

View File

@ -94,6 +94,11 @@ public class ResourceMountController {
tResourceMountApplyDTO.setParameterContentMd5(SecureUtil.md5(JSONObject.toJSONString(index))); tResourceMountApplyDTO.setParameterContentMd5(SecureUtil.md5(JSONObject.toJSONString(index)));
tResourceMountApplyDTO.setResourceDTO(index); tResourceMountApplyDTO.setResourceDTO(index);
tResourceMountApplyDTO.setEnclosure(index.getEnclosure()); tResourceMountApplyDTO.setEnclosure(index.getEnclosure());
try {
tResourceMountApplyDTO.setResourceId(tResourceMountApplyDTO.getResourceDTO().getId());
} catch (Exception e) {
logger.error("", e);
}
ValidatorUtils.validateEntity(tResourceMountApplyDTO, AddGroup.class, DefaultGroup.class); ValidatorUtils.validateEntity(tResourceMountApplyDTO, AddGroup.class, DefaultGroup.class);
tResourceMountApplyService.save(tResourceMountApplyDTO); // 保存单条资源申请记录 tResourceMountApplyService.save(tResourceMountApplyDTO); // 保存单条资源申请记录

View File

@ -37,4 +37,7 @@ public class TResourceBatchMountApplyDTO extends AuditingBaseDTO implements Seri
@ApiModelProperty(value = "附件") @ApiModelProperty(value = "附件")
private String enclosure; private String enclosure;
@ApiModelProperty(value = "附件")
private List<Long> resourceIds;
} }

View File

@ -44,6 +44,9 @@ public class TResourceMountApplyDTO extends AuditingBaseDTO implements Serializa
@ApiModelProperty(value = "附件") @ApiModelProperty(value = "附件")
private String enclosure; private String enclosure;
@ApiModelProperty(value = "资源id")
private Long resourceId;
public ResourceDTO getResourceDTO() { public ResourceDTO getResourceDTO() {
if (this.parameterContent != null) { if (this.parameterContent != null) {
return JSON.parseObject(this.parameterContent, ResourceDTO.class); return JSON.parseObject(this.parameterContent, ResourceDTO.class);

View File

@ -14,47 +14,53 @@ import lombok.EqualsAndHashCode;
* @since 3.0 2022-04-24 * @since 3.0 2022-04-24
*/ */
@Data @Data
@EqualsAndHashCode(callSuper=false) @EqualsAndHashCode(callSuper = false)
@TableName("t_resource_mount_apply") @TableName("t_resource_mount_apply")
public class TResourceMountApplyEntity extends BaseEntity { public class TResourceMountApplyEntity extends BaseEntity {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
/** /**
* 上架申请人id * 上架申请人id
*/ */
private String userId; private String userId;
/** /**
* 上架申请人名字 * 上架申请人名字
*/ */
private String userName; private String userName;
/** /**
* 上架申请人电话 * 上架申请人电话
*/ */
private String phone; private String phone;
/** /**
* 上架申请人部门 * 上架申请人部门
*/ */
@TableField(fill = FieldFill.INSERT) @TableField(fill = FieldFill.INSERT)
private String deptId; private String deptId;
/** /**
* 流程实例ID * 流程实例ID
*/ */
private String instanceId; private String instanceId;
/** /**
* 删除标记0:正常使用1:已删除9:其他 * 删除标记0:正常使用1:已删除9:其他
*/ */
private String delFlag; private String delFlag;
/** /**
* 参数内容(挂载能力json参数) * 参数内容(挂载能力json参数)
*/ */
private String parameterContent; private String parameterContent;
/** /**
* 参数内容 md5 * 参数内容 md5
*/ */
private String parameterContentMd5; private String parameterContentMd5;
/** /**
* 附件 * 附件
*/ */
private String enclosure; private String enclosure;
/**
* 资源id
*/
private Long resourceId;
} }