snow/aid/time.go
eccentric db9f92bd91 Equip Item; Refactor Loadouts; Move Cache System; ...
Change up attribrutes again.
Fix indent bug.
2023-11-05 01:58:00 +00:00

15 lines
605 B
Go

package aid
import "time"
func TimeStartOfDay() string {
return time.Date(time.Now().Year(), time.Now().Month(), time.Now().Day(), 0, 0, 0, 0, time.Now().Location()).Format("2006-01-02T15:04:05.999Z")
}
func TimeEndOfDay() string {
return time.Date(time.Now().Year(), time.Now().Month(), time.Now().Day(), 23, 59, 59, 999999999, time.Now().Location()).Format("2006-01-02T15:04:05.999Z")
}
func TimeEndOfWeekString() string {
return time.Date(time.Now().Year(), time.Now().Month(), time.Now().Day(), 23, 59, 59, 999999999, time.Now().Location()).AddDate(0, 0, 7).Format("2006-01-02T15:04:05.999Z")
}