Documentation ¶
Index ¶
- Variables
- func Add(n, m int) int
- func Css(css string) template.CSS
- func GBK2UTF(text string) string
- func GetDate(timestamp uint32) string
- func GetDateFormat(timestamp uint32, format string) string
- func GetDateMH(timestamp uint32) string
- func GetDateParse(dates string) int64
- func GetTimeParse(times string) int64
- func InArray(in interface{}, list interface{}) bool
- func IntToString(in interface{}) string
- func NewPass(passwd, salt string) (string, error)
- func NumFormat(num uint32) string
- func ParseBool(val interface{}) (value bool, err error)
- func RegisterFuncMap()
- func SubstrNoHtml(s string, start, length int) string
- func ToInt64(value interface{}) (d int64, err error)
- func ToStr(value interface{}, args ...int) (s string)
- func Type(v interface{}) string
- type Paginator
- func (p *Paginator) HasNext() bool
- func (p *Paginator) HasPages() bool
- func (p *Paginator) HasPrev() bool
- func (p *Paginator) IsActive(page int) bool
- func (p *Paginator) Nums() int64
- func (p *Paginator) Offset() int
- func (p *Paginator) Page() int
- func (p *Paginator) PageLink(page int) string
- func (p *Paginator) PageLinkFirst() (link string)
- func (p *Paginator) PageLinkLast() (link string)
- func (p *Paginator) PageLinkNext() (link string)
- func (p *Paginator) PageLinkPrev() (link string)
- func (p *Paginator) PageNos() []int
- func (p *Paginator) PageNums() int
- func (p *Paginator) Pages() []int
- func (p *Paginator) SetNums(nums interface{})
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrHttpNotFound = errors.New("请求未发现") ErrHttpError = errors.New("请求错误") )
Functions ¶
func GetDateFormat ¶
func GetDateParse ¶
func GetTimeParse ¶
func ParseBool ¶
ParseBool returns the boolean value represented by the string.
It accepts 1, 1.0, t, T, TRUE, true, True, YES, yes, Yes,Y, y, ON, on, On, 0, 0.0, f, F, FALSE, false, False, NO, no, No, N,n, OFF, off, Off. Any other value returns an error.
func RegisterFuncMap ¶
func RegisterFuncMap()
Types ¶
type Paginator ¶
type Paginator struct { Request *http.Request PerPageNums int MaxPages int // contains filtered or unexported fields }
func (*Paginator) PageLinkFirst ¶
func (*Paginator) PageLinkLast ¶
func (*Paginator) PageLinkNext ¶
func (*Paginator) PageLinkPrev ¶
Click to show internal directories.
Click to hide internal directories.