|
@@ -108,7 +108,7 @@ public class AitagTagCategoryServiceImpl implements AitagTagCategoryService {
|
|
|
// 检查标签数量
|
|
// 检查标签数量
|
|
|
int tagCount = aiTagCategoryMapper.countTagsByCategoryId(id);
|
|
int tagCount = aiTagCategoryMapper.countTagsByCategoryId(id);
|
|
|
if (tagCount == 0) {
|
|
if (tagCount == 0) {
|
|
|
- throw new RuntimeException("体系内无可用标签!");
|
|
|
|
|
|
|
+ throw new RuntimeException("该体系下无标签数据,请先完成标签配置");
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
// 检查当前状态
|
|
// 检查当前状态
|
|
@@ -144,7 +144,7 @@ public class AitagTagCategoryServiceImpl implements AitagTagCategoryService {
|
|
|
// 判断标签数量是否为 0
|
|
// 判断标签数量是否为 0
|
|
|
int tagCount = aiTagCategoryMapper.countTagsByCategoryId(id);
|
|
int tagCount = aiTagCategoryMapper.countTagsByCategoryId(id);
|
|
|
if (tagCount > 0) {
|
|
if (tagCount > 0) {
|
|
|
- throw new RuntimeException("该标签体系下仍有标签,无法删除");
|
|
|
|
|
|
|
+ throw new RuntimeException("该体系下存在标签数据,为确保业务数据完整性,禁止删除,请先清理关联内容");
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
aiTagCategoryMapper.deleteCategory(id);
|
|
aiTagCategoryMapper.deleteCategory(id);
|