communityFund

package
v0.0.0-...-a5fc328 Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2020 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrorUnableToGetProposalVotes       = errors.New("Unable to retrieve proposal votes")
	ErrorUnableToGetPaymentRequestVotes = errors.New("Unable to retrieve payment request votes")
	ErrorUnableToMatchVote              = errors.New("Unable to match vote")
)

Functions

func GetPaymentRequestVotes

func GetPaymentRequestVotes(user account.User) (votes []model.Vote, err error)

func GetProposalVotes

func GetProposalVotes(user account.User) (votes []model.Vote, err error)

func UpdatePaymentRequestVotes

func UpdatePaymentRequestVotes(voteDtos []VoteDto, user account.User) (err error)

func UpdateProposalVotes

func UpdateProposalVotes(voteDtos []VoteDto, user account.User) (err error)

Types

type Controller

type Controller struct{}

func (*Controller) GetPaymentRequestVotes

func (controller *Controller) GetPaymentRequestVotes(c *gin.Context)

func (*Controller) GetProposalVotes

func (controller *Controller) GetProposalVotes(c *gin.Context)

func (*Controller) UpdatePaymentRequestVotes

func (controller *Controller) UpdatePaymentRequestVotes(c *gin.Context)

func (*Controller) UpdateProposalVotes

func (controller *Controller) UpdateProposalVotes(c *gin.Context)

type VoteDto

type VoteDto struct {
	Type   model.VoteType   `json:"type" binding:"required"`
	Hash   string           `json:"hash" binding:"required"`
	Choice model.VoteChoice `json:"vote" binding:"required"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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