domain

package
v0.0.0-...-a70c2ec Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2022 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Account

type Account struct {
	AccountId   string
	CustomerId  string
	OpeningDate string
	AccountType string
	Amount      float64
	Status      string
}

func (Account) ToNewAccountResponseDto

func (a Account) ToNewAccountResponseDto() *dto.NewAccountResponse

type AccountRepository

type AccountRepository interface {
	Save(Account) (*Account, *errs.AppError)
}

type AccountRespositoryDb

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

func NewAccountRepositoryDb

func NewAccountRepositoryDb(dbClient *sqlx.DB) AccountRespositoryDb

func (AccountRespositoryDb) Save

type Customer

type Customer struct {
	Id          string `db:"customer_id"`
	Name        string
	City        string
	Zipcode     string
	DateofBirth string `db:"date_of_birth"`
	Status      string
}

func (Customer) ToDto

func (c Customer) ToDto() dto.CustomerResponse

type CustomerRepository

type CustomerRepository interface {
	FindAll(status string) ([]Customer, *errs.AppError)
	ById(string) (*Customer, *errs.AppError)
}

type CustomerRepositoryDb

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

func NewCustomerRepositoryDb

func NewCustomerRepositoryDb(dbClient *sqlx.DB) CustomerRepositoryDb

func (CustomerRepositoryDb) ById

func (CustomerRepositoryDb) FindAll

func (d CustomerRepositoryDb) FindAll(status string) ([]Customer, *errs.AppError)

type CustomerRepositoryStub

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

func NewCustomerRepositoryStub

func NewCustomerRepositoryStub() CustomerRepositoryStub

func (CustomerRepositoryStub) FindAll

func (s CustomerRepositoryStub) FindAll() ([]Customer, error)

Jump to

Keyboard shortcuts

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