service

package
v0.0.0-...-a330f29 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2023 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ItemService

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

func NewItemService

func NewItemService(data *data.Data) *ItemService

func (*ItemService) Create

func (is *ItemService) Create(ctx context.Context, req *dto.ItemInBody) (int64, error)

func (*ItemService) GetTotalAmountByExpenses

func (is *ItemService) GetTotalAmountByExpenses(ctx context.Context, userId uint64) (float64, error)

func (*ItemService) GetTotalAmountByIncome

func (is *ItemService) GetTotalAmountByIncome(ctx context.Context, userId uint64) (float64, error)

func (*ItemService) List

func (is *ItemService) List(ctx context.Context, req *dto.ItemListQueries) (*page.Page[*model.Item], error)

type TagService

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

func NewTagService

func NewTagService(data *data.Data) *TagService

func (*TagService) Create

func (ts *TagService) Create(ctx context.Context, req *dto.TagInBody) error

func (*TagService) List

func (ts *TagService) List(ctx context.Context, queries *dto.TagListQueries) (p *page.Page[*model.Tag], err error)

type UserService

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

func NewUserService

func NewUserService(data *data.Data, jwt *jwt.JWT, mailer *mailer.Mailer) *UserService

func (*UserService) FindOrCreate

func (us *UserService) FindOrCreate(ctx context.Context, req *dto.UserInBody) (*dto.UserOutBody, error)

func (*UserService) GetCurrentUser

func (us *UserService) GetCurrentUser(ctx context.Context, userId string) (*dto.UserProfileResp, error)

func (*UserService) SendVerificationCode

func (us *UserService) SendVerificationCode(ctx context.Context, email string) (err error)

Jump to

Keyboard shortcuts

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