Documentation ¶
Index ¶
- Constants
- func DBNow() string
- func Format(t time.Time) string
- func GetTodayZeroTime() time.Time
- func GetTomorrowYMD(sep string) string
- func GetYM(time time.Time, sep string) string
- func GetYMD(time time.Time, sep string) string
- func GetYesterdayYMD(sep string) string
- func GetYesterdayZeroTime() time.Time
- func PgNow() string
- func SetUnixSysTime(t time.Time)
- func StrToIntMonth(month string) int
- func SyncHwTime()
- func TimeCost(start time.Time)
- type DateFilter
- type Duration
- type Time
Constants ¶
View Source
const ( SecondsOfDay = 24 * 60 * 60 SecondsOfMinute = 60 TimeDay = SecondsOfDay * time.Second )
View Source
const ( FormatTime = "2006-01-02 15:04:05.999999" DisplayFormatTime = "2006-01-02 15:04:05" )
View Source
const TimeFormat = "2006/01/02 - 15:04:05"
Variables ¶
This section is empty.
Functions ¶
func GetYesterdayYMD ¶
GetYesterdayYMD 得到以sep为分隔符的年、月、日字符串(昨天)
func SyncHwTime ¶
func SyncHwTime()
Types ¶
type DateFilter ¶
type Duration ¶
Duration be used toml unmarshal string time, like 1s, 500ms.
func (Duration) Shrink ¶
Shrink will decrease the duration by comparing with context's timeout duration and return new timeout\context\CancelFunc.
func (*Duration) UnmarshalText ¶
UnmarshalText unmarshal text to duration.
Click to show internal directories.
Click to hide internal directories.