Explorar o código

fix: 季节性图表详情

hsun %!s(int64=3) %!d(string=hai) anos
pai
achega
0e49aefeb2
Modificáronse 1 ficheiros con 4 adicións e 0 borrados
  1. 4 0
      controller/chart/chart_info.go

+ 4 - 0
controller/chart/chart_info.go

@@ -119,9 +119,13 @@ func GetChartInfoDetail(c *gin.Context)  {
 		var seasonStartDate, seasonEndDate string
 		if reqSeasonStartDate == "" {
 			seasonStartDate = chartInfo.SeasonStartDate
+		} else {
+			seasonStartDate = reqSeasonStartDate
 		}
 		if reqSeasonEndDate == "" {
 			seasonEndDate = chartInfo.SeasonEndDate
+		} else {
+			seasonEndDate = reqSeasonEndDate
 		}
 		if seasonStartDate != "" {
 			startDate = seasonStartDate + "-01-01"