Documentation
¶
Index ¶
- func InitMailRender(dir string, funcMap []template.FuncMap)
- func LoginAuth(username, password string) smtp.Auth
- func NewContext()
- func SendActivateAccountMail(c *macaron.Context, u User)
- func SendActivateEmailMail(c *macaron.Context, u User, email string)
- func SendAsync(msg *Message)
- func SendResetPasswordMail(c *macaron.Context, u User)
- func SendTestMail(email string) error
- func SendUserMail(c *macaron.Context, u User, tpl, code, subject, info string)
- type MailRender
- type Message
- type Sender
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitMailRender ¶
InitMailRender templating system
func SendActivateAccountMail ¶
func SendActivateAccountMail(c *macaron.Context, u User)
SendActivateAccountMail when activating account
func SendActivateEmailMail ¶
SendActivateEmailMail sends confirmation email.
func SendResetPasswordMail ¶
func SendResetPasswordMail(c *macaron.Context, u User)
SendResetPasswordMail when resetting password
func SendUserMail ¶
SendUserMail to the User
Types ¶
type MailRender ¶
type MailRender interface {
HTMLString(string, interface{}, ...macaron.HTMLOptions) (string, error)
}
MailRender the template
type Message ¶
type Message struct { Info string // Message information for log purpose. *gomail.Message }
Message content
func NewMessage ¶
NewMessage creates new mail message object with default From header.
func NewMessageFrom ¶
NewMessageFrom creates new mail message object with custom From header.
Click to show internal directories.
Click to hide internal directories.