data

package
v0.0.0-...-393e050 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2024 License: MIT Imports: 21 Imported by: 0

README

Data

Documentation

Index

Constants

This section is empty.

Variables

ProviderSet is data providers.

Functions

func NewCampaignRepo

func NewCampaignRepo(data *Data) biz.CampaignRepo

NewCampaignRepo .

func NewUserRepo

func NewUserRepo(data *Data) biz.UserRepo

NewUserRepo .

func NewUserVoucherRepo

func NewUserVoucherRepo(data *Data) biz.UserVoucherRepo

NewUserVoucherRepo .

func NewVoucherCampaignRepo

func NewVoucherCampaignRepo(data *Data) biz.VoucherCampaignRepo

NewVoucherCampaignRepo .

func NewVoucherRepo

func NewVoucherRepo(data *Data) biz.VoucherRepo

NewVoucherRepo .

Types

type Data

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

Data .

func NewData

func NewData(conf *conf.Data) (*Data, func(), error)

NewData .

func (*Data) GetClient

func (d *Data) GetClient(ctx context.Context) *ent.Client

func (*Data) NewTxContext

func (d *Data) NewTxContext(ctx context.Context, tx *ent.Tx) context.Context

func (*Data) TxCompleted

func (d *Data) TxCompleted(ctx context.Context) context.Context

func (*Data) TxFromContext

func (d *Data) TxFromContext(ctx context.Context) (tx *ent.Tx, ok bool)

func (*Data) WithTx

func (r *Data) WithTx(ctx context.Context, fn func(ctx context.Context) error) error

Jump to

Keyboard shortcuts

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