Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Bid ¶
type Bid interface { CreateBid(ctx context.Context, investor *BidEntity, tx *sqlx.Tx) (*BidEntity, error) ListBids(ctx context.Context, invoiceID uuid.UUID) ([]BidEntity, error) }
Bid is a interface that contains the methods for the Bidding services
type BidEntity ¶
type BidEntity struct { ID uuid.UUID InvoiceID uuid.UUID InvestorID uuid.UUID Amount int64 Currency string Created time.Time Updated time.Time }
BidEntity represents a bid entity
type Investor ¶
type Investor interface { CreateInvestor(ctx context.Context, investor *InvestorEntity, tx *sqlx.Tx) (*InvestorEntity, error) GetInvestor(ctx context.Context, id uuid.UUID) (*InvestorWithWalletEntity, error) ListInvestor(ctx context.Context, paging *Paging) ([]InvestorWithWalletEntity, error) DeleteInvestor(ctx context.Context, id uuid.UUID, tx *sqlx.Tx) error }
Investor is a interface that contains the methods for the investor services
type InvestorEntity ¶
type InvestorEntity struct { ID uuid.UUID VatNumber string Name string Created time.Time Updated time.Time }
InvestorEntity entity
type InvestorWithWalletEntity ¶
type InvestorWithWalletEntity struct { InvestorEntity Wallet *WalletEntity }
InvestorWithWalletEntity entity
type InvestorsRepo ¶
type InvestorsRepo interface { Investor Wallet TransactionProvider }
InvestorsRepo is a interface that contains the methods for the Investor and its wallets services
type Invoice ¶
type Invoice interface { CreateInvoice(ctx context.Context, invoice *InvoiceEntity, tx *sqlx.Tx) (*InvoiceEntity, error) GetInvoice(ctx context.Context, id uuid.UUID) (*InvoiceEntity, error) UpdateInvoice(ctx context.Context, invoice *InvoiceEntity, tx *sqlx.Tx) error ListInvoice(ctx context.Context, paging *Paging) ([]InvoiceEntity, error) DeleteInvoice(ctx context.Context, id uuid.UUID, tx *sqlx.Tx) error }
Invoice is a interface that contains the methods for the invoice services
type InvoiceEntity ¶
type InvoiceEntity struct { ID uuid.UUID IssuerID uuid.UUID Number string Description string Status string Amount int64 Currency string Created time.Time Updated time.Time }
InvoiceEntity entity
type InvoicesRepo ¶
InvoicesRepo is a interface that contains the methods for the various invoices services
type Issuer ¶
type Issuer interface { CreateIssuer(ctx context.Context, investor *IssuerEntity, tx *sqlx.Tx) (*IssuerEntity, error) GetIssuer(ctx context.Context, id uuid.UUID) (*IssuerWithWalletEntity, error) ListIssuer(ctx context.Context, paging *Paging) ([]IssuerWithWalletEntity, error) DeleteIssuer(ctx context.Context, id uuid.UUID, tx *sqlx.Tx) error }
Issuer is a interface that contains the methods for the issuer services
type IssuerEntity ¶
IssuerEntity model
type IssuerWithWalletEntity ¶
type IssuerWithWalletEntity struct { IssuerEntity Wallet *WalletEntity }
IssuerWithWalletEntity entity
type IssuersRepo ¶
type IssuersRepo interface { Issuer Wallet TransactionProvider }
IssuersRepo is a interface that contains the methods for the Issuer and its wallets services
type TransactionProvider ¶
TransactionProvider is a interface that contains the methods for transactions
type Wallet ¶
type Wallet interface { CreateWallet(ctx context.Context, investor *WalletEntity, tx *sqlx.Tx) (*WalletEntity, error) GetWallet(ctx context.Context, id uuid.UUID) (*WalletEntity, error) UpdateWallet(ctx context.Context, investor *WalletEntity, tx *sqlx.Tx) (*WalletEntity, error) ListWallets(ctx context.Context, paging *Paging) ([]WalletEntity, error) }
Wallet is a interface that contains the methods for the wallet services