Documentation ¶
Index ¶
- Variables
- func HTMLTmpl() *template.Template
- func InitialHTMLTmpl()
- func InitialMarkdownTmpl()
- func Mail(toEmail string, toUsername string, title string, content []byte, ...) error
- func MailTpl() *template.Template
- func MailWithID(id uint64, toEmail string, toUsername string, title string, content []byte, ...) error
- func MailWithIDAndNoticer(id uint64, noticer notice.Noticer, toEmail string, toUsername string, ...) error
- func MailWithNoticer(noticer notice.Noticer, toEmail string, toUsername string, title string, ...) error
- func MarkdownTmpl() *template.Template
- type Content
- type ContentType
- type EmailConfig
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // DefaultSMTPConfig 默认STMP配置 DefaultSMTPConfig = &mail.SMTPConfig{} // DefaultEmailConfig 默认Email配置 DefaultEmailConfig = &EmailConfig{} // ErrIncorrectRecipient 收信地址不正确 ErrIncorrectRecipient = errors.New(`The recipient's email address is incorrect`) )
Functions ¶
func InitialHTMLTmpl ¶
func InitialHTMLTmpl()
func InitialMarkdownTmpl ¶
func InitialMarkdownTmpl()
func Mail ¶
Mail 发送Email @param toEmail 收信邮箱 @param toUsername 收信人名称 @param title 邮件标题 @param content 邮件内容 @param ccList 抄送地址
func MailWithID ¶
func MailWithID(id uint64, toEmail string, toUsername string, title string, content []byte, ccList ...string) error
MailWithID 发送Email(带ID参数)
func MailWithIDAndNoticer ¶
func MailWithIDAndNoticer(id uint64, noticer notice.Noticer, toEmail string, toUsername string, title string, content []byte, ccList ...string) error
MailWithIDAndNoticer 发送Email(带ID和Noticer参数)
func MailWithNoticer ¶
func MailWithNoticer(noticer notice.Noticer, toEmail string, toUsername string, title string, content []byte, ccList ...string) error
MailWithNoticer 发送Email(带Noticer参数)
func MarkdownTmpl ¶
Types ¶
type Content ¶
type Content struct {
// contains filtered or unexported fields
}
func NewContent ¶
func NewContent() *Content
type ContentType ¶
Click to show internal directories.
Click to hide internal directories.