fix the dates in Statistics & Analysis page does not be processed for daylight saving time

This commit is contained in:
MaysWind
2025-12-21 02:35:11 +08:00
parent a09d7b57f9
commit d95e34a597
14 changed files with 171 additions and 94 deletions
+2 -4
View File
@@ -302,13 +302,11 @@ func (a *DataManagementsApi) getExportedFileContent(c *core.WebContext, fileType
return nil, "", errs.NewIncompleteOrIncorrectSubmissionError(err)
}
timezone := time.Local
utcOffset, err := c.GetClientTimezoneOffset()
timezone, _, err := c.GetClientTimezone()
if err != nil {
log.Warnf(c, "[data_managements.getExportedFileContent] cannot get client timezone offset, because %s", err.Error())
} else {
timezone = time.FixedZone("Client Timezone", int(utcOffset)*60)
timezone = time.Local
}
uid := c.GetCurrentUid()