提交代码

This commit is contained in:
jiang 2024-11-20 16:26:17 +08:00
parent 4836ddea44
commit b70395f56b
4 changed files with 18 additions and 4 deletions

View File

@ -82,7 +82,7 @@ public class DataSetLabelsController extends BaseController
* 修改样本标签管理
*/
@RequiresPermissions("dataCenter:dataSetLabels:edit")
@PutMapping("/update")
@PostMapping("/update")
@SysLog(title = "样本标签管理", businessType = OperaType.UPDATE,logType = 0,module = "样本标签管理",details = "导出样本标签管理列表")
public AjaxResult edit(@RequestBody DataSetLabels dataSetLabels)
{
@ -99,4 +99,9 @@ public class DataSetLabelsController extends BaseController
{
return dataSetLabelsService.deleteDataSetLabelsByLabelIds(labelIds);
}
@PostMapping("/getLabelsTree/{labelId}")
public AjaxResult getLabelsTree(@PathVariable Long labelId){
return dataSetLabelsService.getLabelsTree(labelId);
}
}

View File

@ -52,4 +52,5 @@ public interface DataSetLabelsService
*/
public AjaxResult deleteDataSetLabelsByLabelIds(Long[] labelIds);
AjaxResult getLabelsTree(Long labelId);
}

View File

@ -38,7 +38,7 @@ public class DataSetLabelsServiceImpl implements DataSetLabelsService
if (ObjectUtils.isEmpty(dataSetLabels)) {
return AjaxResult.error();
}else {
return AjaxResult.success();
return AjaxResult.success(dataSetLabels);
}
}catch (Exception e){
return AjaxResult.error();
@ -112,4 +112,12 @@ public class DataSetLabelsServiceImpl implements DataSetLabelsService
}
}
@Override
public AjaxResult getLabelsTree(Long labelId) {
DataSetLabels entity = new DataSetLabels();
List<DataSetLabels> dataSetLabels = dataSetLabelsMapper.selectDataSetLabelsList(entity);
dataSetLabels.removeIf(item -> item.getLabelId().equals(labelId));
return AjaxResult.success(dataSetLabels);
}
}

View File

@ -20,12 +20,12 @@
AT.role_id AS roleId
FROM
ai_annotation_team_member AT
LEFT JOIN sys_user su ON AT.member_id = su.user_id AND su.del_flag='0' AND at.del_flag='0'
LEFT JOIN sys_user su ON AT.member_id = su.user_id AND su.del_flag='0'
</sql>
<select id="selectTeamMemberList" parameterType="com.bonus.ai.domain.DataSetTeamMemberEntity" resultType="com.bonus.ai.domain.DataSetTeamMemberEntity">
<include refid="selectTeamMemberVo"/>
<where>
at.del_flag='0'
AT.del_flag='0'
<if test="userName != null and userName != ''"> and su.nick_name like concat('%', #{userName}, '%')</if>
<if test="roleId != null and roleId != ''"> and AT.role_id = #{roleId}</if>
<if test="sex != null and sex != ''"> and su.sex = #{sex}</if>