Kaynağa Gözat

完善视图聚合。

zhangjinjun 6 yıl önce
ebeveyn
işleme
0a68dc3514

+ 1 - 3
src/main/java/com/yihu/quota/service/view/ViewService.java

@ -428,8 +428,6 @@ public class ViewService extends BaseJpaService<View, ViewDao> {
                    aggNamePre = ViewConstant.TOTAL_DIMENSION_CODE + "-";
                }
                // TODO 数值类型场合,又是多维度数据集时,需要指定数据集
                if ("sum".equals(quota.getBasicFormulaType())) {
                    // 求和
                    String aggName = aggNamePre + "sum-result";
@ -483,7 +481,7 @@ public class ViewService extends BaseJpaService<View, ViewDao> {
            BoolQueryBuilder quotaBoolQueryBuilder = QueryBuilders.boolQuery();
            this.joinFilters(quotaBoolQueryBuilder, quotaFilterModelList);
            String aggName = quota.getDimensionCode() + "-filter";
            String aggName = quota.getCode() + "-filter";
            filterAgg = AggregationBuilders.filter(aggName).filter(quotaBoolQueryBuilder);
            filterAgg.subAggregation(metricAgg);
        }