Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // UserMediaMap is a map of attribute names in result type UserMedia indexed by // view name. UserMediaMap = map[string][]string{ "default": []string{ "id", "phone", "lastName", "updatedAt", "email", "createdAt", "firstName", "countryPhoneCode", "changingEmail", "isAdmin", "verifiedEmail", "Authorization", "X-Session", }, } )
Functions ¶
func ValidateUserMedia ¶
ValidateUserMedia runs the validations defined on the viewed result type UserMedia.
func ValidateUserMediaView ¶
func ValidateUserMediaView(result *UserMediaView) (err error)
ValidateUserMediaView runs the validations defined on UserMediaView using the "default" view.
Types ¶
type UserMedia ¶
type UserMedia struct { // Type to project Projected *UserMediaView // View to render View string }
UserMedia is the viewed result type that is projected based on a view.
type UserMediaView ¶
type UserMediaView struct { // Unique unchanging user ID ID *string // Given name for the user FirstName *string // Family name for the user LastName *string // Email attached to the account of the user Email *string // Phone Number Of the user Phone *string // When the user attempts to change their email, this is what they will change // it to after they verify that it belongs to them ChangingEmail *string // Whether the user has verified their email VerifiedEmail *bool // Whether the user is an administrator on the site IsAdmin *bool UpdatedAt *string IsActive *bool CreatedAt *string CountryPhoneCode *string Authorization *string XSession *string }
UserMediaView is a type that runs validations on a projected type.
Click to show internal directories.
Click to hide internal directories.