routes

package
v0.0.0-...-2e66de2 Latest Latest
Warning

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

Go to latest
Published: Sep 15, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const TimeFormat string = "2006-01-02 15:04:05"

Variables

This section is empty.

Functions

This section is empty.

Types

type Route

type Route struct {
	ID             int    `json:"id,omitempty"`
	ShortKey       string `json:"shortkey"`
	URL            string `json:"url"`
	Creator        string `json:"creator"`
	Team           string `json:"team,omitempty"`
	CreatedAt      string `json:"createdat,omitempty"`
	ModifiedAt     string `json:"modifiedat,omitempty"`
	LastModifiedBy string `json:"lastmodifiedby,omitempty"`
	Locked         int    `json:"locked"` // we will have some entries that will require elevated privs to change
}

#### Data structure: - short_key - key used in url for lookup - url - returned url correlated to the key - creator - creator of the k+v - created_at - date of creation - modified_at - date last modified - last_modified_by - user last modified key

Route is

func NewRoute

func NewRoute(k string, url string, creator string, team string) (Route, error)

NewRoute is a

func (*Route) UnmarshalJSON

func (r *Route) UnmarshalJSON(body []byte) (err error)

Jump to

Keyboard shortcuts

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