提交 7e8df423 作者: 刘凯歌

合并分支 'dev_lkg_0604' 到 'event_fusion'

研究中心-列表默认不展示复合专题

查看合并请求 !2
...@@ -134,7 +134,7 @@ public class SubjectManageController { ...@@ -134,7 +134,7 @@ public class SubjectManageController {
* @date 2025/1/7 * @date 2025/1/7
*/ */
@GetMapping("/dictItemList") @GetMapping("/dictItemList")
public Result<?> dictItemList(@RequestParam(defaultValue = "Thematic_Library")String dictCode){ public Result<?> dictItemList(@RequestParam(defaultValue = "Thematic_Library") String dictCode) {
List<SysDictItem> dictItemList = sysDictItemService.listByDictCode(dictCode); List<SysDictItem> dictItemList = sysDictItemService.listByDictCode(dictCode);
return Result.OK(dictItemList); return Result.OK(dictItemList);
} }
...@@ -152,9 +152,9 @@ public class SubjectManageController { ...@@ -152,9 +152,9 @@ public class SubjectManageController {
public Result<?> researchCenterPageList(SubjectCondition subjectCondition, public Result<?> researchCenterPageList(SubjectCondition subjectCondition,
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
@RequestParam(required = false) String flagCode,HttpServletRequest request) { @RequestParam(required = false) String flagCode, HttpServletRequest request) {
UserVo loginUser = UserUtil.getLoginUser(); UserVo loginUser = UserUtil.getLoginUser();
Page<SubjectPage> pageList = subjectService.researchCenterPageList(subjectCondition, pageNo, pageSize,flagCode,request,loginUser.getUsername()); Page<SubjectPage> pageList = subjectService.researchCenterPageList(subjectCondition, pageNo, pageSize, flagCode, request, loginUser.getUsername());
return Result.OK(pageList); return Result.OK(pageList);
} }
...@@ -173,13 +173,14 @@ public class SubjectManageController { ...@@ -173,13 +173,14 @@ public class SubjectManageController {
@GetMapping("/visiblePageList") @GetMapping("/visiblePageList")
public Result<?> visiblePageList(@RequestParam Integer type, public Result<?> visiblePageList(@RequestParam Integer type,
@RequestParam(required = false) String subjectName, @RequestParam(required = false) String subjectName,
@RequestParam(defaultValue = "1") Integer subjectType,
@RequestParam(required = false) String environment, @RequestParam(required = false) String environment,
@RequestParam(required = false) String flagCode, @RequestParam(required = false) String flagCode,
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
HttpServletRequest request) { HttpServletRequest request) {
UserVo loginUser = UserUtil.getLoginUser(); UserVo loginUser = UserUtil.getLoginUser();
Page<Node> pageList = subjectService.visiblePageList(loginUser.getUsername(), type, subjectName, pageNo, pageSize,environment,request,flagCode); Page<Node> pageList = subjectService.visiblePageList(loginUser.getUsername(), type, subjectName, subjectType, pageNo, pageSize, environment, request, flagCode);
return Result.OK(pageList); return Result.OK(pageList);
} }
...@@ -199,13 +200,14 @@ public class SubjectManageController { ...@@ -199,13 +200,14 @@ public class SubjectManageController {
@GetMapping("/visiblePageListNoSign") @GetMapping("/visiblePageListNoSign")
public Result<?> visiblePageListNoSign(@RequestParam Integer type, public Result<?> visiblePageListNoSign(@RequestParam Integer type,
@RequestParam(required = false) String subjectName, @RequestParam(required = false) String subjectName,
@RequestParam(defaultValue = "1") Integer subjectType,
@RequestParam(required = false) String environment, @RequestParam(required = false) String environment,
@RequestParam(required = false) String flagCode, @RequestParam(required = false) String flagCode,
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
HttpServletRequest request) { HttpServletRequest request) {
UserVo loginUser = UserUtil.getLoginUser(); UserVo loginUser = UserUtil.getLoginUser();
Page<Node> pageList = subjectService.visiblePageList(loginUser.getUsername(), type, subjectName, pageNo, pageSize,environment,request,flagCode); Page<Node> pageList = subjectService.visiblePageList(loginUser.getUsername(), type, subjectName, subjectType, pageNo, pageSize, environment, request, flagCode);
return Result.OK(pageList); return Result.OK(pageList);
} }
...@@ -233,7 +235,7 @@ public class SubjectManageController { ...@@ -233,7 +235,7 @@ public class SubjectManageController {
* @date 2025/3/25 * @date 2025/3/25
*/ */
@GetMapping(value = "/statisticInfo") @GetMapping(value = "/statisticInfo")
private Result<?> statisticInfo(@RequestParam List<String> subjectIds){ private Result<?> statisticInfo(@RequestParam List<String> subjectIds) {
List<SubjectStatisticInfo> statisticInfoList = subjectService.statisticInfo(subjectIds); List<SubjectStatisticInfo> statisticInfoList = subjectService.statisticInfo(subjectIds);
//异步更新专题统计信息表的数据 //异步更新专题统计信息表的数据
CompletableFuture.runAsync(() -> { CompletableFuture.runAsync(() -> {
...@@ -409,7 +411,7 @@ public class SubjectManageController { ...@@ -409,7 +411,7 @@ public class SubjectManageController {
xxlJobInfoService.update(Wrappers.<XxlJobInfo>lambdaUpdate() xxlJobInfoService.update(Wrappers.<XxlJobInfo>lambdaUpdate()
.eq(XxlJobInfo::getInfoSourceCode, byId.getSubjectCode()) .eq(XxlJobInfo::getInfoSourceCode, byId.getSubjectCode())
.set(XxlJobInfo::getTriggerStatus, byId.getStatus())); .set(XxlJobInfo::getTriggerStatus, byId.getStatus()));
}else{ } else {
xxlJobInfoService.subjectInsert(byId); xxlJobInfoService.subjectInsert(byId);
} }
...@@ -426,15 +428,16 @@ public class SubjectManageController { ...@@ -426,15 +428,16 @@ public class SubjectManageController {
//获取code状态码 //获取code状态码
Integer code = entries.getInt("code"); Integer code = entries.getInt("code");
if (ObjectUtil.isEmpty(code) || code != 200) { if (ObjectUtil.isEmpty(code) || code != 200) {
log.error("专题状态同步采集失败{}",res); log.error("专题状态同步采集失败{}", res);
} }
} catch (Exception e) { } catch (Exception e) {
log.error("专题状态同步采集失败{}",e.getMessage(),e); log.error("专题状态同步采集失败{}", e.getMessage(), e);
} }
return Result.OK(); return Result.OK();
} }
/** /**
* 更新状态 * 更新状态
* *
...@@ -443,23 +446,24 @@ public class SubjectManageController { ...@@ -443,23 +446,24 @@ public class SubjectManageController {
*/ */
@PostMapping("/updateSubjectAllToCaiji") @PostMapping("/updateSubjectAllToCaiji")
public Result<?> updateSubjectAllToCaiji() { public Result<?> updateSubjectAllToCaiji() {
List<Subject> list = subjectService.list(Wrappers.<Subject>lambdaQuery().eq(Subject::getSubjectType,1)); List<Subject> list = subjectService.list(Wrappers.<Subject>lambdaQuery().eq(Subject::getSubjectType, 1));
for (int i = 0; i < list.size(); i++) { for (int i = 0; i < list.size(); i++) {
Subject subject = list.get(i); Subject subject = list.get(i);
log.info("专题状态同步采集{},index:{},total:{}",subject.getSubjectName(),i,list.size()); log.info("专题状态同步采集{},index:{},total:{}", subject.getSubjectName(), i, list.size());
if (subject.getStatus()!=null && subject.getStatus() == 1) { if (subject.getStatus() != null && subject.getStatus() == 1) {
configurationMessageService.bindInfoSourceSend(subject.getId()); configurationMessageService.bindInfoSourceSend(subject.getId());
configurationMessageService.bindKeyWordsSend(subject.getId()); configurationMessageService.bindKeyWordsSend(subject.getId());
caiJiCenterHttpService.subjectStatusEdit(subject.getStatus(), subject.getId()); caiJiCenterHttpService.subjectStatusEdit(subject.getStatus(), subject.getId());
configurationMessageService.subjectEnterpriseSourceSync(subject.getId()); configurationMessageService.subjectEnterpriseSourceSync(subject.getId());
log.info("专题配置信息同步采集成功:{}",subject.getSubjectName()); log.info("专题配置信息同步采集成功:{}", subject.getSubjectName());
}else{ } else {
caiJiCenterHttpService.delSubject(subject.getId()); caiJiCenterHttpService.delSubject(subject.getId());
log.info("通知采集删除专题成功:{}",subject.getSubjectName()); log.info("通知采集删除专题成功:{}", subject.getSubjectName());
} }
} }
return Result.OK(); return Result.OK();
} }
/** /**
* 更新状态 * 更新状态
* *
...@@ -471,14 +475,14 @@ public class SubjectManageController { ...@@ -471,14 +475,14 @@ public class SubjectManageController {
List<Event> list = eventService.list(); List<Event> list = eventService.list();
for (int i = 0; i < list.size(); i++) { for (int i = 0; i < list.size(); i++) {
Event event = list.get(i); Event event = list.get(i);
log.info("事件状态同步采集{},index:{},total:{}",event.getEventName(),i,list.size()); log.info("事件状态同步采集{},index:{},total:{}", event.getEventName(), i, list.size());
if (event.getStatus()!=null && event.getStatus() == 1) { if (event.getStatus() != null && event.getStatus() == 1) {
configurationMessageService.bindKeyWordsEventSend(event.getId()); configurationMessageService.bindKeyWordsEventSend(event.getId());
caiJiCenterHttpService.subjectStatusEdit(event.getStatus(), event.getId()); caiJiCenterHttpService.subjectStatusEdit(event.getStatus(), event.getId());
log.info("事件配置信息同步采集成功:{}",event.getEventName()); log.info("事件配置信息同步采集成功:{}", event.getEventName());
}else{ } else {
caiJiCenterHttpService.delSubject(event.getId()); caiJiCenterHttpService.delSubject(event.getId());
log.info("通知采集删除事件成功:{}",event.getEventName()); log.info("通知采集删除事件成功:{}", event.getEventName());
} }
} }
return Result.OK(); return Result.OK();
...@@ -506,10 +510,10 @@ public class SubjectManageController { ...@@ -506,10 +510,10 @@ public class SubjectManageController {
//获取code状态码 //获取code状态码
Integer code = entries.getInt("code"); Integer code = entries.getInt("code");
if (ObjectUtil.isEmpty(code) || code != 200) { if (ObjectUtil.isEmpty(code) || code != 200) {
log.error("专题删除同步采集失败{}",res); log.error("专题删除同步采集失败{}", res);
} }
} catch (Exception e) { } catch (Exception e) {
log.error("专题删除同步采集失败{}",e.getMessage(),e); log.error("专题删除同步采集失败{}", e.getMessage(), e);
} }
return Result.OK(); return Result.OK();
} }
...@@ -540,10 +544,10 @@ public class SubjectManageController { ...@@ -540,10 +544,10 @@ public class SubjectManageController {
//获取code状态码 //获取code状态码
Integer code = entries.getInt("code"); Integer code = entries.getInt("code");
if (ObjectUtil.isEmpty(code) || code != 200) { if (ObjectUtil.isEmpty(code) || code != 200) {
log.error("专题删除同步采集失败{}",res); log.error("专题删除同步采集失败{}", res);
} }
} catch (Exception e) { } catch (Exception e) {
log.error("专题删除同步采集失败{}",e.getMessage(),e); log.error("专题删除同步采集失败{}", e.getMessage(), e);
} }
} }
...@@ -618,8 +622,8 @@ public class SubjectManageController { ...@@ -618,8 +622,8 @@ public class SubjectManageController {
* @return * @return
*/ */
@GetMapping(value = "/bindKeyWordsList") @GetMapping(value = "/bindKeyWordsList")
public Result<?> bindKeyWordsList(@RequestParam(name = "id") String id,@RequestParam(name = "bindingType",required = false) String bindingType) { public Result<?> bindKeyWordsList(@RequestParam(name = "id") String id, @RequestParam(name = "bindingType", required = false) String bindingType) {
List<KeyWordsPage> bindKeyWordsList = subjectKeywordsMapService.bindKeyWordsList(id,bindingType); List<KeyWordsPage> bindKeyWordsList = subjectKeywordsMapService.bindKeyWordsList(id, bindingType);
return Result.OK(bindKeyWordsList); return Result.OK(bindKeyWordsList);
} }
...@@ -784,7 +788,6 @@ public class SubjectManageController { ...@@ -784,7 +788,6 @@ public class SubjectManageController {
} }
/** /**
* 专题打分模型配置信息详情 * 专题打分模型配置信息详情
* *
...@@ -861,16 +864,18 @@ public class SubjectManageController { ...@@ -861,16 +864,18 @@ public class SubjectManageController {
List<InfoSourceLabelVO> bindList = clbLabelService.bindInfoSourceLabelInfo(subjectId); List<InfoSourceLabelVO> bindList = clbLabelService.bindInfoSourceLabelInfo(subjectId);
return Result.OK(bindList); return Result.OK(bindList);
} }
/** /**
* 更新subject的数据范围 * 更新subject的数据范围
*
* @param subjectId 专题id * @param subjectId 专题id
*/ */
@GetMapping("/subjectUpdateScope") @GetMapping("/subjectUpdateScope")
public Result<?> subjectUpdateScope(@RequestParam(name = "subjectId") String subjectId, public Result<?> subjectUpdateScope(@RequestParam(name = "subjectId") String subjectId,
@RequestParam(name = "type") String type, @RequestParam(name = "type") String type,
@RequestParam(name = "scop" , defaultValue = "") String scop @RequestParam(name = "scop", defaultValue = "") String scop
) { ) {
Subject subject = subjectService.subjectUpdateScope(subjectId,type,scop); Subject subject = subjectService.subjectUpdateScope(subjectId, type, scop);
return Result.OK(subject); return Result.OK(subject);
} }
...@@ -967,7 +972,7 @@ public class SubjectManageController { ...@@ -967,7 +972,7 @@ public class SubjectManageController {
List<String> sourceIdList = subjectSourceVO.getSourceIdList(); List<String> sourceIdList = subjectSourceVO.getSourceIdList();
if (CollectionUtils.isEmpty(sourceIdList)) { if (CollectionUtils.isEmpty(sourceIdList)) {
LambdaQueryWrapper<InfoSource> queryWrapper = Wrappers.lambdaQuery(); LambdaQueryWrapper<InfoSource> queryWrapper = Wrappers.lambdaQuery();
queryWrapper.select(InfoSource::getId,InfoSource::getSiteName,InfoSource::getSiteUri) queryWrapper.select(InfoSource::getId, InfoSource::getSiteName, InfoSource::getSiteUri)
.in(InfoSource::getWebSiteName, subjectSourceVO.getWebSiteNameList()) .in(InfoSource::getWebSiteName, subjectSourceVO.getWebSiteNameList())
.groupBy(InfoSource::getId); .groupBy(InfoSource::getId);
List<InfoSource> infoSources = infoSourceService.list(queryWrapper); List<InfoSource> infoSources = infoSourceService.list(queryWrapper);
...@@ -1055,7 +1060,7 @@ public class SubjectManageController { ...@@ -1055,7 +1060,7 @@ public class SubjectManageController {
* @date 2025/1/9 * @date 2025/1/9
*/ */
@PostMapping("/removeDirectInfoSource") @PostMapping("/removeDirectInfoSource")
public Result<?> removeDirectInfoSource(@RequestBody List<SubjectBindDirectSourceVO> params){ public Result<?> removeDirectInfoSource(@RequestBody List<SubjectBindDirectSourceVO> params) {
for (SubjectBindDirectSourceVO param : params) { for (SubjectBindDirectSourceVO param : params) {
String subjectId = param.getSubjectId(); String subjectId = param.getSubjectId();
String webSiteName = param.getWebSiteName(); String webSiteName = param.getWebSiteName();
...@@ -1068,7 +1073,7 @@ public class SubjectManageController { ...@@ -1068,7 +1073,7 @@ public class SubjectManageController {
} else { } else {
List<String> webSiteNameList = new ArrayList<>(); List<String> webSiteNameList = new ArrayList<>();
webSiteNameList.add(webSiteName); webSiteNameList.add(webSiteName);
List<InfoSource> infoSources = infoSourceService.subjectBindSourceColumnList(subjectId,webSiteNameList); List<InfoSource> infoSources = infoSourceService.subjectBindSourceColumnList(subjectId, webSiteNameList);
sourceIdList = infoSources.stream().map(InfoSource::getId).collect(Collectors.toList()); sourceIdList = infoSources.stream().map(InfoSource::getId).collect(Collectors.toList());
} }
subjectInfoSourceMapService.remove(new LambdaQueryWrapper<SubjectInfoSourceMap>() subjectInfoSourceMapService.remove(new LambdaQueryWrapper<SubjectInfoSourceMap>()
...@@ -1117,9 +1122,9 @@ public class SubjectManageController { ...@@ -1117,9 +1122,9 @@ public class SubjectManageController {
if (originalFilename.endsWith(".xlsx") || originalFilename.endsWith(".xls")) { if (originalFilename.endsWith(".xlsx") || originalFilename.endsWith(".xls")) {
List<List<String>> dataList; List<List<String>> dataList;
if (originalFilename.endsWith(".xls")) { if (originalFilename.endsWith(".xls")) {
dataList = ExcelExportUtil.readExcelXls(file.getInputStream(), false,1, 2); dataList = ExcelExportUtil.readExcelXls(file.getInputStream(), false, 1, 2);
} else { } else {
dataList = ExcelExportUtil.readExcelXlsx(file.getInputStream(), false,1, 2); dataList = ExcelExportUtil.readExcelXlsx(file.getInputStream(), false, 1, 2);
} }
if (CollectionUtils.isNotEmpty(dataList)) { if (CollectionUtils.isNotEmpty(dataList)) {
boolean emptyFlag = false; boolean emptyFlag = false;
...@@ -1245,7 +1250,7 @@ public class SubjectManageController { ...@@ -1245,7 +1250,7 @@ public class SubjectManageController {
sourceIdList.add(countVO.getName()); sourceIdList.add(countVO.getName());
} }
LambdaQueryWrapper<InfoSource> queryWrapper = Wrappers.lambdaQuery(); LambdaQueryWrapper<InfoSource> queryWrapper = Wrappers.lambdaQuery();
queryWrapper.select(InfoSource::getId,InfoSource::getSiteName,InfoSource::getSiteUri).in(InfoSource::getId,sourceIdList); queryWrapper.select(InfoSource::getId, InfoSource::getSiteName, InfoSource::getSiteUri).in(InfoSource::getId, sourceIdList);
infoSources = infoSourceService.list(queryWrapper); infoSources = infoSourceService.list(queryWrapper);
} }
return Result.OK(infoSources); return Result.OK(infoSources);
...@@ -1394,7 +1399,7 @@ public class SubjectManageController { ...@@ -1394,7 +1399,7 @@ public class SubjectManageController {
String originalFilename = file.getOriginalFilename(); String originalFilename = file.getOriginalFilename();
if (originalFilename.endsWith(".txt")) { if (originalFilename.endsWith(".txt")) {
parseTxt(text, file); parseTxt(text, file);
} else if (originalFilename.endsWith(".docx")){ } else if (originalFilename.endsWith(".docx")) {
parseWordDocx(text, file); parseWordDocx(text, file);
} else if (originalFilename.endsWith(".doc")) { } else if (originalFilename.endsWith(".doc")) {
parseWordDoc(text, file); parseWordDoc(text, file);
...@@ -1418,7 +1423,7 @@ public class SubjectManageController { ...@@ -1418,7 +1423,7 @@ public class SubjectManageController {
} }
private List<StatisticsKeyWordVo> formatWordInfo(String text,List<String> wordsList){ private List<StatisticsKeyWordVo> formatWordInfo(String text, List<String> wordsList) {
List<StatisticsKeyWordVo> articleWordList = new ArrayList<>(); List<StatisticsKeyWordVo> articleWordList = new ArrayList<>();
Map<String, Integer> hitWordsAndTimes = HanlpUtil.getHitWordsAndTimes(wordsList, text); Map<String, Integer> hitWordsAndTimes = HanlpUtil.getHitWordsAndTimes(wordsList, text);
for (Map.Entry<String, Integer> entry : hitWordsAndTimes.entrySet()) { for (Map.Entry<String, Integer> entry : hitWordsAndTimes.entrySet()) {
......
...@@ -33,14 +33,14 @@ public interface SubjectMapper extends BaseMapper<Subject> { ...@@ -33,14 +33,14 @@ public interface SubjectMapper extends BaseMapper<Subject> {
Page<SubjectPage> pageList(@Param("subjectCondition") SubjectCondition subjectCondition, Page<SubjectPage> page); Page<SubjectPage> pageList(@Param("subjectCondition") SubjectCondition subjectCondition, Page<SubjectPage> page);
/** /**
*专题分页列表-新 * 专题分页列表-新
* *
* @param subjectCondition 查询条件 * @param subjectCondition 查询条件
* @param page 分页参数 * @param page 分页参数
* @author lkg * @author lkg
* @date 2025/3/25 * @date 2025/3/25
*/ */
Page<SubjectPageVO> pageList_new(Page<SubjectPageVO> page,@Param("subjectCondition") SubjectCondition subjectCondition,@Param("userId") String userId); Page<SubjectPageVO> pageList_new(Page<SubjectPageVO> page, @Param("subjectCondition") SubjectCondition subjectCondition, @Param("userId") String userId);
/** /**
* 专题详情(包含专题分类、专题项目) * 专题详情(包含专题分类、专题项目)
...@@ -50,6 +50,7 @@ public interface SubjectMapper extends BaseMapper<Subject> { ...@@ -50,6 +50,7 @@ public interface SubjectMapper extends BaseMapper<Subject> {
* @date 2025/3/25 * @date 2025/3/25
*/ */
SubjectPage getInfo(@Param("subjectId") String subjectId); SubjectPage getInfo(@Param("subjectId") String subjectId);
/** /**
* 专题分页列表(个人)-研究中心 * 专题分页列表(个人)-研究中心
* *
...@@ -68,7 +69,7 @@ public interface SubjectMapper extends BaseMapper<Subject> { ...@@ -68,7 +69,7 @@ public interface SubjectMapper extends BaseMapper<Subject> {
* @author lkg * @author lkg
* @date 2025/1/14 * @date 2025/1/14
*/ */
Page<SubjectPage> researchCenterFacePageList(@Param("subjectCondition") SubjectCondition subjectCondition, Page<SubjectPage> page,@Param("sql") String sql,@Param("username") String username); Page<SubjectPage> researchCenterFacePageList(@Param("subjectCondition") SubjectCondition subjectCondition, Page<SubjectPage> page, @Param("sql") String sql, @Param("username") String username);
/** /**
* 当前用户可见的专题分页列表(公开和个人非公开)-研究中心 * 当前用户可见的专题分页列表(公开和个人非公开)-研究中心
...@@ -76,11 +77,12 @@ public interface SubjectMapper extends BaseMapper<Subject> { ...@@ -76,11 +77,12 @@ public interface SubjectMapper extends BaseMapper<Subject> {
* @param username 用户名称 * @param username 用户名称
* @param type 分类(1-个人;2-公开;3-个人+公开) * @param type 分类(1-个人;2-公开;3-个人+公开)
* @param subjectName 专题名称 * @param subjectName 专题名称
* @param subjectType 专题类别(1:通用专题;3:研究中心主题专题[复合专题])
* @param page 分页参数 * @param page 分页参数
* @author lkg * @author lkg
* @date 2025/2/8 * @date 2025/2/8
*/ */
Page<Node> visibleList(@Param("username") String username, @Param("type") Integer type, @Param("subjectName") String subjectName, Page<String> page,@Param("environment") String environment,@Param("sql") String sql); Page<Node> visibleList(@Param("username") String username, @Param("type") Integer type, @Param("subjectName") String subjectName, @Param("subjectType") Integer subjectType, Page<String> page, @Param("environment") String environment, @Param("sql") String sql);
/** /**
* 获取专题详情(包含样例文章信息) * 获取专题详情(包含样例文章信息)
...@@ -120,7 +122,7 @@ public interface SubjectMapper extends BaseMapper<Subject> { ...@@ -120,7 +122,7 @@ public interface SubjectMapper extends BaseMapper<Subject> {
*/ */
int ynBelowExcludeGroup(@Param("subjectId") String subjectId, @Param("sourceId") String sourceId); int ynBelowExcludeGroup(@Param("subjectId") String subjectId, @Param("sourceId") String sourceId);
List<String> getBindSubjectIds(@Param("id")String id); List<String> getBindSubjectIds(@Param("id") String id);
String getMinCreateTime(@Param("subjectIdList") List<String> subjectIdList); String getMinCreateTime(@Param("subjectIdList") List<String> subjectIdList);
} }
...@@ -193,6 +193,9 @@ ...@@ -193,6 +193,9 @@
<if test="subjectCondition.username!=null and subjectCondition.username != ''"> <if test="subjectCondition.username!=null and subjectCondition.username != ''">
and d.create_by = #{subjectCondition.username} and d.create_by = #{subjectCondition.username}
</if> </if>
<if test="subjectCondition.subjectType != null">
and d.subject_type = #{subjectCondition.subjectType}
</if>
order by d.create_time desc order by d.create_time desc
</select> </select>
<select id="researchCenterFacePageList" resultType="com.zzsn.event.vo.SubjectPage"> <select id="researchCenterFacePageList" resultType="com.zzsn.event.vo.SubjectPage">
...@@ -236,6 +239,9 @@ ...@@ -236,6 +239,9 @@
<if test="subjectCondition.status!=null"> <if test="subjectCondition.status!=null">
and d.status = #{subjectCondition.status} and d.status = #{subjectCondition.status}
</if> </if>
<if test="subjectCondition.subjectType!=null">
and d.subject_type = #{subjectCondition.subjectType}
</if>
order by d.create_time desc order by d.create_time desc
</select> </select>
...@@ -286,6 +292,9 @@ ...@@ -286,6 +292,9 @@
<if test="subjectName != null and subjectName != ''"> <if test="subjectName != null and subjectName != ''">
and subject_name like concat('%',#{subjectName},'%') and subject_name like concat('%',#{subjectName},'%')
</if> </if>
<if test="subjectType!=null">
and subject_type = #{subjectType}
</if>
<if test="environment != null and environment != ''"> <if test="environment != null and environment != ''">
and environment = #{environment} and environment = #{environment}
</if> </if>
......
...@@ -76,12 +76,13 @@ public interface SubjectService extends IService<Subject> { ...@@ -76,12 +76,13 @@ public interface SubjectService extends IService<Subject> {
* @param username 用户名称 * @param username 用户名称
* @param type 分类(1-个人;2-公开;3-个人+公开) * @param type 分类(1-个人;2-公开;3-个人+公开)
* @param subjectName 专题名称 * @param subjectName 专题名称
* @param subjectName 专题类别(1:通用专题;3:研究中心主题专题[复合专题])
* @param pageNo 当前页 * @param pageNo 当前页
* @param pageSize 每页返回条数 * @param pageSize 每页返回条数
* @author lkg * @author lkg
* @date 2025/2/8 * @date 2025/2/8
*/ */
Page<Node> visiblePageList(String username, Integer type, String subjectName, Integer pageNo, Integer pageSize, String environment,HttpServletRequest request,String flagCode); Page<Node> visiblePageList(String username, Integer type, String subjectName, Integer subjectType, Integer pageNo, Integer pageSize, String environment,HttpServletRequest request,String flagCode);
/** /**
* 获取专题详情(包含样例文章信息) * 获取专题详情(包含样例文章信息)
......
...@@ -291,7 +291,7 @@ public class SubjectServiceImpl extends ServiceImpl<SubjectMapper, Subject> impl ...@@ -291,7 +291,7 @@ public class SubjectServiceImpl extends ServiceImpl<SubjectMapper, Subject> impl
} }
@Override @Override
public Page<Node> visiblePageList(String username, Integer type, String subjectName, Integer pageNo, Integer pageSize, String environment,HttpServletRequest request,String flagCode) { public Page<Node> visiblePageList(String username, Integer type, String subjectName,Integer subjectType, Integer pageNo, Integer pageSize, String environment,HttpServletRequest request,String flagCode) {
Page<String> page = new Page<>(pageNo, pageSize); Page<String> page = new Page<>(pageNo, pageSize);
String sql = ""; String sql = "";
if(StringUtils.isNotBlank(flagCode)){ if(StringUtils.isNotBlank(flagCode)){
...@@ -309,7 +309,7 @@ public class SubjectServiceImpl extends ServiceImpl<SubjectMapper, Subject> impl ...@@ -309,7 +309,7 @@ public class SubjectServiceImpl extends ServiceImpl<SubjectMapper, Subject> impl
log.info("visiblePageList sql:{}",sql); log.info("visiblePageList sql:{}",sql);
} }
log.info("visiblePageList username:{},type:{},subjectName:{},environment:{},sql:{}",username,type,subjectName,environment,sql); log.info("visiblePageList username:{},type:{},subjectName:{},environment:{},sql:{}",username,type,subjectName,environment,sql);
return baseMapper.visibleList(username, type, subjectName, page,environment,sql); return baseMapper.visibleList(username, type, subjectName,subjectType, page,environment,sql);
} }
@Override @Override
......
...@@ -45,4 +45,7 @@ public class SubjectCondition { ...@@ -45,4 +45,7 @@ public class SubjectCondition {
private String column; private String column;
/**排序方式*/ /**排序方式*/
private String order; private String order;
/*专题类别(1:通用专题;3:研究中心主题专题[复合专题])*/
private Integer subjectType = 1;
} }
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论