Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNoRecord = errors.New("models: no matching record found")
Functions ¶
This section is empty.
Types ¶
type Contact ¶
type Contact struct { ID int `json:"id"` First string `json:"first"` Last string `json:"last"` Phone string `json:"phone"` Email string `json:"email"` }
Contact represents a contact persisted to storage.
type ContactForm ¶
type ContactForm struct { ID int `form:"-"` First string `form:"first"` Last string `form:"last"` Phone string `form:"phone"` Email string `form:"email"` validator.Validator `form:"-"` }
ContactForm represents a form for creating or updating a contact.
type ContactsIndexVM ¶
ContactsIndexVM represents a view model containing multiple contacts.
type ContactsViewVM ¶
type ContactsViewVM struct {
Contact *Contact
}
ContactsViewVM represents a view model containing a single contact.
Click to show internal directories.
Click to hide internal directories.