server

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jun 12, 2024 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	SUCCESS = 0
	FAIL    = 1
)

Variables

This section is empty.

Functions

This section is empty.

Types

type CallBack

type CallBack struct {
	AmountOfGasFee string `json:"amountOfGasFee" gorm:"column:amountOfGasFee"`
	Hook           string `json:"callback" gorm:"column:callback"`
	Recipient      string `json:"recipient" gorm:"column:recipient"`
	Sender         string `json:"senderMd5" gorm:"column:sender"`
	Memo           string `json:"memo" gorm:"column:memo"`
	AmountOfAbel   string `json:"amountOfAbel" gorm:"column:amountOfAbel"`
}

type Deposit

type Deposit struct {
	FromNetwork string `json:"from_network" gorm:"from_network"`
	FromAddress string `json:"from_address" gorm:"from_address"`
	ToNetwork   string `json:"to_network" gorm:"to_network"`
	ToAddress   string `json:"to_address" gorm:"to_address"`
	UUID        string `json:"uuid" gorm:"uuid"`
	Hash        string `json:"hash" gorm:"hash"`
	CallBack    string `json:"callBack" gorm:"call_back"`
}

func (*Deposit) TableName

func (d *Deposit) TableName() string

type Memo

type Memo struct {
	Protocol string `json:"protocol" gorm:"column:protocol"`
	Action   string `json:"action" gorm:"column:action"`
	From     string `json:"from" gorm:"column:from"`
	Receipt  string `json:"receipt" gorm:"column:receipt"`
	To       string `json:"to" gorm:"column:to"`
	Value    string `json:"value" gorm:"column:value"`
}

type Service

type Service struct {
	// contains filtered or unexported fields
}

func NewService

func NewService(config config.Config, log *xlog.XLog) *Service

func (*Service) Error

func (s *Service) Error(c *gin.Context, req string, path string, err string)

func (*Service) GetDeposit

func (s *Service) GetDeposit(ctx *gin.Context)

func (*Service) GetToAddress

func (s *Service) GetToAddress(ctx *gin.Context)

func (*Service) NotifyTx

func (s *Service) NotifyTx(ctx *gin.Context)

func (*Service) SaveTx

func (s *Service) SaveTx(ctx *gin.Context)

func (*Service) SaveTxAndMemo

func (s *Service) SaveTxAndMemo(ctx *gin.Context)

func (*Service) Success

func (s *Service) Success(c *gin.Context, req string, resp interface{}, path string)

Jump to

Keyboard shortcuts

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