| | |
| | | */ |
| | | List<Map<String, Object>> selectSatisfactionFillPersonCount(SatisfactionStatQuery query); |
| | | |
| | | /** |
| | | * 【按 模板 + 问题】统计答题人数({@code count(distinct ssd.sub_id)})。 |
| | | * <p> |
| | | * <b>为什么单独加这一条</b>:{@code /statistics} 的「答题人数 / 未答题人数」必须与 |
| | | * 「发送人数」({@link #selectSatisfactionSendCount},也是人数)同口径。 |
| | | * 原实现误用 {@link #selectSatisfactionFillStatByMatchedtext} 的 {@code count(*)}(明细<b>行数</b>), |
| | | * 而一条 {@code (sub_id, questiontext)} 可能有多行明细(多选项 / 重复明细), |
| | | * 导致「未答题人数 = 发送人数 − 明细行数」出现负数(实测 -120)。 |
| | | * <p> |
| | | * ⚠️ 平均分 / 最高分 / 最低分 / 各选项占比仍使用明细行数(那些口径本来就按行计),未改动。 |
| | | * <p> |
| | | * 除聚合键与 {@code distinct} 外,from/where 与 {@link #selectSatisfactionFillStatByMatchedtext} |
| | | * 完全一致,保证两者统计的是同一批数据。 |
| | | * |
| | | * @param query 聚合查询条件 |
| | | * @return 每行含 libtemplateid、questiontext、cnt(人数) |
| | | */ |
| | | List<Map<String, Object>> selectSatisfactionFillPersonCountByQuestion(SatisfactionStatQuery query); |
| | | |
| | | // ================================================================ 省立同德:趋势与维度 |
| | | |
| | | /** |