Documentation ¶
Index ¶
- Variables
- type Bag
- type BulkyItem
- type ChainAddUserRequest
- type ChainApproveUserRequest
- type ChainChangeUserWardenRequest
- type ChainCreateRequest
- type ChainRemoveUserRequest
- type ChainResponse
- type ChainUpdateRequest
- type ContactMailRequest
- type ContactNewsletterRequest
- type Event
- type EventCreateRequest
- type EventPriceType
- func (x EventPriceType) IsValid() bool
- func (x EventPriceType) MarshalText() ([]byte, error)
- func (x *EventPriceType) Scan(value interface{}) (err error)
- func (x EventPriceType) String() string
- func (x *EventPriceType) UnmarshalText(text []byte) error
- func (x EventPriceType) Value() (driver.Value, error)
- type EventUpdateRequest
- type ImageUploadResponse
- type Info
- type InfoTopLoop
- type LoginEmailRequest
- type LoginSuperAsGenerateLinkRequest
- type NullEventPriceType
- type PaymentsInitiateRequest
- type PaymentsInitiateResponse
- type RegisterBasicUserRequest
- type RegisterChainAdminRequest
- type RouteCoordinatesGetResponseItem
- type RouteOrderSet
- type User
- type UserChain
- type UserCreateRequest
- type UserOnesignal
- type UserToken
- type UserTransferChainRequest
- type UserUpdateRequest
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidEventPriceType = errors.New("not a valid EventPriceType")
Functions ¶
This section is empty.
Types ¶
type Bag ¶
type Bag struct { ID uint `json:"id"` Number string `json:"number"` Color string `json:"color"` UserChainID uint `json:"-"` ChainUID string `json:"chain_uid" gorm:"-:migration;<-:false"` UserUID string `json:"user_uid" gorm:"-:migration;<-:false"` UpdatedAt time.Time `json:"updated_at" gorm:"autoUpdateTime:false"` LastNotifiedAt *time.Time `json:"-"` LastUserEmailToUpdate string `json:"-"` LastUserDateToUpdate string `json:"-"` }
type BulkyItem ¶
type BulkyItem struct { ID uint `json:"id"` Title string `json:"title"` Message string `json:"message"` ImageUrl string `json:"image_url"` UserChainID uint `json:"-"` ChainUID string `json:"chain_uid" gorm:"-:migration;<-:false"` UserUID string `json:"user_uid" gorm:"-:migration;<-:false"` CreatedAt time.Time `json:"created_at"` }
type ChainAddUserRequest ¶
type ChainApproveUserRequest ¶
type ChainCreateRequest ¶
type ChainCreateRequest struct { Name string `json:"name" binding:"required"` Description string `json:"description"` Address string `json:"address" binding:"required"` CountryCode string `json:"country_code" binding:"required"` Latitude float64 `json:"latitude" binding:"required"` Longitude float64 `json:"longitude" binding:"required"` Radius float32 `json:"radius" binding:"required,gte=1.0,lte=100.0"` OpenToNewMembers bool `json:"open_to_new_members" binding:"required"` Sizes []string `json:"sizes" binding:"required"` Genders []string `json:"genders" binding:"required"` AllowTOH bool `json:"allow_toh" binding:"required"` }
type ChainRemoveUserRequest ¶
type ChainResponse ¶
type ChainResponse struct { UID string `json:"uid" gorm:"chains.uid"` Name string `json:"name" gorm:"chains.name"` Description string `json:"description" gorm:"chains.description"` Address string `json:"address" gorm:"chains.address"` Image *string `json:"image" gorm:"chains.image"` Latitude float64 `json:"latitude" gorm:"chains.latitude"` Longitude float64 `json:"longitude" gorm:"chains.longitude"` Radius float32 `json:"radius" gorm:"chains.radius"` Sizes []string `json:"sizes" gorm:"chains.sizes;serializer:json"` Genders []string `json:"genders" gorm:"chains.genders;serializer:json"` Published bool `json:"published" gorm:"chains.published"` OpenToNewMembers bool `json:"open_to_new_members" gorm:"chains.open_to_new_members"` TotalMembers *int `json:"total_members,omitempty" gorm:"total_members"` TotalHosts *int `json:"total_hosts,omitempty" gorm:"total_hosts"` RulesOverride *string `json:"rules_override,omitempty" gorm:"chains.rules_override"` HeadersOverride *string `json:"headers_override,omitempty" gorm:"chains.headers_override"` Theme *string `json:"theme,omitempty" gorm:"chains.theme"` IsAppDisabled *bool `json:"is_app_disabled,omitempty" gorm:"chains.is_app_disabled"` RoutePrivacy *int `json:"route_privacy,omitempty" gorm:"chains.route_privacy"` AllowMap *bool `json:"allow_map,omitempty" gorm:"chains.allow_map"` }
type ChainUpdateRequest ¶
type ChainUpdateRequest struct { UID string `json:"uid" binding:"required"` Name *string `json:"name,omitempty"` Description *string `json:"description,omitempty"` Address *string `json:"address,omitempty"` Image *string `json:"image,omitempty"` CountryCode *string `json:"country_code,omitempty"` Latitude *float32 `json:"latitude,omitempty"` Longitude *float32 `json:"longitude,omitempty"` Radius *float32 `json:"radius,omitempty" binding:"omitempty,gte=1.0,lte=100.0"` Sizes *[]string `json:"sizes,omitempty"` Genders *[]string `json:"genders,omitempty"` RulesOverride *string `json:"rules_override,omitempty"` HeadersOverride *string `json:"headers_override,omitempty"` Published *bool `json:"published,omitempty"` OpenToNewMembers *bool `json:"open_to_new_members,omitempty"` Theme *string `json:"theme,omitempty"` RoutePrivacy *int `json:"route_privacy"` AllowMap *bool `json:"allow_map,omitempty"` IsAppDisabled *bool `json:"is_app_disabled,omitempty"` }
type ContactMailRequest ¶
type Event ¶
type Event struct { ID uint `json:"-"` UID string `gorm:"uniqueIndex" json:"uid"` Name string `json:"name"` Description string `json:"description"` Latitude float64 `json:"latitude"` Longitude float64 `json:"longitude"` Address string `json:"address"` PriceValue float64 `json:"price_value"` PriceCurrency *string `json:"price_currency"` PriceType *EventPriceType `json:"price_type"` Link string `json:"link"` Date time.Time `json:"date"` DateEnd *time.Time `json:"date_end"` Genders []string `gorm:"serializer:json" json:"genders"` ChainID *uint `json:"-"` ChainUID *string `json:"chain_uid" gorm:"-:migration;<-:false"` UserID uint `json:"-"` CreatedAt time.Time `json:"-"` UpdatedAt time.Time `json:"-"` UserUID *string `json:"user_uid" gorm:"-:migration;<-:false"` UserName *string `json:"user_name" gorm:"-:migration;<-:false"` UserEmail *string `json:"user_email" gorm:"-:migration;<-:false"` ImageUrl string `json:"image_url"` ImageDeleteUrl string `json:"-"` ChainName *string `json:"chain_name" gorm:"-:migration;<-:false"` }
type EventCreateRequest ¶
type EventCreateRequest struct { Name string `json:"name" binding:"required"` Description string `json:"description"` Latitude float64 `json:"latitude" binding:"required,latitude"` Longitude float64 `json:"longitude" binding:"required,longitude"` Address string `json:"address" binding:"required"` PriceValue float64 `json:"price_value"` PriceCurrency string `json:"price_currency"` PriceType EventPriceType `json:"price_type" binding:"required"` Link string `json:"link"` Date time.Time `json:"date" binding:"required"` DateEnd *time.Time `json:"date_end" binding:"omitempty"` Genders []string `json:"genders" binding:"required"` ChainUID string `json:"chain_uid,omitempty" binding:"omitempty"` ImageUrl string `json:"image_url" binding:"required,url"` ImageDeleteUrl string `json:"image_delete_url" binding:"omitempty,url"` }
type EventPriceType ¶
type EventPriceType string
ENUM(free, entrance, donation, perswap)
const ( // EventPriceTypeFree is a EventPriceType of type free. EventPriceTypeFree EventPriceType = "free" // EventPriceTypeEntrance is a EventPriceType of type entrance. EventPriceTypeEntrance EventPriceType = "entrance" // EventPriceTypeDonation is a EventPriceType of type donation. EventPriceTypeDonation EventPriceType = "donation" // EventPriceTypePerswap is a EventPriceType of type perswap. EventPriceTypePerswap EventPriceType = "perswap" )
func ParseEventPriceType ¶
func ParseEventPriceType(name string) (EventPriceType, error)
ParseEventPriceType attempts to convert a string to a EventPriceType.
func (EventPriceType) IsValid ¶
func (x EventPriceType) IsValid() bool
IsValid provides a quick way to determine if the typed value is part of the allowed enumerated values
func (EventPriceType) MarshalText ¶
func (x EventPriceType) MarshalText() ([]byte, error)
MarshalText implements the text marshaller method.
func (*EventPriceType) Scan ¶
func (x *EventPriceType) Scan(value interface{}) (err error)
Scan implements the Scanner interface.
func (EventPriceType) String ¶
func (x EventPriceType) String() string
String implements the Stringer interface.
func (*EventPriceType) UnmarshalText ¶
func (x *EventPriceType) UnmarshalText(text []byte) error
UnmarshalText implements the text unmarshaller method.
type EventUpdateRequest ¶
type EventUpdateRequest struct { UID string `json:"uid" binding:"required,uuid"` Name *string `json:"name,omitempty"` Description *string `json:"description,omitempty"` Address *string `json:"address,omitempty"` Link *string `json:"link,omitempty"` PriceValue *float64 `json:"price_value,omitempty"` PriceCurrency *string `json:"price_currency,omitempty"` PriceType *EventPriceType `json:"price_type,omitempty"` Latitude *float64 `json:"latitude,omitempty" binding:"omitempty,latitude"` Longitude *float64 `json:"longitude,omitempty" binding:"omitempty,longitude"` Date *time.Time `json:"date,omitempty"` DateEnd *time.Time `json:"date_end,omitempty"` Genders *[]string `json:"genders,omitempty"` ImageUrl *string `json:"image_url,omitempty"` ImageDeleteUrl *string `json:"image_delete_url,omitempty"` ChainUID *string `json:"chain_uid,omitempty"` }
type ImageUploadResponse ¶
type InfoTopLoop ¶
type LoginEmailRequest ¶
type NullEventPriceType ¶
type NullEventPriceType struct { EventPriceType EventPriceType Valid bool Set bool }
func NewNullEventPriceType ¶
func NewNullEventPriceType(val interface{}) (x NullEventPriceType)
func (NullEventPriceType) MarshalJSON ¶
func (n NullEventPriceType) MarshalJSON() ([]byte, error)
MarshalJSON correctly serializes a NullEventPriceType to JSON.
func (*NullEventPriceType) Scan ¶
func (x *NullEventPriceType) Scan(value interface{}) (err error)
Scan implements the Scanner interface.
func (*NullEventPriceType) UnmarshalJSON ¶
func (n *NullEventPriceType) UnmarshalJSON(b []byte) error
UnmarshalJSON correctly deserializes a NullEventPriceType from JSON.
type PaymentsInitiateRequest ¶
type PaymentsInitiateResponse ¶
type PaymentsInitiateResponse struct {
SessionID string `json:"session_id"`
}
type RegisterBasicUserRequest ¶
type RegisterBasicUserRequest struct { ChainUID string `json:"chain_uid" binding:"omitempty,uuid"` User UserCreateRequest `json:"user" binding:"required"` }
type RegisterChainAdminRequest ¶
type RegisterChainAdminRequest struct { Chain ChainCreateRequest `json:"chain" binding:"required"` User UserCreateRequest `json:"user" binding:"required"` }
type RouteOrderSet ¶
type User ¶
type User struct { ID uint `json:"-"` UID string `json:"uid" gorm:"uniqueIndex"` FID *string `json:"-" gorm:"column:fid"` Email *string `json:"email" gorm:"unique"` IsEmailVerified bool `json:"is_email_verified"` IsRootAdmin bool `json:"is_root_admin"` PausedUntil *time.Time `json:"paused_until"` Name string `json:"name"` PhoneNumber string `json:"phone_number"` Address string `json:"address"` Sizes []string `json:"sizes" gorm:"serializer:json"` LastSignedInAt *time.Time `json:"-"` LastPokeAt *time.Time `json:"-"` UserToken []UserToken `json:"-"` Event []Event `json:"-"` Chains []UserChain `json:"chains"` UserOnesignal []UserOnesignal `json:"-"` CreatedAt time.Time `json:"-"` UpdatedAt time.Time `json:"-"` I18n string `json:"i18n"` JwtTokenPepper int `json:"-" ` Latitude float64 `json:"-"` Longitude float64 `json:"-"` AcceptedTOH bool `json:"-"` AcceptedDPA bool `json:"-"` AcceptedTOHJSON *bool `json:"accepted_toh,omitempty" gorm:"-:migration;<-:false"` AcceptedDPAJSON *bool `json:"accepted_dpa,omitempty" gorm:"-:migration;<-:false"` NotificationChainUIDs []string `json:"notification_chain_uids,omitempty" gorm:"-"` }
type UserChain ¶
type UserChain struct { ID uint `json:"-"` UserID uint `json:"-" gorm:"index"` UserUID string `json:"user_uid" gorm:"-:migration;<-:false"` ChainID uint `json:"-"` ChainUID string `json:"chain_uid" gorm:"-:migration;<-:false"` IsChainAdmin bool `json:"is_chain_admin"` IsChainWarden bool `json:"is_chain_warden"` CreatedAt time.Time `json:"created_at"` IsApproved bool `json:"is_approved"` LastNotifiedIsUnapprovedAt *time.Time `json:"-"` RouteOrder int `json:"-"` IsPaused bool `json:"is_paused"` Note *string `json:"-" gorm:"->:false;<-:create"` Bags []Bag `json:"-"` Bulky []BulkyItem `json:"-"` }
type UserCreateRequest ¶
type UserCreateRequest struct { Email string `json:"email" binding:"required,email"` Name string `json:"name" binding:"required,min=3"` Address string `json:"address" binding:"required,min=3"` PhoneNumber string `json:"phone_number" binding:"required,min=3"` Newsletter bool `json:"newsletter"` Sizes []string `json:"sizes"` Latitude float64 `json:"latitude"` Longitude float64 `json:"longitude"` }
type UserOnesignal ¶
type UserUpdateRequest ¶
type UserUpdateRequest struct { ChainUID string `json:"chain_uid,omitempty" binding:"omitempty,uuid"` UserUID string `json:"user_uid,omitempty" binding:"uuid"` Name *string `json:"name,omitempty"` PhoneNumber *string `json:"phone_number,omitempty"` Newsletter *bool `json:"newsletter,omitempty"` PausedUntil *time.Time `json:"paused_until,omitempty"` ChainPaused *bool `json:"chain_paused,omitempty"` Sizes *[]string `json:"sizes,omitempty"` Address *string `json:"address,omitempty"` I18n *string `json:"i18n,omitempty"` Latitude *float64 `json:"latitude,omitempty"` Longitude *float64 `json:"longitude,omitempty"` AcceptedLegal *bool `json:"accepted_legal,omitempty"` }
Click to show internal directories.
Click to hide internal directories.