Roc 2 жил өмнө
parent
commit
fcb7ccd077

+ 2 - 2
services/chart/chart_info.go

@@ -719,7 +719,7 @@ func BarChartData(mappingList []*chartEdbMappingModel.ChartEdbInfoMapping, edbDa
 						err = tmpErr
 						return
 					}
-					if utils.GetTimeSubDay(currDateTime, findDateTime) >= 5 {
+					if currDateTime.Equal(findDateTime) || currDateTime.Before(findDateTime) {
 						findDate = dataList[i].DataTime
 						break
 					}
@@ -812,7 +812,7 @@ func BarChartData(mappingList []*chartEdbMappingModel.ChartEdbInfoMapping, edbDa
 						err = tmpErr
 						return
 					}
-					if utils.GetTimeSubDay(currDateTime, findDateTime) >= 5 {
+					if currDateTime.Equal(findDateTime) || currDateTime.Before(findDateTime) {
 						findDate = dataList[i].DataTime
 						break
 					}