Example #1
0
func (u User) AfterCreate(sess bond.Session) error {
	message := fmt.Sprintf("User %q was created.", u.Username)
	return sess.Save(&Log{Message: message})
}
Example #2
0
func (a Account) AfterCreate(sess bond.Session) error {
	message := fmt.Sprintf("Account %q was created.", a.Name)
	return sess.Save(&Log{Message: message})
}