Documentation ¶
Index ¶
- Variables
- func Capitalize(in *pongo2.Value, param *pongo2.Value) (*pongo2.Value, *pongo2.Error)
- func ConvertKilometersToMiles(in *pongo2.Value, param *pongo2.Value) (*pongo2.Value, *pongo2.Error)
- func CurrencySymbol(in *pongo2.Value, param *pongo2.Value) (*pongo2.Value, *pongo2.Error)
- func EscapeEntities(in *pongo2.Value, param *pongo2.Value) (*pongo2.Value, *pongo2.Error)
- func FormatCurrencyAmount(locale string) pongo2.FilterFunction
- func FormatDecimalAmount(locale string) pongo2.FilterFunction
- func FormatShortCurrencyAmount(locale string) pongo2.FilterFunction
- func InsertSymbol(in *pongo2.Value, param *pongo2.Value) (*pongo2.Value, *pongo2.Error)
- func LocalizedDateFormatter(locale string, timezone string) pongo2.FilterFunction
- func LocalizedFormatCurrency(currency string, locale string) pongo2.FilterFunction
- func LookupMap(in *pongo2.Value, param *pongo2.Value) (*pongo2.Value, *pongo2.Error)
- func MaskAccountNumber(in *pongo2.Value, param *pongo2.Value) (*pongo2.Value, *pongo2.Error)
- func ParseTimeFromString(in string, loc ...*time.Location) time.Time
- func Passthrough(in *pongo2.Value, param *pongo2.Value) (*pongo2.Value, *pongo2.Error)
- func SimpleDateFormatter(timezone string) pongo2.FilterFunction
- func Split(in *pongo2.Value, param *pongo2.Value) (*pongo2.Value, *pongo2.Error)
- func UnmarshalJson(in *pongo2.Value, param *pongo2.Value) (*pongo2.Value, *pongo2.Error)
Constants ¶
This section is empty.
Variables ¶
var TTFormats = []string{"2006-01-02 15:04:05.0 MST", "2006-01-02 15:04:05.0", "2006-01-02"}
TTFormats is a list of time formats as a list of strings used for parsing times supplied as strings
Functions ¶
func Capitalize ¶
Capitalize capitalizes the supplied string
func ConvertKilometersToMiles ¶
ConvertKilometersToMiles converts the supplied value in Km as Miles
func CurrencySymbol ¶
CurrencySymbol returns a filter that retruns a currency symbol for the supplied currency isocode.
func EscapeEntities ¶
EscapeEntities applies HTML escaping tot he supplied input string.
func FormatCurrencyAmount ¶
func FormatCurrencyAmount(locale string) pongo2.FilterFunction
FormatCurrencyAmount returns a filter that formats currency amount for display WITHOUT a currency symbol
func FormatDecimalAmount ¶
func FormatDecimalAmount(locale string) pongo2.FilterFunction
FormatDecimalAmount returns a filter that formats decimal amount for display WITHOUT a currency symbol
func FormatShortCurrencyAmount ¶
func FormatShortCurrencyAmount(locale string) pongo2.FilterFunction
FormatShortCurrencyAmount returns a filter that formats currency amount for display WITHOUT a currency symbol in a bizarrely complex way
func InsertSymbol ¶
InsertSymbol sort of inserts a symbol
func LocalizedDateFormatter ¶
func LocalizedDateFormatter(locale string, timezone string) pongo2.FilterFunction
LocalizedDateFormatter returns a formatter for the context locale and time-zone that attempts to parse the input using a list of formats until a successful parse is achieved.
func LocalizedFormatCurrency ¶
func LocalizedFormatCurrency(currency string, locale string) pongo2.FilterFunction
LocalizedFormatCurrency returns a filter that formats currency for display WITH symbol
func LookupMap ¶
LookupMap returns a value extracted from the map supplied as the value for the key supplied as param.
func MaskAccountNumber ¶
MaskAccountNumber applies various maskings to a number (or string>) supplied as a string, e.g. to card number.
func ParseTimeFromString ¶
ParseTimeFromString parses a date from the supplied value using an optional supplied location
func Passthrough ¶
Passthrough does nothing to the supplied input - just passes it through
func SimpleDateFormatter ¶
func SimpleDateFormatter(timezone string) pongo2.FilterFunction
SimpleDateFormatter given a time-zone deduces an appropriate location and returns a filter that prses a date from a supplied string or timestamp.
Types ¶
This section is empty.