You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
errorx.Render(w, errorx.Parser(errorx.GetMessage("range cannot be more than 12 months", http.StatusUnprocessableEntity)))
62
+
return
63
+
}
64
+
65
+
varformat, levelstring
66
+
67
+
iftoTime.Sub(fromTime).Hours() <=24*30 {
68
+
format="02/01/2006"
69
+
level="day"
70
+
} else {
71
+
format="Jan 2006"
72
+
level="month"
73
+
}
74
+
75
+
tx:=model.DB.Model(&model.User{}).Select("count(id) as count, date_trunc('"+level+"', created_at) as name").Where("created_at BETWEEN ? AND ?", fromTime, toTime).Group("name").Order("name")
0 commit comments