datetime

package
v0.0.0-...-5de5bcf Latest Latest
Warning

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

Go to latest
Published: Mar 17, 2021 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DateTimeRoutes = utils.Routes{
	utils.Route{
		Name:        "GetDateTimeInfo",
		Method:      "GET",
		Pattern:     "/rest/datetime/info",
		HandlerFunc: getDateTimeInfo,
	}, utils.Route{
		Name:        "SetNTP",
		Method:      "PUT",
		Pattern:     "/rest/datetime/ntp",
		HandlerFunc: setNTP,
	}, utils.Route{
		Name:        "SetTimeZone",
		Method:      "PUT",
		Pattern:     "/rest/datetime/timezone",
		HandlerFunc: setTimeZone,
	}, utils.Route{
		Name:        "GetDateInfo",
		Method:      "GET",
		Pattern:     "/rest/datetime/datetime",
		HandlerFunc: getDateInfo,
	}, utils.Route{
		Name:        "SetDateInfo",
		Method:      "PUT",
		Pattern:     "/rest/datetime/datetime",
		HandlerFunc: setDateTime,
	},
	utils.Route{
		Name:        "SetNTPServer",
		Method:      "PUT",
		Pattern:     "/rest/datetime/ntpserver",
		HandlerFunc: setNTPServer,
	},
	utils.Route{
		Name:        "DeleteNTPServer",
		Method:      "DELETE",
		Pattern:     "/rest/datetime/ntpserver",
		HandlerFunc: deleteNTPServer,
	},
}

DateTimeRoutes all routes concerning date and time

Functions

This section is empty.

Types

type DateTimeConfig

type DateTimeConfig struct {
	// Link ID
	NTP bool `json:"ntp"`
	// Link Name
	NTPServer string `json:"ntpserver,omitempty"`
	// Link Type
	TimeZone string   `json:"timezone,omitempty"`
	Zones    []string `json:"zones"`
	Time     string   `json:"time"`
	Date     string   `json:"date"`
	LastSync string   `json:"lastsync"`
}

Jump to

Keyboard shortcuts

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