generated

package
v0.0.0-...-fb54e65 Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2023 License: Unlicense Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CreateEavAttributeOptionParams

type CreateEavAttributeOptionParams struct {
	EavAttributeCode string
	Value            string
	Ordering         uint16
	IsVisible        bool
}

type CreateEavAttributeParams

type CreateEavAttributeParams struct {
	Code        string
	Name        string
	ValueType   uint8
	Description string
	FieldFormat pgtype.Text
	Regexp      pgtype.Text
	MinLength   pgtype.Int2
	MaxLength   pgtype.Int2
	IsSelection bool
	IsRequired  bool
}

type CreateEavAttributeValueParams

type CreateEavAttributeValueParams struct {
	UserID           uint64
	EavAttributeCode string
	Value            string
}

type CreateEavAttributeValueRow

type CreateEavAttributeValueRow struct {
	UserID           uint64
	EavAttributeCode string
}

type DBTX

type DBTX interface {
	Exec(context.Context, string, ...interface{}) (pgconn.CommandTag, error)
	Query(context.Context, string, ...interface{}) (pgx.Rows, error)
	QueryRow(context.Context, string, ...interface{}) pgx.Row
}

type EavAttribute

type EavAttribute struct {
	Code        string
	Name        string
	ValueType   uint8
	Description string
	FieldFormat pgtype.Text
	Regexp      pgtype.Text
	MinLength   pgtype.Int2
	MaxLength   pgtype.Int2
	IsSelection bool
	IsRequired  bool
	CreatedAt   pgtype.Timestamp
}

type EavAttributeOption

type EavAttributeOption struct {
	ID               uint64
	EavAttributeCode string
	Value            string
	Ordering         uint16
	IsVisible        bool
	CreatedAt        pgtype.Timestamp
}

type EavAttributeValue

type EavAttributeValue struct {
	UserID           uint64
	EavAttributeCode string
	Value            string
	CreatedAt        pgtype.Timestamp
}

type GetEavAttributeValueByUserIDAndCodeParams

type GetEavAttributeValueByUserIDAndCodeParams struct {
	UserID           uint64
	EavAttributeCode string
}

type Queries

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

func New

func New(db DBTX) *Queries

func (*Queries) CreateEavAttribute

func (q *Queries) CreateEavAttribute(ctx context.Context, arg CreateEavAttributeParams) (string, error)

func (*Queries) CreateEavAttributeOption

func (q *Queries) CreateEavAttributeOption(ctx context.Context, arg CreateEavAttributeOptionParams) (string, error)

func (*Queries) CreateEavAttributeValue

func (q *Queries) CreateEavAttributeValue(ctx context.Context, arg CreateEavAttributeValueParams) (CreateEavAttributeValueRow, error)

func (*Queries) CreateUser

func (q *Queries) CreateUser(ctx context.Context) (uint64, error)

func (*Queries) DeleteUserByID

func (q *Queries) DeleteUserByID(ctx context.Context, id uint64) error

func (*Queries) GetEavAttributeByCode

func (q *Queries) GetEavAttributeByCode(ctx context.Context, code string) (EavAttribute, error)

func (*Queries) GetEavAttributeValueByUserIDAndCode

func (q *Queries) GetEavAttributeValueByUserIDAndCode(ctx context.Context, arg GetEavAttributeValueByUserIDAndCodeParams) (EavAttributeValue, error)

func (*Queries) GetUserByID

func (q *Queries) GetUserByID(ctx context.Context, id uint64) (User, error)

func (*Queries) ListEavAttributeOptionByEavAttributeCode

func (q *Queries) ListEavAttributeOptionByEavAttributeCode(ctx context.Context, eavAttributeCode string) ([]EavAttributeOption, error)

func (*Queries) ListEavAttributeValueByUserID

func (q *Queries) ListEavAttributeValueByUserID(ctx context.Context, userID uint64) ([]EavAttributeValue, error)

func (*Queries) ListEavAttributes

func (q *Queries) ListEavAttributes(ctx context.Context) ([]EavAttribute, error)

func (*Queries) WithTx

func (q *Queries) WithTx(tx pgx.Tx) *Queries

type User

type User struct {
	ID        uint64
	CreatedAt pgtype.Timestamp
}

Jump to

Keyboard shortcuts

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