dao

package
v1.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 15, 2023 License: GPL-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type NethWithdrawalRequest

type NethWithdrawalRequest struct {
	ID                 uint64    `gorm:"column:id;primary_key" json:"id"`
	Network            string    `gorm:"column:network;" json:"network"`
	OperatorId         uint64    `gorm:"column:operator_id;" json:"operator_id"`
	RequestId          uint64    `gorm:"column:request_id;" json:"request_id"`
	WithdrawHeight     string    `gorm:"column:withdraw_height;" json:"withdraw_height"`
	WithdrawNethAmount string    `gorm:"column:withdraw_neth_amount;" json:"withdraw_neth_amount"`
	WithdrawExchange   string    `gorm:"column:withdraw_exchange;" json:"withdraw_exchange"`
	ClaimEthAmount     string    `gorm:"column:claim_eth_amount;" json:"claim_eth_amount"`
	Owner              string    `gorm:"column:owner;" json:"owner"`
	IsExit             bool      `gorm:"column:is_exit;" json:"is_exit"`
	Ctime              time.Time `gorm:"column:ctime;default" json:"ctime"`
	Mtime              time.Time `gorm:"column:mtime;default" json:"mtime"`
}

func NewNethWithdrawalRequest

func NewNethWithdrawalRequest() *NethWithdrawalRequest

func (*NethWithdrawalRequest) CreateBatch

func (e *NethWithdrawalRequest) CreateBatch(withdrawalRequests []*NethWithdrawalRequest) error

func (*NethWithdrawalRequest) GetByRequestIds

func (e *NethWithdrawalRequest) GetByRequestIds(network string, operatorId uint64, requestId []uint64, isExit bool) ([]*NethWithdrawalRequest, error)

func (*NethWithdrawalRequest) InsertForNotExist

func (e *NethWithdrawalRequest) InsertForNotExist(withdrawalRequests []*NethWithdrawalRequest) error

func (*NethWithdrawalRequest) TableName

func (e *NethWithdrawalRequest) TableName() string

func (*NethWithdrawalRequest) UpdateExited

func (e *NethWithdrawalRequest) UpdateExited(network string, requestId []uint64) error

type NodedaoValidator

type NodedaoValidator struct {
	ID         uint64             `gorm:"column:id;primary_key" json:"id"`
	Network    string             `gorm:"column:network;" json:"network"`
	Pubkey     string             `gorm:"column:pubkey;" json:"pubkey"`
	OperatorId uint64             `gorm:"column:operator_id;type:BIGINT;" json:"operator_id"`
	TokenId    uint64             `gorm:"column:token_id;type:BIGINT;" json:"token_id"`
	Type       exitscan.StakeType `gorm:"column:type;" json:"type"`
	IsExit     bool               `gorm:"column:is_exit;" json:"is_exit"`
	Ctime      time.Time          `gorm:"column:ctime;default" json:"ctime"`
	Mtime      time.Time          `gorm:"column:mtime;default" json:"mtime"`
}

func NewNodedaoValidator

func NewNodedaoValidator() *NodedaoValidator

func (*NodedaoValidator) CreateBatch

func (e *NodedaoValidator) CreateBatch(vnftRecords []*NodedaoValidator) error

func (*NodedaoValidator) GetByTokenIds

func (e *NodedaoValidator) GetByTokenIds(network string, operatorId uint64, tokenIds []uint64, unstakeType exitscan.StakeType, isExit bool) ([]*NodedaoValidator, error)

func (*NodedaoValidator) TableName

func (e *NodedaoValidator) TableName() string

func (*NodedaoValidator) UpdateExited

func (e *NodedaoValidator) UpdateExited(network string, tokenIds []uint64) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL