Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type I18nEnabled ¶ added in v0.0.28
type I18nEnabled struct {
LocaleFields []*LocaleFieldValue `gorm:"-" json:"-"`
}
type I18nFactory ¶
type I18nFactory struct {
Translator Translator `inject:"translator"`
}
type LocaleFieldValue ¶
type LocaleFieldValue struct { EntityName string `gorm:"column:entity_name;primaryKey" json:"entityName"` EntityId string `gorm:"column:entity_id;primaryKey" json:"entityId"` Name string `gorm:"column:name;primaryKey" json:"name"` Locale string `gorm:"column:locale;default:en;primaryKey" json:"locale"` Value string `gorm:"column:value" json:"value"` }
type Translator ¶
type Translator interface { StoreTranslations(translations []*LocaleFieldValue) LoadTranslations(locale, entityName string, entityId ...string) map[string][]*LocaleFieldValue }
Click to show internal directories.
Click to hide internal directories.