You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
323 B
18 lines
323 B
package models |
|
|
|
import ( |
|
"github.com/liangdas/mqant/log" |
|
"server/common" |
|
"server/db" |
|
) |
|
|
|
func GetDailyData(s, e *int64, channel *int, field string) int64 { |
|
q := NewQ(s, e, nil, channel) |
|
|
|
res, err := db.ES().SumBy(common.ESIndexBackDailyData, field, q) |
|
if err != nil { |
|
log.Error(err.Error()) |
|
} |
|
|
|
return int64(res) |
|
}
|
|
|