app

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jul 9, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Item

type Item struct {
	TaskName string `json:"task_name"`
	Descs    string `json:"descs"`
	Points   int    `json:"points"`
	Time     string `json:"time"`
}

type PointsCmd

type PointsCmd struct {
	Promotionid string
	User        types.Account
	Lang        common.Language
}

type PointsDTO

type PointsDTO struct {
	Items []Item `json:"items"`
	Total int    `json:"total"`
}

type PointsRankDTO

type PointsRankDTO struct {
	User  string `json:"user"`
	Point int    `json:"point"`
}

type PointsService

type PointsService interface {
	GetPoints(*PointsCmd) (PointsDTO, error)
	GetPointsRank(promotionid string) ([]PointsRankDTO, error)
}

func NewPointsService

func NewPointsService(
	service service.PointsTaskService,
) PointsService

type PromotionCmd

type PromotionCmd struct {
	User types.Account
	// contains filtered or unexported fields
}

type PromotionDTO

type PromotionDTO struct {
	Id         string `json:"id"`
	Name       string `json:"name"`
	Desc       string `json:"desc"`
	Poster     string `json:"poster"`
	Status     string `json:"status"`
	IsRegister bool   `json:"is_register"`
	Total      int    `json:"total"`
	Duration   string `json:"duration"`
}

type PromotionService

type PromotionService interface {
	GetPromotion(*PromotionCmd) (PromotionDTO, error)
	GetUserRegisterPromotion(*types.Account) ([]PromotionDTO, string, error)
	UserRegister(*UserRegistrationCmd) (code string, err error)
}

type UserRegistrationCmd

type UserRegistrationCmd struct {
	PromotionId string
	domain.UserRegistration
	Origin domain.Origin
}

Jump to

Keyboard shortcuts

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