提交 ad7ff7a7 作者: obcy

【采集词添加元搜索标识-通知采集只取标识打开的】

上级 4eb62d03
...@@ -555,6 +555,8 @@ public class SubjectManageController { ...@@ -555,6 +555,8 @@ public class SubjectManageController {
@PostMapping(value = "/keyWordsBindScope") @PostMapping(value = "/keyWordsBindScope")
public Result<?> keyWordsBindScope(@RequestBody SubjectKeywordsMap subjectKeywordsMap) { public Result<?> keyWordsBindScope(@RequestBody SubjectKeywordsMap subjectKeywordsMap) {
subjectKeywordsMapService.updateById(subjectKeywordsMap); subjectKeywordsMapService.updateById(subjectKeywordsMap);
//同步配置到采集
configurationMessageService.bindKeyWordsSend(subjectKeywordsMap.getSubjectId());
return Result.OK(); return Result.OK();
} }
......
...@@ -62,5 +62,5 @@ public interface KeyWordsMapper extends BaseMapper<KeyWords> { ...@@ -62,5 +62,5 @@ public interface KeyWordsMapper extends BaseMapper<KeyWords> {
Integer countByTypeAndIdList(@Param("finalIdList") List<String> finalIdList, @Param("subjectId") String subjectId); Integer countByTypeAndIdList(@Param("finalIdList") List<String> finalIdList, @Param("subjectId") String subjectId);
List<KeyWordsPage> bindKeyWordsListByIdsAndBindType(@Param("subjectIds") List<String> ids, @Param("bindingType") String bindingType); List<KeyWordsPage> bindKeyWordsListByIdsAndBindType(@Param("subjectIds") List<String> ids, @Param("bindingType") String bindingType, @Param("metaSearchFlag") Integer metaSearchFlag);
} }
...@@ -136,6 +136,9 @@ ...@@ -136,6 +136,9 @@
<if test="bindingType!=null and bindingType != ''"> <if test="bindingType!=null and bindingType != ''">
and a.binding_type = #{bindingType} and a.binding_type = #{bindingType}
</if> </if>
<if test="metaSearchFlag!=null">
and a.meta_search_flag = #{metaSearchFlag}
</if>
group by b.id group by b.id
</select> </select>
</mapper> </mapper>
...@@ -89,5 +89,5 @@ public interface IKeyWordsService extends IService<KeyWords> { ...@@ -89,5 +89,5 @@ public interface IKeyWordsService extends IService<KeyWords> {
Integer countByTypeAndIdList(List<String> finalIdList, String subjectId); Integer countByTypeAndIdList(List<String> finalIdList, String subjectId);
List<KeyWordsPage> bindKeyWordsListByIdsAndBindType(List<String> ids, String bindingType); List<KeyWordsPage> bindKeyWordsListByIdsAndBindType(List<String> ids, String bindingType,Integer metaSearchFlag);
} }
...@@ -165,7 +165,7 @@ public interface SubjectService extends IService<Subject> { ...@@ -165,7 +165,7 @@ public interface SubjectService extends IService<Subject> {
*/ */
void send(String subjectId, String status); void send(String subjectId, String status);
List<KeyWordsPage> bindKeyWordsListByIdsAndBindType(List<String> ids, String bindingType); List<KeyWordsPage> bindKeyWordsListByIdsAndBindType(List<String> ids, String bindingType,Integer metaSearchFlag);
Result<?> infoSourceBindNew(SubjectPage subjectPage); Result<?> infoSourceBindNew(SubjectPage subjectPage);
......
...@@ -304,7 +304,7 @@ public class ConfigurationMessageService { ...@@ -304,7 +304,7 @@ public class ConfigurationMessageService {
} }
List<String> subjectIdList = new ArrayList<>(); List<String> subjectIdList = new ArrayList<>();
subjectIdList.add(subjectId); subjectIdList.add(subjectId);
List<KeyWordsPage> keyWordsPages = subjectService.bindKeyWordsListByIdsAndBindType(subjectIdList,"1"); List<KeyWordsPage> keyWordsPages = subjectService.bindKeyWordsListByIdsAndBindType(subjectIdList,"1",1);
String keyWordsParam; String keyWordsParam;
if (CollectionUtil.isEmpty(keyWordsPages)) { if (CollectionUtil.isEmpty(keyWordsPages)) {
log.info("专题未绑定采集词组,通知采集清空"); log.info("专题未绑定采集词组,通知采集清空");
......
...@@ -293,7 +293,7 @@ public class KeyWordsServiceImpl extends ServiceImpl<KeyWordsMapper, KeyWords> i ...@@ -293,7 +293,7 @@ public class KeyWordsServiceImpl extends ServiceImpl<KeyWordsMapper, KeyWords> i
keywordsTypeMapService.save(keywordsTypeMap); keywordsTypeMapService.save(keywordsTypeMap);
} }
@Override @Override
public List<KeyWordsPage> bindKeyWordsListByIdsAndBindType(List<String> ids, String bindingType) { public List<KeyWordsPage> bindKeyWordsListByIdsAndBindType(List<String> ids, String bindingType,Integer metaSearchFlag) {
return baseMapper.bindKeyWordsListByIdsAndBindType(ids,bindingType); return baseMapper.bindKeyWordsListByIdsAndBindType(ids,bindingType,metaSearchFlag);
} }
} }
...@@ -421,6 +421,7 @@ public class SubjectServiceImpl extends ServiceImpl<SubjectMapper, Subject> impl ...@@ -421,6 +421,7 @@ public class SubjectServiceImpl extends ServiceImpl<SubjectMapper, Subject> impl
subjectKeywordsMap.setSubjectId(subjectPage.getId()); subjectKeywordsMap.setSubjectId(subjectPage.getId());
subjectKeywordsMap.setType(subjectPage.getType()); subjectKeywordsMap.setType(subjectPage.getType());
subjectKeywordsMap.setBindingType(subjectPage.getBindingType()); subjectKeywordsMap.setBindingType(subjectPage.getBindingType());
subjectKeywordsMap.setMetaSearchFlag(0);
mapList.add(subjectKeywordsMap); mapList.add(subjectKeywordsMap);
} }
subjectKeywordsMapService.saveBatch(mapList); subjectKeywordsMapService.saveBatch(mapList);
...@@ -775,8 +776,8 @@ public class SubjectServiceImpl extends ServiceImpl<SubjectMapper, Subject> impl ...@@ -775,8 +776,8 @@ public class SubjectServiceImpl extends ServiceImpl<SubjectMapper, Subject> impl
} }
@Override @Override
public List<KeyWordsPage> bindKeyWordsListByIdsAndBindType(List<String> ids, String bindingType) { public List<KeyWordsPage> bindKeyWordsListByIdsAndBindType(List<String> ids, String bindingType,Integer metaSearchFlag) {
return iKeyWordsService.bindKeyWordsListByIdsAndBindType(ids, bindingType); return iKeyWordsService.bindKeyWordsListByIdsAndBindType(ids, bindingType,metaSearchFlag);
} }
......
...@@ -35,5 +35,7 @@ public class SubjectKeywordsMap implements Serializable { ...@@ -35,5 +35,7 @@ public class SubjectKeywordsMap implements Serializable {
private String type; private String type;
/**绑定类型1:绑定为采集词,2:绑定为过滤词,3绑定为排除词组*/ /**绑定类型1:绑定为采集词,2:绑定为过滤词,3绑定为排除词组*/
private String bindingType; private String bindingType;
/**是否启用元搜索 1启用,0不启用*/
private Integer metaSearchFlag;
} }
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论