Commit 896875f7 authored by linpeiqin's avatar linpeiqin

增加模型评估的任务状态

parent c847d403
...@@ -57,6 +57,7 @@ public class ModelEstimateController { ...@@ -57,6 +57,7 @@ public class ModelEstimateController {
@PostMapping("/add") @PostMapping("/add")
public ResponseResult<Long> add( public ResponseResult<Long> add(
@MyRequestBody ModelEstimateDto modelEstimateDto) { @MyRequestBody ModelEstimateDto modelEstimateDto) {
modelEstimateDto.setTaskStatus(0);
Long modelVersionId = modelEstimateDto.getModelVersionId(); Long modelVersionId = modelEstimateDto.getModelVersionId();
ModelVersion modelVersion = this.modelVersionService.getById(modelVersionId); ModelVersion modelVersion = this.modelVersionService.getById(modelVersionId);
ModelTaskDto modelTaskDto = new ModelTaskDto(); ModelTaskDto modelTaskDto = new ModelTaskDto();
......
...@@ -13,6 +13,7 @@ ...@@ -13,6 +13,7 @@
<result column="dataset_version_id" jdbcType="BIGINT" property="datasetVersionId"/> <result column="dataset_version_id" jdbcType="BIGINT" property="datasetVersionId"/>
<result column="scoring_mode" jdbcType="TINYINT" property="scoringMode"/> <result column="scoring_mode" jdbcType="TINYINT" property="scoringMode"/>
<result column="configuration" jdbcType="LONGVARCHAR" property="configuration"/> <result column="configuration" jdbcType="LONGVARCHAR" property="configuration"/>
<result column="task_status" jdbcType="TINYINT" property="taskStatus"/>
</resultMap> </resultMap>
<insert id="insertList"> <insert id="insertList">
...@@ -27,7 +28,8 @@ ...@@ -27,7 +28,8 @@
model_version_id, model_version_id,
dataset_version_id, dataset_version_id,
scoring_mode, scoring_mode,
configuration) configuration,
task_status)
VALUES VALUES
<foreach collection="list" index="index" item="item" separator=","> <foreach collection="list" index="index" item="item" separator=",">
(#{item.taskId}, (#{item.taskId},
...@@ -40,7 +42,8 @@ ...@@ -40,7 +42,8 @@
#{item.modelVersionId}, #{item.modelVersionId},
#{item.datasetVersionId}, #{item.datasetVersionId},
#{item.scoringMode}, #{item.scoringMode},
#{item.configuration}) #{item.configuration},
#{item.taskStatus})
</foreach> </foreach>
</insert> </insert>
......
...@@ -59,6 +59,11 @@ public class ModelEstimateDto { ...@@ -59,6 +59,11 @@ public class ModelEstimateDto {
*/ */
@ApiModelProperty(value = "参数配置") @ApiModelProperty(value = "参数配置")
private String configuration; private String configuration;
/**
* 任务状态。
*/
@ApiModelProperty(value = "任务状态")
private Integer taskStatus;
/** /**
* task_name LIKE搜索字符串。 * task_name LIKE搜索字符串。
......
...@@ -59,7 +59,10 @@ public class ModelEstimate extends BaseModel { ...@@ -59,7 +59,10 @@ public class ModelEstimate extends BaseModel {
* 参数配置。 * 参数配置。
*/ */
private String configuration; private String configuration;
/**
* 任务状态。
*/
private Integer taskStatus;
/** /**
* task_name LIKE搜索字符串。 * task_name LIKE搜索字符串。
*/ */
......
...@@ -60,6 +60,12 @@ public class ModelEstimateVo extends BaseVo { ...@@ -60,6 +60,12 @@ public class ModelEstimateVo extends BaseVo {
@ApiModelProperty(value = "参数配置") @ApiModelProperty(value = "参数配置")
private String configuration; private String configuration;
/**
* 任务状态。
*/
@ApiModelProperty(value = "任务状态")
private Integer taskStatus;
/** /**
* taskId 的一对一关联数据对象,数据对应类型为ModelTaskVo。 * taskId 的一对一关联数据对象,数据对应类型为ModelTaskVo。
*/ */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment