Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type NodeProfile ¶
type NodeProfile struct { // Default Gorm Model Properties // Stating here to remove from JSON responses with `json:"-"` ID uint `json:"-" gorm:"primary_key"` CreatedAt time.Time `json:"-"` UpdatedAt time.Time `json:"-"` DeletedAt *time.Time `json:"-"` Name string `json:"name" gorm:"not null"` Email string `json:"email" gorm:"not null"` Bio string `json:"bio" gorm:"not null"` Location string `json:"location" gorm:"not null"` IPAddress string `json:"-" gorm:"not null"` EstimatedSpeed int `json:"estimatedSpeed" gorm:"not null"` PoolAccepted bool `json:"-" gorm:"default:false"` NodeAccepted bool `json:"-" gorm:"default:false"` Pending bool `json:"pending" gorm:"default:true"` Approved bool `json:"approved" gorm:"default:false"` Wallet string `json:"wallet" gorm:"not null; unique"` }
func CreateApplication ¶
func CreateApplication(payload *NodeRequestPayload) NodeProfile
func (*NodeProfile) AfterUpdate ¶
func (profile *NodeProfile) AfterUpdate(tx *gorm.DB) (err error)
type NodeRequestPayload ¶
type PoolInformation ¶
type PoolInformation struct { // Default Gorm Model Properties // Stating here to remove from JSON responses with `json:"-"` ID uint `json:"-" gorm:"primary_key"` CreatedAt time.Time `json:"-"` UpdatedAt time.Time `json:"-"` DeletedAt *time.Time `json:"-"` OnlyRow int `json:"-" gorm:"unique;not null;default:1"` Address string `json:"address" gorm:"not null"` Name string `json:"name" gorm:"not null"` Bio string `json:"bio"` Location string `json:"location" gorm:"not null"` Rating int `json:"rating"` NodeCount int `json:"nodeCount" gorm:"not null;default:0"` Wallet string `json:"wallet" gorm:"not null"` Email string `json:"email" gorm:"not null"` Url string `json:"url" gorm:"-"` Public bool `json:"public" gorm:"not null;default:false"` }
func (PoolInformation) TableName ¶
func (PoolInformation) TableName() string
Click to show internal directories.
Click to hide internal directories.