...
|
...
|
@@ -32,14 +32,14 @@ func Statistics(header *protocol.RequestHeader, request *protocol.DividendStatis |
|
|
t := time.Now()
|
|
|
last := time.Date(t.Year(), time.December, 31, 23, 59, 59, 0, time.Local)
|
|
|
first := time.Date(t.Year(), time.January, 1, 0, 0, 0, 0, time.Local)
|
|
|
fmt.Print("First:", first, "\n")
|
|
|
fmt.Print("Last:", last, "\n")
|
|
|
if request.StartTime == 0 {
|
|
|
request.StartTime = first.Unix() * 1000
|
|
|
}
|
|
|
if request.EndTime == 0 {
|
|
|
request.EndTime = last.Unix() * 1000
|
|
|
}
|
|
|
fmt.Print("StartTime: ", request.StartTime, "\n")
|
|
|
fmt.Print("EndTime: ", request.EndTime, "\n")
|
|
|
var orderBetween []*domain.OrderBase
|
|
|
for i := range orderAll {
|
|
|
if orderAll[i].SaleDate.Unix() >= (request.StartTime/1000) && orderAll[i].SaleDate.Unix() < (request.EndTime/1000) {
|
...
|
...
|
|