提交 2892e4fa authored 作者: mry's avatar mry

fix(base): 修改了主键id类型

上级 20acdede
......@@ -28,10 +28,10 @@ public class Action extends BaseEntity {
private String name;
@ApiModelProperty("行为ID")
private Integer moveId;
private Long moveId;
@ApiModelProperty("项目ID")
private Integer projectId;
private Long projectId;
@ApiModelProperty("备注")
private String remark;
......
......@@ -19,7 +19,7 @@ import org.matrix.actuators.datasource.DataSourceDTO;
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "Connect对象", description = "")
@ApiModel(value = "Connect对象", description = "数据库")
@TableName(value = "kt_connect")
public class Connect extends BaseEntity {
......
......@@ -22,12 +22,12 @@ import org.matrix.enums.DynamicVarType;
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "DynamicVariable对象", description = "")
@ApiModel(value = "DynamicVariable对象", description = "动参")
@TableName(value = "kt_dynamic_variable")
public class DynamicVariable extends BaseEntity {
@ApiModelProperty("所属项目")
private Integer projectId;
private Long projectId;
@ApiModelProperty("取用字段")
private String takenField;
......
......@@ -35,7 +35,7 @@ public class Environment extends BaseEntity {
private String parameterName;
@ApiModelProperty("项目ID")
private Integer projectId;
private Long projectId;
@ApiModelProperty("静态变量,以JSON的形式存储,例如({\"name\":\"张三\"})")
@TableField(typeHandler = FastjsonTypeHandler.class)
......
......@@ -17,7 +17,7 @@ import lombok.*;
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "Move对象", description = "")
@ApiModel(value = "Move对象", description = "行为")
@TableName(value = "kt_move")
public class Move extends BaseEntity {
......@@ -25,7 +25,7 @@ public class Move extends BaseEntity {
private String name;
@ApiModelProperty("所属项目")
private Integer projectId;
private Long projectId;
@ApiModelProperty("备注")
private String remark;
......
......@@ -17,7 +17,7 @@ import lombok.*;
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "Project对象", description = "")
@ApiModel(value = "Project对象", description = "项目")
@TableName(value = "kt_project")
public class Project extends BaseEntity {
......
......@@ -18,14 +18,14 @@ import lombok.*;
@AllArgsConstructor
@EqualsAndHashCode(callSuper = true)
@TableName("kt_test_case")
@ApiModel(value = "TestCase对象", description = "")
@ApiModel(value = "TestCase对象", description = "用例")
public class TestCase extends BaseEntity {
@ApiModelProperty("名称")
private String name;
@ApiModelProperty("所属项目")
private Integer projectId;
private Long projectId;
@ApiModelProperty("用例类型 1为http")
private Integer type;
......
......@@ -87,9 +87,7 @@ public class MoveController {
.eq(Action::getMoveId, moveId)))
.orElse(new ArrayList<>());
MoveAction ma = new MoveAction(move, actionList);
return ma != null
? CommonResult.success(ma, "查询成功")
: CommonResult.failed(ma, "查询失败或无数据");
return CommonResult.success(ma, "查询成功");
}
/**
......@@ -103,7 +101,7 @@ public class MoveController {
public ResponseEntity<CommonResultObj<MoveAction>> insertMoveAction(@RequestBody MoveAction moveAction) {
Boolean moveBoolean = Optional.of(moveService.save(moveAction.getMove()))
.orElseThrow(GlobalException::new);
Integer id = Math.toIntExact(moveAction.getMove().getId());
Long id = moveAction.getMove().getId();
if (moveAction.getAction().size() != 0) {
for (Action action : moveAction.getAction()) {
action.setMoveId(id);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论