| 
					
				 | 
			
			
				@@ -381,44 +381,70 @@ public class CoreServiceImpl implements CoreService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             if (!flag) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 continue; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            ArticleSortRequest articleSortRequest = new ArticleSortRequest(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            articleSortRequest.setAccountId(planAccount.getAccountId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            articleSortRequest.setAccountName(planAccount.getAccountName()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            articleSortRequest.setGhId(planAccount.getGhId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            //测试参数 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            List<PublishArticleData> rankList; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            if (StringUtils.isNotEmpty(planAccount.getSortStrategy())) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                ArticleSortRequest articleSortRequest = new ArticleSortRequest(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                articleSortRequest.setAccountId(planAccount.getAccountId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                articleSortRequest.setAccountName(planAccount.getAccountName()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                articleSortRequest.setGhId(planAccount.getGhId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                //测试参数 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 //            articleSortRequest.setStrategy("ArticleRankRandom"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 //            articleSortRequest.setExcludeLog(true); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            articleSortRequest.setStrategy(planAccount.getSortStrategy()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            articleSortRequest.setPublishNum(planAccount.getPublishPreNum()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            if (Objects.equals(PublishGzhPushTypeEnum.auto_group_publish.getVal(), planAccount.getPushType())) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                articleSortRequest.setPublishNum(planAccount.getPublishNum()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            articleSortRequest.setPlanId(planAccount.getPlanId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            articleSortRequest.setPushType(planAccount.getPushType()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                articleSortRequest.setStrategy(planAccount.getSortStrategy()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                articleSortRequest.setPublishNum(planAccount.getPublishPreNum()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                if (Objects.equals(PublishGzhPushTypeEnum.auto_group_publish.getVal(), planAccount.getPushType())) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    articleSortRequest.setPublishNum(planAccount.getPublishNum()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                articleSortRequest.setPlanId(planAccount.getPlanId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                articleSortRequest.setPushType(planAccount.getPushType()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            ArticleSortResponse articleSortResponse = sortService.publishArticleSort(articleSortRequest); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            if (articleSortResponse == null || articleSortResponse.getData() == null) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                continue; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            if (CollectionUtils.isEmpty(articleSortResponse.getData().getRank_list())) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                continue; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            ArticleSortResponseData data = articleSortResponse.getData(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            if (!CollectionUtils.isEmpty(data.getFilter_list())) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                List<FilterSortContentParam> list = new ArrayList<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                for (PublishArticleData publishArticleData : data.getFilter_list()) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    FilterSortContentParam param = new FilterSortContentParam(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    param.setFilterReason(publishArticleData.getFilterReason()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    param.setPublishContentId(publishArticleData.getId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    list.add(param); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                ArticleSortResponse articleSortResponse = sortService.publishArticleSort(articleSortRequest); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                if (articleSortResponse == null || articleSortResponse.getData() == null) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    continue; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                if (CollectionUtils.isEmpty(articleSortResponse.getData().getRank_list())) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    continue; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                ArticleSortResponseData data = articleSortResponse.getData(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                if (!CollectionUtils.isEmpty(data.getFilter_list())) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    List<FilterSortContentParam> list = new ArrayList<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    for (PublishArticleData publishArticleData : data.getFilter_list()) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        FilterSortContentParam param = new FilterSortContentParam(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        param.setFilterReason(publishArticleData.getFilterReason()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        param.setPublishContentId(publishArticleData.getId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        list.add(param); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    FilterSortParam param = new FilterSortParam(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    param.setFilterSortContentList(list); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    aigcService.filterSortContents(param); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                //排序结束 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                rankList = data.getRank_list(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                LongArticleSystemGetContentsParam param = new LongArticleSystemGetContentsParam(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                param.setPlanId(planAccount.getPlanId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                param.setAccountId(planAccount.getAccountId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                param.setPageNum(1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                param.setPageSize(planAccount.getPublishPreNum()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                LongArticleSystemContentVO longArticleSystemContentVO = aigcService.listWaitingSortContents(param); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                if (longArticleSystemContentVO == null 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        || longArticleSystemContentVO.getTotalCount() < planAccount.getPublishPreMinNum() 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        || CollectionUtils.isEmpty(longArticleSystemContentVO.getContentItemList()) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        || longArticleSystemContentVO.getContentItemList().size() < planAccount.getPublishPreMinNum()) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    continue; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                List<PublishArticleData> notSortList = new ArrayList<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                for (ContentItemVO contentItemVO : longArticleSystemContentVO.getContentItemList()) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    PublishArticleData publishArticleData = new PublishArticleData(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    publishArticleData.setId(contentItemVO.getPublishContentId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    publishArticleData.setSourceId(contentItemVO.getSourceId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    publishArticleData.setTitle(contentItemVO.getTitle()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    publishArticleData.setContentPoolType(contentItemVO.getFlowPoolLevelTag()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    notSortList.add(publishArticleData); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                FilterSortParam param = new FilterSortParam(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                param.setFilterSortContentList(list); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                aigcService.filterSortContents(param); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                rankList = notSortList; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             List<LongArticleSystemPushContentParam> pushContentList = new ArrayList<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            //排序结束 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            List<PublishArticleData> rankList = data.getRank_list(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             List<Long> sendIds = new ArrayList<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             for (PublishArticleData publishArticleData : rankList) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 LongArticleSystemPushContentParam contentParam = new LongArticleSystemPushContentParam(); 
			 |