fix 标注结果插入报错的问题

This commit is contained in:
weiweiw 2024-11-29 17:28:45 +08:00
parent b110880fe3
commit cbfa932648
1 changed files with 10 additions and 8 deletions

View File

@ -283,20 +283,22 @@
<update id="updateAnnotationInfo" parameterType="com.bonus.ai.domain.dataset.AnnotationTaskAnnotatorEntity">
UPDATE ai_annotation_task_annotator_map
<set>
<if test="annotationResult != null and annotationResult != ''">
<choose>
<when test="annotationResult != null and annotationResult != ''">
annotation_result = #{annotationResult},
annotation_time = sysdate(),
annotateTaskStatus = '1',
</if>
<if test="auditFailedReason != null and auditFailedReason == ''">
annotationStatus = '1',
</when>
<when test="auditFailedReason != null and auditFailedReason == ''">
audit_failed_reason = #{auditFailedReason},
review_time = sysdate(),
annotation_status = '3',
</if>
<if test="annotateTaskStatus != null and annotateTaskStatus == '2'">
annotateTaskStatus = #{annotateTaskStatus},
</when>
<when test="annotationStatus != null and annotationStatus == '2'">
annotationStatus = #{annotationStatus},
review_time = sysdate(),
</if>
</when>
</choose>
<if test="annotationResource != null and annotationResource != ''">annotation_resource = #{annotationResource},</if>
<if test="labelStudioProjectId != null">label_studio_project_id = #{labelStudioProjectId},</if>
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>