Documentation ¶
Overview ¶
Package persistence. Code is generated. DO NOT EDIT.
Index ¶
- func NewIncomeRepository() domain.IncomeRepository
- type IncomeEntity
- type IncomeRepository
- func (repository *IncomeRepository) CountByAccountId(ctx trx.Context, accountId int64) (int64, error)
- func (repository *IncomeRepository) DeleteByAccountId(ctx trx.Context, accountId int64) (int64, error)
- func (repository *IncomeRepository) DeleteById(ctx trx.Context, id int64) (bool, error)
- func (repository *IncomeRepository) FindByAccountIdAndTransactionAtBetween(ctx trx.Context, accountId int64, start time.Time, end time.Time) ([]*domain.Income, error)
- func (repository *IncomeRepository) FindByAccountIdOrderByAccountIdAndTransactionAtDesc(ctx trx.Context, accountId int64) ([]*domain.Income, error)
- func (repository *IncomeRepository) FindById(ctx trx.Context, id int64) (*domain.Income, error)
- func (repository *IncomeRepository) Insert(ctx trx.Context, income *domain.Income) (*domain.Income, error)
- func (repository *IncomeRepository) InsertAll(ctx trx.Context, incomes []*domain.Income) ([]*domain.Income, error)
- func (repo *IncomeRepository) Test(ctx trx.Context) int64
- func (repository *IncomeRepository) UpdateAccountIdAndDetailByTransactionAt(ctx trx.Context, accountId int64, detail string, transactionAt time.Time) (int64, error)
- func (repository *IncomeRepository) UpdateById(ctx trx.Context, income *domain.Income, id int64) (bool, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewIncomeRepository ¶
func NewIncomeRepository() domain.IncomeRepository
Types ¶
type IncomeEntity ¶
type IncomeEntity struct { Id db_gorm.ID `gorm:"primaryKey"` Detail string `gorm:"detail;type:VARCHAR(64) NOT NULL"` Amount int64 `gorm:"type:bigint NOT NULL DEFAULT 0"` SubjectId db_gorm.ID `gorm:"not null" mapper:"Subject,subject2Id,id2Subject"` AccountId db_gorm.ID `gorm:"not null"` OperatorId db_gorm.ID `gorm:"not null"` TransactionAt time.Time `gorm:"not null"` CreateAt time.Time `gorm:"autoCreateTime;not null"` }
func (*IncomeEntity) TableName ¶
func (entity *IncomeEntity) TableName() string
type IncomeRepository ¶
type IncomeRepository struct { }
func (*IncomeRepository) CountByAccountId ¶
func (*IncomeRepository) DeleteByAccountId ¶
func (*IncomeRepository) DeleteById ¶
func (*IncomeRepository) FindByAccountIdAndTransactionAtBetween ¶
func (*IncomeRepository) FindByAccountIdOrderByAccountIdAndTransactionAtDesc ¶
func (*IncomeRepository) UpdateAccountIdAndDetailByTransactionAt ¶
func (*IncomeRepository) UpdateById ¶
Click to show internal directories.
Click to hide internal directories.