Przeglądaj źródła

priorScene 池最终排序首键由 rov 换为 sceneSumRov,次级 total_rov DESC 保留

rov 仍作为质量过滤(>0),不再参与排序;SQL ORDER BY total_rov DESC, score DESC 不动(去重代表行选取沿用)。
刘立冬 12 godzin temu
rodzic
commit
5e5a13c79e

+ 4 - 4
api-module/src/main/java/com/tzld/piaoquan/api/service/contentplatform/impl/ContentPlatformPlanServiceImpl.java

@@ -960,7 +960,7 @@ public class ContentPlatformPlanServiceImpl implements ContentPlatformPlanServic
      * 后处理:
      *   1. 同 video_id 仅保留 total_rov 最大的代表行(利用 SQL 已按 total_rov DESC, score DESC 排好,首次即最大)
      *   2. 过滤 rov 为 null 或 <=0(视频近 7 日无表现)
-     *   3. 输出顺序按 rov DESC,相同 rov 按 total_rov DESC 兜底
+     *   3. 输出顺序按 sceneSumRov DESC,相同再按 total_rov DESC 兜底
      */
     private List<VideoContentItemVO> fetchPriorSceneCandidates(VideoContentListParam param, ContentPlatformAccount user, int limit) {
         String channelName = resolveChannelName(param);
@@ -996,11 +996,11 @@ public class ContentPlatformPlanServiceImpl implements ContentPlatformPlanServic
             if (r.getRov() == null || r.getRov() <= 0) continue;
             filtered.add(r);
         }
-        // 3. 按 rov DESC 排序,次级 total_rov DESC
+        // 3. 按 sceneSumRov DESC 排序,次级 total_rov DESC
         filtered.sort((a, b) -> {
             int c = Double.compare(
-                    b.getRov() == null ? 0d : b.getRov(),
-                    a.getRov() == null ? 0d : a.getRov());
+                    b.getSceneSumRov() == null ? 0d : b.getSceneSumRov(),
+                    a.getSceneSumRov() == null ? 0d : a.getSceneSumRov());
             if (c != 0) return c;
             return Double.compare(
                     b.getTotalRov() == null ? 0d : b.getTotalRov(),