makeMsgTpl takes a page title, heading, and message and returns a msgTpl that can be rendered as an HTML view. This is used for rendering arbitrary HTML views with error and success messages.
(pageTitle, heading, msg string)
| 42 | // a msgTpl that can be rendered as an HTML view. This is used for |
| 43 | // rendering arbitrary HTML views with error and success messages. |
| 44 | func makeMsgTpl(pageTitle, heading, msg string) msgTpl { |
| 45 | if heading == "" { |
| 46 | heading = pageTitle |
| 47 | } |
| 48 | err := msgTpl{} |
| 49 | err.Title = pageTitle |
| 50 | err.MessageTitle = heading |
| 51 | err.Message = msg |
| 52 | return err |
| 53 | } |
| 54 | |
| 55 | // parseStringIDs takes a slice of numeric string IDs and |
| 56 | // parses each number into an int64 and returns a slice of the |
no outgoing calls
no test coverage detected