zhangjinli 3 years ago
parent 786ea2f231
commit 104d84c9bb

@ -52,10 +52,10 @@ public class StatisticsController {
static class SSParam {
@Schema(title = "时间条件", description = "1今日;2本周;3本月;4全年")
private Integer dateCondition;
@Schema(title = "开始时间(yyyy-MM-dd HH:mm:ss)", description = "如果传入month以月份区间为条件")
@Schema(title = "开始时间(yyyy-MM-dd HH:mm:ss)", description = "如果传入dateCondition以月份区间为条件")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private LocalDateTime beginTime;
@Schema(title = "结束时间(yyyy-MM-dd HH:mm:ss)", description = "如果传入month以月份区间为条件")
@Schema(title = "结束时间(yyyy-MM-dd HH:mm:ss)", description = "如果传入dateCondition以月份区间为条件")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private LocalDateTime endTime;
}
@ -84,7 +84,7 @@ public class StatisticsController {
break;
default:
}
qw.between("t1.creatAt", before, LocalDateTime.now());
qw.between("creatAt", before, LocalDateTime.now());
} else {
qw.ge(param.getBeginTime() != null, "date_format(creatAt, '%Y-%m-%d')", param.getBeginTime());
qw.le(param.getEndTime() != null, "date_format(creatAt, '%Y-%m-%d')", param.getEndTime());

@ -41,7 +41,13 @@ public interface AdminMapper extends BaseMapper<Admin> {
",sum(IFNULL(reSendNum,0)) as reSendNumSum " +
",sum(IFNULL(recommendNum,0)) as recommendNumSum " +
"from video \n" +
"${ew.customSqlSegment} " +
"where dat" +
"<if test='ew != null'>" +
"<if test='ew.nonEmptyOfWhere'>" +
"AND " +
"</if> " +
"${ew.SqlSegment}" +
"</if> " +
"GROUP BY dat ORDER BY dat ")
List<JSONObject> statistics2(@Param("ew") Wrapper<Video> queryWrapper);
}

Loading…
Cancel
Save