This commit is contained in:
张磊 2025-06-09 21:14:34 +08:00
parent df83e8418c
commit 2cda46fe21
1 changed files with 2 additions and 2 deletions

View File

@ -104,7 +104,7 @@ public class NewsInfoService {
List<Industry> industries = industryMapper.queryAll();
for (Industry industryItem: industries) {
if (industry.equals(industryItem.getPrimaryName()) || industryItem.equals(industryItem.getSecondaryName())) {
industryMapper.saveNewsIndustryRel(newsInfo.getNewsId(), industryItem.getId());
industryMapper.saveNewsIndustryRel(relNews.getId(), industryItem.getId());
}
}
}
@ -114,7 +114,7 @@ public class NewsInfoService {
List<Tag> matchedTags = tagMapper.queryTag(1L, sourcename, null, "create_time", null);
for (Tag tag: matchedTags) {
if (tag.getName().equals(sourcename)) {
tagMapper.saveNewsTagRel(newsInfo.getNewsId(), tag.getId());
tagMapper.saveNewsTagRel(relNews.getId(), tag.getId());
}
}
}