time

package
v0.0.0-...-6f92cd8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 7, 2021 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Monday 周一
	Monday int64 = iota + 1
	// Tuesday 周二
	Tuesday
	// Wednesday 周三
	Wednesday
	// Thursday 周四
	Thursday
	// Friday 周五
	Friday
	// Saturday 周六
	Saturday
	// Sunday 周日
	Sunday
)

Variables

This section is empty.

Functions

func CalWeekDayBeforeNow

func CalWeekDayBeforeNow(now time.Time, beforeDay int) []time.Time

ThreeWeekDayBeforeNow 计算今天往前三个工作日的开始和结束时间

func DayInWeek

func DayInWeek(day time.Time) int64

DayInWeek 计算给定的时间在本周是第几天

func LastWeekStartAndEnd

func LastWeekStartAndEnd(now time.Time) (time.Time, time.Time)

LastWeekStartAndEnd 获取上周的起始时间和结束时间

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL