build: system project sdk domain

This commit is contained in:
CaptainB 2023-05-12 11:24:58 +08:00 committed by fit2-zhao
parent 5fc5d34e9a
commit 9bca908204
61 changed files with 3228 additions and 211 deletions

View File

@ -1,18 +0,0 @@
package io.metersphere.domain;
import lombok.Data;
import java.io.Serializable;
@Data
public class SystemParameter implements Serializable {
private String paramKey;
private String paramValue;
private String type;
private Integer sort;
private static final long serialVersionUID = 1L;
}

View File

@ -1,43 +0,0 @@
package io.metersphere.domain;
import com.baomidou.mybatisplus.annotation.TableName;
import jakarta.validation.constraints.Email;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@Data
@TableName(value = "user", autoResultMap = true)
public class User implements Serializable {
@NotBlank(message = "id不能为空")
private String id;
@NotBlank(message = "用户名不能为空")
@Size(min = 1, max = 50, message = "用户名长度必须在1-50之间")
private String name;
@Email
private String email;
private String password;
@NotBlank(message = "状态不能为空")
private String status;
private Long createTime;
private Long updateTime;
private String language;
private String lastWorkspaceId;
private String phone;
private String source;
private String lastProjectId;
private String createUser;
private static final long serialVersionUID = 1L;
}

View File

@ -1,26 +0,0 @@
package io.metersphere.domain;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import java.io.Serializable;
@Data
@AllArgsConstructor
@NoArgsConstructor
public class UserGroup implements Serializable {
private String id;
private String userId;
private String groupId;
private String sourceId;
private Long createTime;
private Long updateTime;
private static final long serialVersionUID = 1L;
}

View File

@ -1,18 +0,0 @@
package io.metersphere.domain;
import lombok.Data;
import java.io.Serializable;
@Data
public class UserGroupPermission implements Serializable {
private String id;
private String groupId;
private String permissionId;
private String moduleId;
private static final long serialVersionUID = 1L;
}

View File

@ -1,22 +0,0 @@
package io.metersphere.domain;
import lombok.Data;
import java.io.Serializable;
@Data
public class UserKey implements Serializable {
private String id;
private String userId;
private String accessKey;
private String secretKey;
private Long createTime;
private String status;
private static final long serialVersionUID = 1L;
}

View File

@ -0,0 +1,75 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "API模版表")
@TableName("api_template")
@Data
public class ApiTemplate implements Serializable {
private static final long serialVersionUID = 1L;
/** 模版ID */
@TableId
@NotBlank(message = "模版ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "模版ID")
private String id;
/** 模版名称 */
@Size(min = 1, max = 64, message = "模版名称长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "模版名称不能为空", groups = {Created.class})
@ApiModelProperty(name = "模版名称")
private String name;
/** 描述 */
@ApiModelProperty(name = "描述")
private String description;
/** 是否是系统模版 */
@Size(min = 1, max = 1, message = "是否是系统模版长度必须在1-1之间", groups = {Created.class, Updated.class})
@NotBlank(message = "是否是系统模版不能为空", groups = {Created.class})
@ApiModelProperty(name = "是否是系统模版")
private Boolean system;
/** 是否是全局模版 */
@Size(min = 1, max = 1, message = "是否是全局模版长度必须在1-1之间", groups = {Created.class, Updated.class})
@NotBlank(message = "是否是全局模版不能为空", groups = {Created.class})
@ApiModelProperty(name = "是否是全局模版")
private Boolean global;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 创建人 */
@ApiModelProperty(name = "创建人")
private String createUser;
/** 项目ID */
@ApiModelProperty(name = "项目ID")
private String projectId;
}

View File

@ -0,0 +1,99 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "自定义字段")
@TableName("custom_field")
@Data
public class CustomField implements Serializable {
private static final long serialVersionUID = 1L;
/** 自定义字段ID */
@TableId
@NotBlank(message = "自定义字段ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "自定义字段ID")
private String id;
/** 自定义字段名称 */
@Size(min = 1, max = 64, message = "自定义字段名称长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "自定义字段名称不能为空", groups = {Created.class})
@ApiModelProperty(name = "自定义字段名称")
private String name;
/** 使用场景 */
@Size(min = 1, max = 30, message = "使用场景长度必须在1-30之间", groups = {Created.class, Updated.class})
@NotBlank(message = "使用场景不能为空", groups = {Created.class})
@ApiModelProperty(name = "使用场景")
private String scene;
/** 自定义字段类型 */
@Size(min = 1, max = 30, message = "自定义字段类型长度必须在1-30之间", groups = {Created.class, Updated.class})
@NotBlank(message = "自定义字段类型不能为空", groups = {Created.class})
@ApiModelProperty(name = "自定义字段类型")
private String type;
/** 自定义字段备注 */
@ApiModelProperty(name = "自定义字段备注")
private String remark;
/** 自定义字段选项 */
@ApiModelProperty(name = "自定义字段选项")
private String options;
/** 是否是系统字段 */
@ApiModelProperty(name = "是否是系统字段")
private Boolean system;
/** 是否是全局字段 */
@ApiModelProperty(name = "是否是全局字段")
private Boolean global;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 创建人 */
@ApiModelProperty(name = "创建人")
private String createUser;
/** 项目ID */
@ApiModelProperty(name = "项目ID")
private String projectId;
/** 是否关联第三方 */
@Size(min = 1, max = 1, message = "是否关联第三方长度必须在1-1之间", groups = {Created.class, Updated.class})
@NotBlank(message = "是否关联第三方不能为空", groups = {Created.class})
@ApiModelProperty(name = "是否关联第三方")
private Boolean thirdPart;
}

View File

@ -0,0 +1,45 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "自定义字段关系")
@TableName("custom_field_api")
@Data
public class CustomFieldApi implements Serializable {
private static final long serialVersionUID = 1L;
/** 资源ID */
@TableId
@NotBlank(message = "资源ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "资源ID")
private String resourceId;
/** 字段ID */
@TableId
@NotBlank(message = "字段ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "字段ID")
private String fieldId;
/** 字段值 */
@ApiModelProperty(name = "字段值")
private String value;
/** */
@ApiModelProperty(name = "")
private byte[] textValue;
}

View File

@ -0,0 +1,45 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "自定义字段缺陷关系")
@TableName("custom_field_issue")
@Data
public class CustomFieldIssue implements Serializable {
private static final long serialVersionUID = 1L;
/** 资源ID */
@TableId
@NotBlank(message = "资源ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "资源ID")
private String resourceId;
/** 字段ID */
@TableId
@NotBlank(message = "字段ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "字段ID")
private String fieldId;
/** 字段值 */
@ApiModelProperty(name = "字段值")
private String value;
/** */
@ApiModelProperty(name = "")
private byte[] textValue;
}

View File

@ -0,0 +1,75 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "自定义模版")
@TableName("custom_field_template")
@Data
public class CustomFieldTemplate implements Serializable {
private static final long serialVersionUID = 1L;
/** 自定义模版ID */
@TableId
@NotBlank(message = "自定义模版ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "自定义模版ID")
private String id;
/** 自定义字段ID */
@Size(min = 1, max = 50, message = "自定义字段ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "自定义字段ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "自定义字段ID")
private String fieldId;
/** 模版ID */
@Size(min = 1, max = 50, message = "模版ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "模版ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "模版ID")
private String templateId;
/** 使用场景 */
@Size(min = 1, max = 30, message = "使用场景长度必须在1-30之间", groups = {Created.class, Updated.class})
@NotBlank(message = "使用场景不能为空", groups = {Created.class})
@ApiModelProperty(name = "使用场景")
private String scene;
/** 是否必填 */
@ApiModelProperty(name = "是否必填")
private Boolean required;
/** 排序字段 */
@ApiModelProperty(name = "排序字段")
private Integer pos;
/** 默认值 */
@ApiModelProperty(name = "默认值")
private byte[] defaultValue;
/** 自定义数据 */
@ApiModelProperty(name = "自定义数据")
private String customData;
/** 自定义表头 */
@ApiModelProperty(name = "自定义表头")
private String key;
}

View File

@ -0,0 +1,45 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "自定义字段功能用例关系")
@TableName("custom_field_test_case")
@Data
public class CustomFieldTestCase implements Serializable {
private static final long serialVersionUID = 1L;
/** 资源ID */
@TableId
@NotBlank(message = "资源ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "资源ID")
private String resourceId;
/** 字段ID */
@TableId
@NotBlank(message = "字段ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "字段ID")
private String fieldId;
/** 字段值 */
@ApiModelProperty(name = "字段值")
private String value;
/** */
@ApiModelProperty(name = "")
private String textValue;
}

View File

@ -0,0 +1,75 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "自定义函数-代码片段")
@TableName("custom_function")
@Data
public class CustomFunction implements Serializable {
private static final long serialVersionUID = 1L;
/** */
@TableId
@NotBlank(message = "不能为空", groups = {Updated.class})
@ApiModelProperty(name = "")
private String id;
/** 函数名 */
@Size(min = 1, max = 255, message = "函数名长度必须在1-255之间", groups = {Created.class, Updated.class})
@NotBlank(message = "函数名不能为空", groups = {Created.class})
@ApiModelProperty(name = "函数名")
private String name;
/** 标签 */
@ApiModelProperty(name = "标签")
private String tags;
/** 函数描述 */
@ApiModelProperty(name = "函数描述")
private String description;
/** 脚本语言类型 */
@Size(min = 1, max = 255, message = "脚本语言类型长度必须在1-255之间", groups = {Created.class, Updated.class})
@NotBlank(message = "脚本语言类型不能为空", groups = {Created.class})
@ApiModelProperty(name = "脚本语言类型")
private String type;
/** 创建人 */
@Size(min = 1, max = 100, message = "创建人长度必须在1-100之间", groups = {Created.class, Updated.class})
@NotBlank(message = "创建人不能为空", groups = {Created.class})
@ApiModelProperty(name = "创建人")
private String createUser;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 所属项目ID */
@Size(min = 1, max = 50, message = "所属项目ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "所属项目ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "所属项目ID")
private String projectId;
}

View File

@ -0,0 +1,45 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "自定义函数-代码片段大字段")
@TableName("custom_function_blob")
@Data
public class CustomFunctionBlob implements Serializable {
private static final long serialVersionUID = 1L;
/** */
@TableId
@NotBlank(message = "不能为空", groups = {Updated.class})
@ApiModelProperty(name = "")
private String functionId;
/** 参数列表 */
@ApiModelProperty(name = "参数列表")
private byte[] params;
/** 函数体 */
@ApiModelProperty(name = "函数体")
private byte[] script;
/** 执行结果 */
@ApiModelProperty(name = "执行结果")
private byte[] result;
}

View File

@ -0,0 +1,75 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "误报库")
@TableName("fake_error")
@Data
public class FakeError implements Serializable {
private static final long serialVersionUID = 1L;
/** 误报ID */
@TableId
@NotBlank(message = "误报ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "误报ID")
private String id;
/** 项目ID */
@Size(min = 1, max = 50, message = "项目ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "项目ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "项目ID")
private String projectId;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 创建人 */
@Size(min = 1, max = 64, message = "创建人长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "创建人不能为空", groups = {Created.class})
@ApiModelProperty(name = "创建人")
private String createUser;
/** 更新人 */
@Size(min = 1, max = 64, message = "更新人长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "更新人不能为空", groups = {Created.class})
@ApiModelProperty(name = "更新人")
private String updateUser;
/** 错误码 */
@Size(min = 1, max = 255, message = "错误码长度必须在1-255之间", groups = {Created.class, Updated.class})
@NotBlank(message = "错误码不能为空", groups = {Created.class})
@ApiModelProperty(name = "错误码")
private String errorCode;
/** 匹配类型 */
@Size(min = 1, max = 255, message = "匹配类型长度必须在1-255之间", groups = {Created.class, Updated.class})
@NotBlank(message = "匹配类型不能为空", groups = {Created.class})
@ApiModelProperty(name = "匹配类型")
private String matchType;
/** 状态 */
@ApiModelProperty(name = "状态")
private Boolean status;
}

View File

@ -0,0 +1,39 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "误报库大字段")
@TableName("fake_error_blob")
@Data
public class FakeErrorBlob implements Serializable {
private static final long serialVersionUID = 1L;
/** Test ID */
@TableId
@NotBlank(message = "Test ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "Test ID")
private String fakeErrorId;
/** 内容 */
@ApiModelProperty(name = "内容")
private byte[] content;
/** 报告内容 */
@ApiModelProperty(name = "报告内容")
private byte[] description;
}

View File

@ -0,0 +1,129 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "文件基础信息")
@TableName("file_metadata")
@Data
public class FileMetadata implements Serializable {
private static final long serialVersionUID = 1L;
/** 文件ID */
@TableId
@NotBlank(message = "文件ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "文件ID")
private String id;
/** 文件名 */
@Size(min = 1, max = 250, message = "文件名长度必须在1-250之间", groups = {Created.class, Updated.class})
@NotBlank(message = "文件名不能为空", groups = {Created.class})
@ApiModelProperty(name = "文件名")
private String name;
/** 文件类型 */
@ApiModelProperty(name = "文件类型")
private String type;
/** 文件大小 */
@ApiModelProperty(name = "文件大小")
private Long size;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 项目ID */
@ApiModelProperty(name = "项目ID")
private String projectId;
/** 文件存储方式 */
@Size(min = 1, max = 50, message = "文件存储方式长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "文件存储方式不能为空", groups = {Created.class})
@ApiModelProperty(name = "文件存储方式")
private String storage;
/** 创建人 */
@ApiModelProperty(name = "创建人")
private String createUser;
/** 修改人 */
@ApiModelProperty(name = "修改人")
private String updateUser;
/** 标签 */
@ApiModelProperty(name = "标签")
private String tags;
/** 描述 */
@ApiModelProperty(name = "描述")
private String description;
/** 文件所属模块 */
@ApiModelProperty(name = "文件所属模块")
private String moduleId;
/** 是否加载jar开启后用于接口测试执行时使用 */
@ApiModelProperty(name = "是否加载jar开启后用于接口测试执行时使用")
private Boolean loadJar;
/** 文件存储路径 */
@ApiModelProperty(name = "文件存储路径")
private String path;
/** 资源作用范围主要兼容2.1版本前的历史数据,后续版本不再产生数据 */
@ApiModelProperty(name = "资源作用范围主要兼容2.1版本前的历史数据,后续版本不再产生数据")
private String resourceType;
/** 是否是最新版 */
@ApiModelProperty(name = "是否是最新版")
private Boolean latest;
/** 同版本数据关联的ID */
@ApiModelProperty(name = "同版本数据关联的ID")
private String refId;
}

View File

@ -0,0 +1,33 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "文件基础信息大字段")
@TableName("file_metadata_blob")
@Data
public class FileMetadataBlob implements Serializable {
private static final long serialVersionUID = 1L;
/** 文件ID */
@TableId
@NotBlank(message = "文件ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "文件ID")
private String fileId;
/** 储存库 */
@ApiModelProperty(name = "储存库")
private byte[] gitInfo;
}

View File

@ -0,0 +1,81 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "文件管理模块")
@TableName("file_module")
@Data
public class FileModule implements Serializable {
private static final long serialVersionUID = 1L;
/** ID */
@TableId
@NotBlank(message = "ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "ID")
private String id;
/** 项目ID */
@Size(min = 1, max = 50, message = "项目ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "项目ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "项目ID")
private String projectId;
/** 模块名称 */
@Size(min = 1, max = 64, message = "模块名称长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "模块名称不能为空", groups = {Created.class})
@ApiModelProperty(name = "模块名称")
private String name;
/** 父级ID */
@ApiModelProperty(name = "父级ID")
private String parentId;
/** 层数 */
@ApiModelProperty(name = "层数")
private Integer level;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 排序用的标识 */
@ApiModelProperty(name = "排序用的标识")
private Double pos;
/** 创建人 */
@ApiModelProperty(name = "创建人")
private String createUser;
/** 模块类型: module/repository */
@ApiModelProperty(name = "模块类型: module/repository")
private String moduleType;
}

View File

@ -0,0 +1,51 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "文件管理模块大字段")
@TableName("file_module_blob")
@Data
public class FileModuleBlob implements Serializable {
private static final long serialVersionUID = 1L;
/** ID */
@TableId
@NotBlank(message = "ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "ID")
private String fileModuleId;
/** 存储库描述 */
@ApiModelProperty(name = "存储库描述")
private byte[] repositoryDesc;
/** 存储库路径 */
@ApiModelProperty(name = "存储库路径")
private String repositoryPath;
/** 存储库Token */
@ApiModelProperty(name = "存储库Token")
private String repositoryUserName;
/** 存储库Token */
@ApiModelProperty(name = "存储库Token")
private String repositoryToken;
}

View File

@ -0,0 +1,69 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "项目")
@TableName("project")
@Data
public class Project implements Serializable {
private static final long serialVersionUID = 1L;
/** 项目ID */
@TableId
@NotBlank(message = "项目ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "项目ID")
private String id;
/** 工作空间ID */
@Size(min = 1, max = 50, message = "工作空间ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "工作空间ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "工作空间ID")
private String workspaceId;
/** 项目名称 */
@Size(min = 1, max = 64, message = "项目名称长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "项目名称不能为空", groups = {Created.class})
@ApiModelProperty(name = "项目名称")
private String name;
/** 项目描述 */
@ApiModelProperty(name = "项目描述")
private String description;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 创建人 */
@ApiModelProperty(name = "创建人")
private String createUser;
/** */
@ApiModelProperty(name = "")
private String systemId;
}

View File

@ -0,0 +1,39 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "项目应用")
@TableName("project_application")
@Data
public class ProjectApplication implements Serializable {
private static final long serialVersionUID = 1L;
/** 项目ID */
@TableId
@NotBlank(message = "项目ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "项目ID")
private String projectId;
/** 配置项 */
@TableId
@NotBlank(message = "配置项不能为空", groups = {Updated.class})
@ApiModelProperty(name = "配置项")
private String type;
/** 配置值 */
@ApiModelProperty(name = "配置值")
private String typeValue;
}

View File

@ -0,0 +1,93 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "项目扩展")
@TableName("project_extend")
@Data
public class ProjectExtend implements Serializable {
private static final long serialVersionUID = 1L;
/** 项目ID */
@TableId
@NotBlank(message = "项目ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "项目ID")
private String projectId;
/** */
@ApiModelProperty(name = "")
private String tapdId;
/** */
@ApiModelProperty(name = "")
private String jiraKey;
/** */
@ApiModelProperty(name = "")
private String zentaoId;
/** */
@ApiModelProperty(name = "")
private String azureDevopsId;
/** 用例模版ID */
@ApiModelProperty(name = "用例模版ID")
private String caseTemplateId;
/** azure 过滤需求的 parent workItem ID */
@ApiModelProperty(name = "azure 过滤需求的 parent workItem ID")
private String azureFilterId;
/** 项目使用哪个平台的模板 */
@Size(min = 1, max = 20, message = "项目使用哪个平台的模板长度必须在1-20之间", groups = {Created.class, Updated.class})
@NotBlank(message = "项目使用哪个平台的模板不能为空", groups = {Created.class})
@ApiModelProperty(name = "项目使用哪个平台的模板")
private String platform;
/** 是否使用第三方平台缺陷模板 */
@ApiModelProperty(name = "是否使用第三方平台缺陷模板")
private Boolean thirdPartTemplate;
/** 是否开启版本管理 */
@ApiModelProperty(name = "是否开启版本管理")
private Boolean versionEnable;
/** */
@ApiModelProperty(name = "")
private byte[] issueConfig;
/** */
@ApiModelProperty(name = "")
private String apiTemplateId;
}

View File

@ -0,0 +1,87 @@
package io.metersphere.project.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "版本管理")
@TableName("project_version")
@Data
public class ProjectVersion implements Serializable {
private static final long serialVersionUID = 1L;
/** 版本ID */
@TableId
@NotBlank(message = "版本ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "版本ID")
private String id;
/** 项目ID */
@Size(min = 1, max = 50, message = "项目ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "项目ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "项目ID")
private String projectId;
/** 版本名称 */
@Size(min = 1, max = 100, message = "版本名称长度必须在1-100之间", groups = {Created.class, Updated.class})
@NotBlank(message = "版本名称不能为空", groups = {Created.class})
@ApiModelProperty(name = "版本名称")
private String name;
/** 描述 */
@ApiModelProperty(name = "描述")
private String description;
/** 状态 */
@ApiModelProperty(name = "状态")
private String status;
/** 是否是最新版 */
@Size(min = 1, max = 1, message = "是否是最新版长度必须在1-1之间", groups = {Created.class, Updated.class})
@NotBlank(message = "是否是最新版不能为空", groups = {Created.class})
@ApiModelProperty(name = "是否是最新版")
private Boolean latest;
/** 发布时间 */
@ApiModelProperty(name = "发布时间")
private Long publishTime;
/** 开始时间 */
@ApiModelProperty(name = "开始时间")
private Long startTime;
/** 结束时间 */
@ApiModelProperty(name = "结束时间")
private Long endTime;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 创建人 */
@Size(min = 1, max = 100, message = "创建人长度必须在1-100之间", groups = {Created.class, Updated.class})
@NotBlank(message = "创建人不能为空", groups = {Created.class})
@ApiModelProperty(name = "创建人")
private String createUser;
}

View File

@ -0,0 +1,105 @@
package io.metersphere.sdk.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "环境")
@TableName("environment")
@Data
public class Environment implements Serializable {
private static final long serialVersionUID = 1L;
/** Api Test Environment ID */
@TableId
@NotBlank(message = "Api Test Environment ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "Api Test Environment ID")
private String id;
/** Api Test Environment Name */
@Size(min = 1, max = 64, message = "Api Test Environment Name长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Api Test Environment Name不能为空", groups = {Created.class})
@ApiModelProperty(name = "Api Test Environment Name")
private String name;
/** Project ID */
@Size(min = 1, max = 50, message = "Project ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Project ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "Project ID")
private String projectId;
/** Api Test Protocol */
@ApiModelProperty(name = "Api Test Protocol")
private String protocol;
/** Api Test Socket */
@ApiModelProperty(name = "Api Test Socket")
private String socket;
/** Api Test Domain */
@ApiModelProperty(name = "Api Test Domain")
private String domain;
/** Api Test Port */
@ApiModelProperty(name = "Api Test Port")
private Integer port;
/** Global ariables */
@ApiModelProperty(name = "Global ariables")
private String variables;
/** Global Heards */
@ApiModelProperty(name = "Global Heards")
private String headers;
/** Config Data (JSON format) */
@ApiModelProperty(name = "Config Data (JSON format)")
private String config;
/** hosts */
@ApiModelProperty(name = "hosts")
private String hosts;
/** */
@ApiModelProperty(name = "")
private String createUser;
/** */
@ApiModelProperty(name = "")
private Long createTime;
/** */
@ApiModelProperty(name = "")
private Long updateTime;
}

View File

@ -0,0 +1,63 @@
package io.metersphere.sdk.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "环境组")
@TableName("environment_group")
@Data
public class EnvironmentGroup implements Serializable {
private static final long serialVersionUID = 1L;
/** 环境组id */
@TableId
@NotBlank(message = "环境组id不能为空", groups = {Updated.class})
@ApiModelProperty(name = "环境组id")
private String id;
/** 环境组名 */
@Size(min = 1, max = 50, message = "环境组名长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "环境组名不能为空", groups = {Created.class})
@ApiModelProperty(name = "环境组名")
private String name;
/** 所属工作空间 */
@Size(min = 1, max = 64, message = "所属工作空间长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "所属工作空间不能为空", groups = {Created.class})
@ApiModelProperty(name = "所属工作空间")
private String workspaceId;
/** 环境组描述 */
@ApiModelProperty(name = "环境组描述")
private String description;
/** 创建人 */
@ApiModelProperty(name = "创建人")
private String createUser;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
}

View File

@ -0,0 +1,45 @@
package io.metersphere.sdk.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "环境组配置")
@TableName("environment_group_project")
@Data
public class EnvironmentGroupProject implements Serializable {
private static final long serialVersionUID = 1L;
/** */
@TableId
@NotBlank(message = "不能为空", groups = {Updated.class})
@ApiModelProperty(name = "")
private String id;
/** 环境组id */
@ApiModelProperty(name = "环境组id")
private String environmentGroupId;
/** api test environment 环境ID */
@ApiModelProperty(name = "api test environment 环境ID")
private String environmentId;
/** 项目id */
@ApiModelProperty(name = "项目id")
private String projectId;
}

View File

@ -0,0 +1,63 @@
package io.metersphere.sdk.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "执行链(接口/场景/UI/性能用例)")
@TableName("execution_queue")
@Data
public class ExecutionQueue implements Serializable {
private static final long serialVersionUID = 1L;
/** ID */
@TableId
@NotBlank(message = "ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "ID")
private String id;
/** 集合报告/测试计划报告 */
@ApiModelProperty(name = "集合报告/测试计划报告")
private String reportId;
/** 报告类型/计划报告/单独报告 */
@ApiModelProperty(name = "报告类型/计划报告/单独报告")
private String reportType;
/** 执行模式/scenario/api/test_paln_api/test_pan_scenario */
@ApiModelProperty(name = "执行模式/scenario/api/test_paln_api/test_pan_scenario")
private String runMode;
/** 执行资源池 */
@ApiModelProperty(name = "执行资源池")
private String poolId;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** */
@ApiModelProperty(name = "")
private Boolean failure;
}

View File

@ -0,0 +1,87 @@
package io.metersphere.sdk.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "执行链条目")
@TableName("execution_queue_detail")
@Data
public class ExecutionQueueDetail implements Serializable {
private static final long serialVersionUID = 1L;
/** ID */
@TableId
@NotBlank(message = "ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "ID")
private String id;
/** 队列id */
@ApiModelProperty(name = "队列id")
private String queueId;
/** 排序 */
@ApiModelProperty(name = "排序")
private Integer sort;
/** 报告id */
@ApiModelProperty(name = "报告id")
private String reportId;
/** 资源id */
@ApiModelProperty(name = "资源id")
private String testId;
/** 环境 */
@ApiModelProperty(name = "环境")
private String evnMap;
/** 资源类型 */
@ApiModelProperty(name = "资源类型")
private String type;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 是否开启失败重试 */
@ApiModelProperty(name = "是否开启失败重试")
private Boolean retryEnable;
/** 失败重试次数 */
@ApiModelProperty(name = "失败重试次数")
private Long retryNumber;
/** 项目ID集合 */
@ApiModelProperty(name = "项目ID集合")
private String projectIds;
}

View File

@ -0,0 +1,57 @@
package io.metersphere.sdk.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "关系图")
@TableName("relationship_edge")
@Data
public class RelationshipEdge implements Serializable {
private static final long serialVersionUID = 1L;
/** 源节点的ID */
@TableId
@NotBlank(message = "源节点的ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "源节点的ID")
private String sourceId;
/** 目标节点的ID */
@TableId
@NotBlank(message = "目标节点的ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "目标节点的ID")
private String targetId;
/** 边的分类 */
@Size(min = 1, max = 20, message = "边的分类长度必须在1-20之间", groups = {Created.class, Updated.class})
@NotBlank(message = "边的分类不能为空", groups = {Created.class})
@ApiModelProperty(name = "边的分类")
private String type;
/** 所属关系图的ID */
@Size(min = 1, max = 50, message = "所属关系图的ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "所属关系图的ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "所属关系图的ID")
private String graphId;
/** 创建人 */
@Size(min = 1, max = 50, message = "创建人长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "创建人不能为空", groups = {Created.class})
@ApiModelProperty(name = "创建人")
private String createUser;
/** */
@ApiModelProperty(name = "")
private Long createTime;
}

View File

@ -0,0 +1,63 @@
package io.metersphere.sdk.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "分享")
@TableName("share_info")
@Data
public class ShareInfo implements Serializable {
private static final long serialVersionUID = 1L;
/** 分享ID */
@TableId
@NotBlank(message = "分享ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "分享ID")
private String id;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 创建人 */
@ApiModelProperty(name = "创建人")
private String createUser;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 分享类型single batch */
@ApiModelProperty(name = "分享类型single batch")
private String shareType;
/** 分享扩展数据 */
@ApiModelProperty(name = "分享扩展数据")
private byte[] customData;
/** 语言 */
@ApiModelProperty(name = "语言")
private String lang;
}

View File

@ -0,0 +1,69 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "三方认证源")
@TableName("auth_source")
@Data
public class AuthSource implements Serializable {
private static final long serialVersionUID = 1L;
/** 认证源ID */
@TableId
@NotBlank(message = "认证源ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "认证源ID")
private String id;
/** 认证源配置 */
@ApiModelProperty(name = "认证源配置")
private byte[] configuration;
/** 状态 启用 禁用 */
@Size(min = 1, max = 64, message = "状态 启用 禁用长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "状态 启用 禁用不能为空", groups = {Created.class})
@ApiModelProperty(name = "状态 启用 禁用")
private String status;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 描述 */
@ApiModelProperty(name = "描述")
private String description;
/** 名称 */
@ApiModelProperty(name = "名称")
private String name;
/** 类型 */
@ApiModelProperty(name = "类型")
private String type;
}

View File

@ -0,0 +1,45 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "")
@TableName("license")
@Data
public class License implements Serializable {
private static final long serialVersionUID = 1L;
/** ID */
@TableId
@NotBlank(message = "ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "ID")
private String id;
/** Create timestamp */
@ApiModelProperty(name = "Create timestamp")
private Long createTime;
/** Update timestamp */
@ApiModelProperty(name = "Update timestamp")
private Long updateTime;
/** license_code */
@ApiModelProperty(name = "license_code")
private String licenseCode;
}

View File

@ -0,0 +1,75 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "消息通知任务")
@TableName("message_task")
@Data
public class MessageTask implements Serializable {
private static final long serialVersionUID = 1L;
/** */
@TableId
@NotBlank(message = "不能为空", groups = {Updated.class})
@ApiModelProperty(name = "")
private String id;
/** 消息类型 */
@Size(min = 1, max = 50, message = "消息类型长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "消息类型不能为空", groups = {Created.class})
@ApiModelProperty(name = "消息类型")
private String type;
/** 通知事件类型 */
@Size(min = 1, max = 255, message = "通知事件类型长度必须在1-255之间", groups = {Created.class, Updated.class})
@NotBlank(message = "通知事件类型不能为空", groups = {Created.class})
@ApiModelProperty(name = "通知事件类型")
private String event;
/** 接收人id */
@Size(min = 1, max = 50, message = "接收人id长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "接收人id不能为空", groups = {Created.class})
@ApiModelProperty(name = "接收人id")
private String receiver;
/** 任务类型 */
@Size(min = 1, max = 64, message = "任务类型长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "任务类型不能为空", groups = {Created.class})
@ApiModelProperty(name = "任务类型")
private String taskType;
/** webhook地址 */
@ApiModelProperty(name = "webhook地址")
private String webhook;
/** 具体测试的ID */
@Size(min = 1, max = 255, message = "具体测试的ID长度必须在1-255之间", groups = {Created.class, Updated.class})
@NotBlank(message = "具体测试的ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "具体测试的ID")
private String testId;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 项目ID */
@Size(min = 1, max = 64, message = "项目ID长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "项目ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "项目ID")
private String projectId;
}

View File

@ -0,0 +1,33 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "消息通知任务大字段")
@TableName("message_task_blob")
@Data
public class MessageTaskBlob implements Serializable {
private static final long serialVersionUID = 1L;
/** */
@TableId
@NotBlank(message = "不能为空", groups = {Updated.class})
@ApiModelProperty(name = "")
private String messageTaskId;
/** 消息模版 */
@ApiModelProperty(name = "消息模版")
private String template;
}

View File

@ -0,0 +1,87 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "消息通知")
@TableName("notification")
@Data
public class Notification implements Serializable {
private static final long serialVersionUID = 1L;
/** ID */
@TableId
@NotBlank(message = "ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "ID")
private Long id;
/** 通知类型 */
@Size(min = 1, max = 30, message = "通知类型长度必须在1-30之间", groups = {Created.class, Updated.class})
@NotBlank(message = "通知类型不能为空", groups = {Created.class})
@ApiModelProperty(name = "通知类型")
private String type;
/** 接收人 */
@Size(min = 1, max = 50, message = "接收人长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "接收人不能为空", groups = {Created.class})
@ApiModelProperty(name = "接收人")
private String receiver;
/** 标题 */
@Size(min = 1, max = 100, message = "标题长度必须在1-100之间", groups = {Created.class, Updated.class})
@NotBlank(message = "标题不能为空", groups = {Created.class})
@ApiModelProperty(name = "标题")
private String title;
/** 状态 */
@Size(min = 1, max = 30, message = "状态长度必须在1-30之间", groups = {Created.class, Updated.class})
@NotBlank(message = "状态不能为空", groups = {Created.class})
@ApiModelProperty(name = "状态")
private String status;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 操作人 */
@Size(min = 1, max = 50, message = "操作人长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "操作人不能为空", groups = {Created.class})
@ApiModelProperty(name = "操作人")
private String operator;
/** 操作 */
@Size(min = 1, max = 50, message = "操作长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "操作不能为空", groups = {Created.class})
@ApiModelProperty(name = "操作")
private String operation;
/** 资源ID */
@Size(min = 1, max = 50, message = "资源ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "资源ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "资源ID")
private String resourceId;
/** 资源类型 */
@Size(min = 1, max = 50, message = "资源类型长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "资源类型不能为空", groups = {Created.class})
@ApiModelProperty(name = "资源类型")
private String resourceType;
/** 资源名称 */
@Size(min = 1, max = 100, message = "资源名称长度必须在1-100之间", groups = {Created.class, Updated.class})
@NotBlank(message = "资源名称不能为空", groups = {Created.class})
@ApiModelProperty(name = "资源名称")
private String resourceName;
}

View File

@ -0,0 +1,63 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "新手村")
@TableName("novice_statistics")
@Data
public class NoviceStatistics implements Serializable {
private static final long serialVersionUID = 1L;
/** */
@TableId
@NotBlank(message = "不能为空", groups = {Updated.class})
@ApiModelProperty(name = "")
private String id;
/** 用户id */
@ApiModelProperty(name = "用户id")
private String userId;
/** 新手引导完成的步骤 */
@Size(min = 1, max = 1, message = "新手引导完成的步骤长度必须在1-1之间", groups = {Created.class, Updated.class})
@NotBlank(message = "新手引导完成的步骤不能为空", groups = {Created.class})
@ApiModelProperty(name = "新手引导完成的步骤")
private Boolean guideStep;
/** 新手引导的次数 */
@ApiModelProperty(name = "新手引导的次数")
private Integer guideNum;
/** data option (JSON format) */
@ApiModelProperty(name = "data option (JSON format)")
private byte[] dataOption;
/** */
@ApiModelProperty(name = "")
private Long createTime;
/** */
@ApiModelProperty(name = "")
private Long updateTime;
}

View File

@ -0,0 +1,99 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "操作日志")
@TableName("operating_log")
@Data
public class OperatingLog implements Serializable {
private static final long serialVersionUID = 1L;
/** ID */
@TableId
@NotBlank(message = "ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "ID")
private String id;
/** 项目ID */
@Size(min = 1, max = 50, message = "项目ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "项目ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "项目ID")
private String projectId;
/** operating method */
@ApiModelProperty(name = "operating method")
private String operMethod;
/** 创建人 */
@ApiModelProperty(name = "创建人")
private String createUser;
/** 操作人 */
@ApiModelProperty(name = "操作人")
private String operUser;
/** 资源ID */
@ApiModelProperty(name = "资源ID")
private String sourceId;
/** 操作类型 */
@ApiModelProperty(name = "操作类型")
private String operType;
/** 操作模块 */
@ApiModelProperty(name = "操作模块")
private String operModule;
/** 操作标题 */
@ApiModelProperty(name = "操作标题")
private String operTitle;
/** 操作路径 */
@ApiModelProperty(name = "操作路径")
private String operPath;
/** 操作内容 */
@ApiModelProperty(name = "操作内容")
private byte[] operContent;
/** 操作参数 */
@ApiModelProperty(name = "操作参数")
private byte[] operParams;
/** 操作时间 */
@ApiModelProperty(name = "操作时间")
private Long operTime;
}

View File

@ -0,0 +1,39 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "操作日志关系记录")
@TableName("operating_log_resource")
@Data
public class OperatingLogResource implements Serializable {
private static final long serialVersionUID = 1L;
/** ID */
@TableId
@NotBlank(message = "ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "ID")
private String id;
/** Operating log ID */
@Size(min = 1, max = 50, message = "Operating log ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Operating log ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "Operating log ID")
private String operatingLogId;
/** operating source id */
@Size(min = 1, max = 50, message = "operating source id长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "operating source id不能为空", groups = {Created.class})
@ApiModelProperty(name = "operating source id")
private String sourceId;
}

View File

@ -0,0 +1,105 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "插件")
@TableName("plugin")
@Data
public class Plugin implements Serializable {
private static final long serialVersionUID = 1L;
/** ID */
@TableId
@NotBlank(message = "ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "ID")
private String id;
/** plugin name */
@ApiModelProperty(name = "plugin name")
private String name;
/** Plugin id */
@Size(min = 1, max = 300, message = "Plugin id长度必须在1-300之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Plugin id不能为空", groups = {Created.class})
@ApiModelProperty(name = "Plugin id")
private String pluginId;
/** Ui script id */
@Size(min = 1, max = 300, message = "Ui script id长度必须在1-300之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Ui script id不能为空", groups = {Created.class})
@ApiModelProperty(name = "Ui script id")
private String scriptId;
/** Plugin clazzName */
@Size(min = 1, max = 500, message = "Plugin clazzName长度必须在1-500之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Plugin clazzName不能为空", groups = {Created.class})
@ApiModelProperty(name = "Plugin clazzName")
private String clazzName;
/** Jmeter base clazzName */
@Size(min = 1, max = 300, message = "Jmeter base clazzName长度必须在1-300之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Jmeter base clazzName不能为空", groups = {Created.class})
@ApiModelProperty(name = "Jmeter base clazzName")
private String jmeterClazz;
/** Plugin jar path */
@Size(min = 1, max = 300, message = "Plugin jar path长度必须在1-300之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Plugin jar path不能为空", groups = {Created.class})
@ApiModelProperty(name = "Plugin jar path")
private String sourcePath;
/** Plugin jar name */
@Size(min = 1, max = 300, message = "Plugin jar name长度必须在1-300之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Plugin jar name不能为空", groups = {Created.class})
@ApiModelProperty(name = "Plugin jar name")
private String sourceName;
/** plugin init entry class */
@ApiModelProperty(name = "plugin init entry class")
private String execEntry;
/** */
@ApiModelProperty(name = "")
private Long createTime;
/** */
@ApiModelProperty(name = "")
private Long updateTime;
/** */
@ApiModelProperty(name = "")
private String createUser;
/** Is xpack plugin */
@ApiModelProperty(name = "Is xpack plugin")
private Boolean xpack;
/** Plugin usage scenarios */
@Size(min = 1, max = 50, message = "Plugin usage scenarios长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Plugin usage scenarios不能为空", groups = {Created.class})
@ApiModelProperty(name = "Plugin usage scenarios")
private String scenario;
}

View File

@ -0,0 +1,39 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "插件大字段")
@TableName("plugin_blob")
@Data
public class PluginBlob implements Serializable {
private static final long serialVersionUID = 1L;
/** ID */
@TableId
@NotBlank(message = "ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "ID")
private String pluginId;
/** plugin form option */
@ApiModelProperty(name = "plugin form option")
private byte[] formOption;
/** plugin form script */
@ApiModelProperty(name = "plugin form script")
private byte[] formScript;
}

View File

@ -0,0 +1,105 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "配额")
@TableName("quota")
@Data
public class Quota implements Serializable {
private static final long serialVersionUID = 1L;
/** */
@TableId
@NotBlank(message = "不能为空", groups = {Updated.class})
@ApiModelProperty(name = "")
private String id;
/** 接口数量 */
@ApiModelProperty(name = "接口数量")
private Integer api;
/** 性能测试数量 */
@ApiModelProperty(name = "性能测试数量")
private Integer performance;
/** 最大并发数 */
@ApiModelProperty(name = "最大并发数")
private Integer maxThreads;
/** 最大执行时长 */
@ApiModelProperty(name = "最大执行时长")
private Integer duration;
/** 资源池列表 */
@ApiModelProperty(name = "资源池列表")
private String resourcePool;
/** 工作空间ID */
@ApiModelProperty(name = "工作空间ID")
private String workspaceId;
/** 是否使用默认值 */
@ApiModelProperty(name = "是否使用默认值")
private Boolean useDefault;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 成员数量限制 */
@ApiModelProperty(name = "成员数量限制")
private Integer member;
/** 项目数量限制 */
@ApiModelProperty(name = "项目数量限制")
private Integer project;
/** 项目类型配额 */
@ApiModelProperty(name = "项目类型配额")
private String projectId;
/** 总vum数 */
@ApiModelProperty(name = "总vum数")
private Double vumTotal;
/** 消耗的vum数 */
@ApiModelProperty(name = "消耗的vum数")
private Double vumUsed;
}

View File

@ -0,0 +1,99 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "定时任务")
@TableName("schedule")
@Data
public class Schedule implements Serializable {
private static final long serialVersionUID = 1L;
/** */
@TableId
@NotBlank(message = "不能为空", groups = {Updated.class})
@ApiModelProperty(name = "")
private String id;
/** qrtz UUID */
@ApiModelProperty(name = "qrtz UUID")
private String key;
/** 资源类型 */
@Size(min = 1, max = 50, message = "资源类型长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "资源类型不能为空", groups = {Created.class})
@ApiModelProperty(name = "资源类型")
private String type;
/** Schedule value */
@Size(min = 1, max = 255, message = "Schedule value长度必须在1-255之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Schedule value不能为空", groups = {Created.class})
@ApiModelProperty(name = "Schedule value")
private String value;
/** Schedule Job Class Name */
@Size(min = 1, max = 64, message = "Schedule Job Class Name长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Schedule Job Class Name不能为空", groups = {Created.class})
@ApiModelProperty(name = "Schedule Job Class Name")
private String job;
/** Schedule Eable */
@ApiModelProperty(name = "Schedule Eable")
private Boolean enable;
/** */
@ApiModelProperty(name = "")
private String resourceId;
/** 创建人 */
@Size(min = 1, max = 50, message = "创建人长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "创建人不能为空", groups = {Created.class})
@ApiModelProperty(name = "创建人")
private String createUser;
/** Create timestamp */
@ApiModelProperty(name = "Create timestamp")
private Long createTime;
/** Update timestamp */
@ApiModelProperty(name = "Update timestamp")
private Long updateTime;
/** 项目ID */
@ApiModelProperty(name = "项目ID")
private String projectId;
/** 名称 */
@ApiModelProperty(name = "名称")
private String name;
/** 配置 */
@ApiModelProperty(name = "配置")
private String config;
}

View File

@ -0,0 +1,45 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "服务集成")
@TableName("service_integration")
@Data
public class ServiceIntegration implements Serializable {
private static final long serialVersionUID = 1L;
/** */
@TableId
@NotBlank(message = "不能为空", groups = {Updated.class})
@ApiModelProperty(name = "")
private String id;
/** 平台 */
@Size(min = 1, max = 50, message = "平台长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "平台不能为空", groups = {Created.class})
@ApiModelProperty(name = "平台")
private String platform;
/** */
@ApiModelProperty(name = "")
private byte[] configuration;
/** 工作空间ID */
@ApiModelProperty(name = "工作空间ID")
private String workspaceId;
}

View File

@ -0,0 +1,39 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "系统参数")
@TableName("system_parameter")
@Data
public class SystemParameter implements Serializable {
private static final long serialVersionUID = 1L;
/** 参数名称 */
@TableId
@NotBlank(message = "参数名称不能为空", groups = {Updated.class})
@ApiModelProperty(name = "参数名称")
private String paramKey;
/** 参数值 */
@ApiModelProperty(name = "参数值")
private String paramValue;
/** 类型 */
@Size(min = 1, max = 100, message = "类型长度必须在1-100之间", groups = {Created.class, Updated.class})
@NotBlank(message = "类型不能为空", groups = {Created.class})
@ApiModelProperty(name = "类型")
private String type;
}

View File

@ -0,0 +1,57 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "测试资源池节点")
@TableName("test_resource")
@Data
public class TestResource implements Serializable {
private static final long serialVersionUID = 1L;
/** Test resource ID */
@TableId
@NotBlank(message = "Test resource ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "Test resource ID")
private String id;
/** Test resource pool ID this test resource belongs to */
@Size(min = 1, max = 50, message = "Test resource pool ID this test resource belongs to长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Test resource pool ID this test resource belongs to不能为空", groups = {Created.class})
@ApiModelProperty(name = "Test resource pool ID this test resource belongs to")
private String testResourcePoolId;
/** Test resource configuration */
@ApiModelProperty(name = "Test resource configuration")
private byte[] configuration;
/** Test resource status */
@Size(min = 1, max = 64, message = "Test resource status长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "Test resource status不能为空", groups = {Created.class})
@ApiModelProperty(name = "Test resource status")
private String status;
/** Create timestamp */
@ApiModelProperty(name = "Create timestamp")
private Long createTime;
/** Update timestamp */
@ApiModelProperty(name = "Update timestamp")
private Long updateTime;
}

View File

@ -0,0 +1,99 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "测试资源池")
@TableName("test_resource_pool")
@Data
public class TestResourcePool implements Serializable {
private static final long serialVersionUID = 1L;
/** 资源池ID */
@TableId
@NotBlank(message = "资源池ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "资源池ID")
private String id;
/** 名称 */
@Size(min = 1, max = 64, message = "名称长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "名称不能为空", groups = {Created.class})
@ApiModelProperty(name = "名称")
private String name;
/** 类型 */
@Size(min = 1, max = 30, message = "类型长度必须在1-30之间", groups = {Created.class, Updated.class})
@NotBlank(message = "类型不能为空", groups = {Created.class})
@ApiModelProperty(name = "类型")
private String type;
/** 描述 */
@ApiModelProperty(name = "描述")
private String description;
/** 状态 */
@Size(min = 1, max = 64, message = "状态长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "状态不能为空", groups = {Created.class})
@ApiModelProperty(name = "状态")
private String status;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 性能测试镜像 */
@ApiModelProperty(name = "性能测试镜像")
private String image;
/** 性能测试jvm配置 */
@ApiModelProperty(name = "性能测试jvm配置")
private String heap;
/** 性能测试gc配置 */
@ApiModelProperty(name = "性能测试gc配置")
private String gcAlgo;
/** 创建人 */
@ApiModelProperty(name = "创建人")
private String createUser;
/** 是否用于接口测试 */
@ApiModelProperty(name = "是否用于接口测试")
private Boolean api;
/** 是否用于性能测试 */
@ApiModelProperty(name = "是否用于性能测试")
private Boolean performance;
}

View File

@ -0,0 +1,99 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "用户")
@TableName("user")
@Data
public class User implements Serializable {
private static final long serialVersionUID = 1L;
/** 用户ID */
@TableId
@NotBlank(message = "用户ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "用户ID")
private String id;
/** 用户名 */
@Size(min = 1, max = 64, message = "用户名长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "用户名不能为空", groups = {Created.class})
@ApiModelProperty(name = "用户名")
private String name;
/** 用户邮箱 */
@Size(min = 1, max = 64, message = "用户邮箱长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "用户邮箱不能为空", groups = {Created.class})
@ApiModelProperty(name = "用户邮箱")
private String email;
/** 用户密码 */
@ApiModelProperty(name = "用户密码")
private String password;
/** 用户状态,启用或禁用 */
@Size(min = 1, max = 50, message = "用户状态启用或禁用长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "用户状态,启用或禁用不能为空", groups = {Created.class})
@ApiModelProperty(name = "用户状态,启用或禁用")
private String status;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 语言 */
@ApiModelProperty(name = "语言")
private String language;
/** 当前工作空间ID */
@ApiModelProperty(name = "当前工作空间ID")
private String lastWorkspaceId;
/** 手机号 */
@ApiModelProperty(name = "手机号")
private String phone;
/** 来源LOCAL OIDC CAS */
@Size(min = 1, max = 50, message = "来源LOCAL OIDC CAS长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "来源LOCAL OIDC CAS不能为空", groups = {Created.class})
@ApiModelProperty(name = "来源LOCAL OIDC CAS")
private String source;
/** 当前项目ID */
@ApiModelProperty(name = "当前项目ID")
private String lastProjectId;
/** 创建人 */
@Size(min = 1, max = 100, message = "创建人长度必须在1-100之间", groups = {Created.class, Updated.class})
@NotBlank(message = "创建人不能为空", groups = {Created.class})
@ApiModelProperty(name = "创建人")
private String createUser;
}

View File

@ -0,0 +1,39 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "用户扩展")
@TableName("user_extend")
@Data
public class UserExtend implements Serializable {
private static final long serialVersionUID = 1L;
/** 用户ID */
@TableId
@NotBlank(message = "用户ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "用户ID")
private String userId;
/** 其他平台对接信息 */
@ApiModelProperty(name = "其他平台对接信息")
private byte[] platformInfo;
/** UI本地调试地址 */
@ApiModelProperty(name = "UI本地调试地址")
private String seleniumServer;
}

View File

@ -0,0 +1,57 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "用户api key")
@TableName("user_key")
@Data
public class UserKey implements Serializable {
private static final long serialVersionUID = 1L;
/** user_key ID */
@TableId
@NotBlank(message = "user_key ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "user_key ID")
private String id;
/** 用户ID */
@Size(min = 1, max = 50, message = "用户ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "用户ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "用户ID")
private String createUser;
/** access_key */
@Size(min = 1, max = 50, message = "access_key长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "access_key不能为空", groups = {Created.class})
@ApiModelProperty(name = "access_key")
private String accessKey;
/** secret key */
@Size(min = 1, max = 50, message = "secret key长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "secret key不能为空", groups = {Created.class})
@ApiModelProperty(name = "secret key")
private String secretKey;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 状态 */
@ApiModelProperty(name = "状态")
private String status;
}

View File

@ -0,0 +1,75 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "用户组")
@TableName("user_role")
@Data
public class UserRole implements Serializable {
private static final long serialVersionUID = 1L;
/** 组ID */
@TableId
@NotBlank(message = "组ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "组ID")
private String id;
/** 组名称 */
@Size(min = 1, max = 64, message = "组名称长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "组名称不能为空", groups = {Created.class})
@ApiModelProperty(name = "组名称")
private String name;
/** 描述 */
@ApiModelProperty(name = "描述")
private String description;
/** 是否是系统用户组 */
@Size(min = 1, max = 1, message = "是否是系统用户组长度必须在1-1之间", groups = {Created.class, Updated.class})
@NotBlank(message = "是否是系统用户组不能为空", groups = {Created.class})
@ApiModelProperty(name = "是否是系统用户组")
private Boolean system;
/** 所属类型 */
@Size(min = 1, max = 20, message = "所属类型长度必须在1-20之间", groups = {Created.class, Updated.class})
@NotBlank(message = "所属类型不能为空", groups = {Created.class})
@ApiModelProperty(name = "所属类型")
private String type;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 创建人(操作人) */
@Size(min = 1, max = 64, message = "创建人(操作人长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "创建人(操作人)不能为空", groups = {Created.class})
@ApiModelProperty(name = "创建人(操作人)")
private String createUser;
/** 应用范围 */
@Size(min = 1, max = 64, message = "应用范围长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "应用范围不能为空", groups = {Created.class})
@ApiModelProperty(name = "应用范围")
private String scopeId;
}

View File

@ -0,0 +1,45 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "用户组权限")
@TableName("user_role_permission")
@Data
public class UserRolePermission implements Serializable {
private static final long serialVersionUID = 1L;
/** */
@TableId
@NotBlank(message = "不能为空", groups = {Updated.class})
@ApiModelProperty(name = "")
private String id;
/** 用户组ID */
@Size(min = 1, max = 64, message = "用户组ID长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "用户组ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "用户组ID")
private String roleId;
/** 权限ID */
@Size(min = 1, max = 128, message = "权限ID长度必须在1-128之间", groups = {Created.class, Updated.class})
@NotBlank(message = "权限ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "权限ID")
private String permissionId;
/** 功能菜单 */
@Size(min = 1, max = 64, message = "功能菜单长度必须在1-64之间", groups = {Created.class, Updated.class})
@NotBlank(message = "功能菜单不能为空", groups = {Created.class})
@ApiModelProperty(name = "功能菜单")
private String moduleId;
}

View File

@ -0,0 +1,57 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "用户组关系")
@TableName("user_role_relation")
@Data
public class UserRoleRelation implements Serializable {
private static final long serialVersionUID = 1L;
/** 用户组关系ID */
@TableId
@NotBlank(message = "用户组关系ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "用户组关系ID")
private String id;
/** 用户ID */
@Size(min = 1, max = 50, message = "用户ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "用户ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "用户ID")
private String userId;
/** 组ID */
@Size(min = 1, max = 50, message = "组ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "组ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "组ID")
private String roleId;
/** 工作空间或项目ID */
@Size(min = 1, max = 50, message = "工作空间或项目ID长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "工作空间或项目ID不能为空", groups = {Created.class})
@ApiModelProperty(name = "工作空间或项目ID")
private String sourceId;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
}

View File

@ -0,0 +1,57 @@
package io.metersphere.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.metersphere.validation.groups.Created;
import io.metersphere.validation.groups.Updated;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.Size;
import lombok.Data;
import java.io.Serializable;
@ApiModel(value = "工作空间")
@TableName("workspace")
@Data
public class Workspace implements Serializable {
private static final long serialVersionUID = 1L;
/** 工作空间ID */
@TableId
@NotBlank(message = "工作空间ID不能为空", groups = {Updated.class})
@ApiModelProperty(name = "工作空间ID")
private String id;
/** 工作空间名称 */
@Size(min = 1, max = 100, message = "工作空间名称长度必须在1-100之间", groups = {Created.class, Updated.class})
@NotBlank(message = "工作空间名称不能为空", groups = {Created.class})
@ApiModelProperty(name = "工作空间名称")
private String name;
/** 描述 */
@ApiModelProperty(name = "描述")
private String description;
/** 创建时间 */
@ApiModelProperty(name = "创建时间")
private Long createTime;
/** 更新时间 */
@ApiModelProperty(name = "更新时间")
private Long updateTime;
/** 创建人 */
@Size(min = 1, max = 50, message = "创建人长度必须在1-50之间", groups = {Created.class, Updated.class})
@NotBlank(message = "创建人不能为空", groups = {Created.class})
@ApiModelProperty(name = "创建人")
private String createUser;
}

View File

@ -0,0 +1,4 @@
package io.metersphere.validation.groups;
public interface Created {
}

View File

@ -0,0 +1,4 @@
package io.metersphere.validation.groups;
public interface Updated {
}

View File

@ -1,77 +0,0 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE generatorConfiguration PUBLIC "-//mybatis.org//DTD MyBatis Generator Configuration 1.0//EN"
"http://mybatis.org/dtd/mybatis-generator-config_1_0.dtd" >
<generatorConfiguration>
<!--配置数据库连接的位置-->
<properties url="file:///opt/metersphere/conf/metersphere.properties"/>
<!-- 设置mysql驱动路径 -->
<!--<classPathEntry location="/Users/liuruibin/.m2/repository/mysql/mysql-connector-java/5.1.34/mysql-connector-java-5.1.34.jar"/>-->
<!-- 此处指定生成针对MyBatis3的DAO -->
<context id="mysql" targetRuntime="MyBatis3">
<!-- 字段带`,解决列表跟关键字冲突问题 -->
<property name="autoDelimitKeywords" value="true"/>
<property name="beginningDelimiter" value="`"/>
<property name="endingDelimiter" value="`"/>
<plugin type="org.mybatis.generator.plugins.SerializablePlugin"/>
<plugin type="org.mybatis.generator.plugins.UnmergeableXmlMappersPlugin"/>
<!-- Lombok插件 -->
<plugin type="com.itfsw.mybatis.generator.plugins.LombokPlugin">
<!-- @Data 默认开启,同时插件会对子类自动附加@EqualsAndHashCode(callSuper = true)@ToString(callSuper = true) -->
<property name="@Data" value="true"/>
<!-- @Builder 必须在 Lombok 版本 >= 1.18.2 的情况下开启,对存在继承关系的类自动替换成@SuperBuilder -->
<property name="@Builder" value="false"/>
<!-- @NoArgsConstructor 和 @AllArgsConstructor 使用规则和Lombok一致 -->
<property name="@AllArgsConstructor" value="false"/>
<property name="@NoArgsConstructor" value="false"/>
<!-- @Getter、@Setter、@Accessors 等使用规则参见官方文档 -->
<property name="@Accessors(chain = true)" value="false"/>
<!-- 临时解决IDEA工具对@SuperBuilder的不支持问题开启后(默认未开启)插件在遇到@SuperBuilder注解时会调用ModelBuilderPlugin来生成相应的builder代码 -->
<property name="supportSuperBuilderForIdea" value="false"/>
</plugin>
<!-- 用来除去时间信息的这在配合类似subversion的代码管理工具时使用很有效因为可以减少没有必要的注释迁入 -->
<commentGenerator>
<property name="suppressDate" value="true"/>
<!-- 关闭自动生成的注释 -->
<property name="suppressAllComments" value="true"/>
</commentGenerator>
<!-- jdbc连接信息 --> <!-- EduLoanManage EduTestDataBase -->
<!--<jdbcConnection driverClass="com.mysql.jdbc.Driver" connectionURL="jdbc:mysql://192.168.20.180:3306/fit2cloud"-->
<!--userId="root" password="Fit2cloud2015!" />-->
<jdbcConnection driverClass="com.mysql.cj.jdbc.Driver"
connectionURL="${spring.datasource.url}&amp;nullCatalogMeansCurrent=true"
userId="${spring.datasource.username}" password="${spring.datasource.password}"/>
<!-- javaTypeResolver式类型转换的信息 -->
<javaTypeResolver>
<property name="forceBigDecimals" value="false"/>
</javaTypeResolver>
<!-- 模型对象 -->
<javaModelGenerator targetPackage="io.metersphere.base.domain" targetProject="src/main/java">
<property name="enableSubPackages" value="true"/>
<property name="trimStrings" value="true"/>
</javaModelGenerator>
<!-- XML映射文件 -->
<sqlMapGenerator targetPackage="io.metersphere.base.mapper" targetProject="src/main/java">
<property name="enableSubPackages" value="true"/>
</sqlMapGenerator>
<!-- 接口 -->
<javaClientGenerator type="XMLMAPPER" targetPackage="io.metersphere.base.mapper"
targetProject="src/main/java">
<property name="enableSubPackages" value="true"/>
</javaClientGenerator>
<!--要生成的数据库表 -->
<table tableName="custom_field"/>
<!-- 要忽略的字段-->
<!-- <table tableName="test_case">
<ignoreColumn column="follow_people"/>
</table>-->
<!-- 表名和关键字冲突-->
<!-- <table tableName="group" delimitIdentifiers="true"></table>-->
</context>
</generatorConfiguration>

View File

@ -7,6 +7,8 @@ import io.metersphere.sdk.interceptor.MybatisInterceptor;
import io.metersphere.sdk.interceptor.UserDesensitizationInterceptor;
import io.metersphere.sdk.util.CompressUtils;
import io.metersphere.sdk.util.MybatisInterceptorConfig;
import io.metersphere.system.domain.AuthSource;
import io.metersphere.system.domain.TestResource;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.jdbc.DataSourceProperties;
@ -45,7 +47,8 @@ public class MybatisConfig {
public MybatisInterceptor dbInterceptor() {
MybatisInterceptor interceptor = new MybatisInterceptor();
List<MybatisInterceptorConfig> configList = new ArrayList<>();
// configList.add(new MybatisInterceptorConfig(FileContent.class, "file", CompressUtils.class, "zip", "unzip"));
configList.add(new MybatisInterceptorConfig(TestResource.class, "configuration", CompressUtils.class, "zip", "unzip"));
configList.add(new MybatisInterceptorConfig(AuthSource.class, "configuration", CompressUtils.class, "zip", "unzip"));
interceptor.setInterceptorConfigList(configList);
return interceptor;
}

View File

@ -1,6 +1,6 @@
package io.metersphere.sdk.interceptor;
import io.metersphere.domain.User;
import io.metersphere.system.domain.User;
import org.apache.ibatis.cache.CacheKey;
import org.apache.ibatis.executor.Executor;
import org.apache.ibatis.mapping.BoundSql;

View File

@ -1,7 +1,7 @@
package io.metersphere.sdk.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import io.metersphere.domain.User;
import io.metersphere.system.domain.User;
public interface UserMapper extends BaseMapper<User> {
}

View File

@ -1,7 +1,7 @@
package io.metersphere.sdk;
package io.metersphere.sdk.service;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import io.metersphere.domain.User;
import io.metersphere.system.domain.User;
import io.metersphere.sdk.mapper.UserMapper;
import org.springframework.stereotype.Service;

View File

@ -1,8 +1,8 @@
package io.metersphere.system.controller;
import io.metersphere.domain.User;
import io.metersphere.sdk.UserService;
import io.metersphere.system.domain.User;
import io.metersphere.sdk.service.UserService;
import jakarta.annotation.Resource;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;