Documentation
¶
Overview ¶
Package models is the schema of the custom-sql-migration example.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Account ¶
type Account struct {
momo.Model `momo:"table:accounts"`
ID int64 `momo:"pk,identity"`
Email string `momo:"size:200,notnull"`
EmailNorm string `momo:"column:email_norm,size:200,notnull,default:'',unique"`
}
Account is a login. EmailNorm is the lower-cased email, used for lookups that ignore case. The unique index on it is added last, after a migration has filled the column in.
Click to show internal directories.
Click to hide internal directories.