parent
aae4112b32
commit
e25da0cbd4
@ -0,0 +1,16 @@
|
||||
package gotime
|
||||
|
||||
const (
|
||||
DateTimeFormat = "2006-01-02 15:04:05"
|
||||
DateTimeShrinkFormat = "2006-01-02 15:04"
|
||||
DateFormat = "2006-01-02"
|
||||
TimeFormat = "15:04:05"
|
||||
)
|
||||
|
||||
const (
|
||||
DateTimeZhFormat = "2006年01月02日 15点04分05秒"
|
||||
DateTimeZhShrinkFormat = "2006年01月02日 15点04分"
|
||||
DateZhFormat = "2006年01月02日"
|
||||
TimeZhFormat = "15点04分05秒"
|
||||
TimeZhShrinkFormat = "15点04分"
|
||||
)
|
@ -0,0 +1,11 @@
|
||||
package gotime
|
||||
|
||||
import "testing"
|
||||
|
||||
func TestZhFormat(t *testing.T) {
|
||||
t.Log("DateTimeZhFormat", Current().SetFormat(DateTimeZhFormat))
|
||||
t.Log("DateTimeZhShrinkFormat", Current().SetFormat(DateTimeZhShrinkFormat))
|
||||
t.Log("DateZhFormat", Current().SetFormat(DateZhFormat))
|
||||
t.Log("TimeZhFormat", Current().SetFormat(TimeZhFormat))
|
||||
t.Log("TimeZhShrinkFormat", Current().SetFormat(TimeZhShrinkFormat))
|
||||
}
|
@ -1,3 +1,3 @@
|
||||
package gotime
|
||||
|
||||
const Version = "1.0.7"
|
||||
const Version = "1.0.8"
|
||||
|
Loading…
Reference in new issue