Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PaymentConfigRepository ¶
type PaymentConfigRepository struct {
// contains filtered or unexported fields
}
PaymentConfigRepository is storage for payment configurations
func NewPaymentConfigRepository ¶
func NewPaymentConfigRepository(source string) *PaymentConfigRepository
NewPaymentConfigRepository creates payment configuration data source by reading a file located on `source`
func (PaymentConfigRepository) FindAll ¶
func (r PaymentConfigRepository) FindAll(ctx context.Context) (*config.PaymentConfig, error)
FindAll returns all payment configurations.
func (PaymentConfigRepository) FindByPaymentType ¶
func (r PaymentConfigRepository) FindByPaymentType(ctx context.Context, paymentType payment.PaymentType, opts ...payment.Option) (config.FeeConfigReader, error)
FindByPaymentType return FeeConfigReader for a given payment type. If it is a credit card, credit card option will be check to get the type of installment, term and its aqcuiring bank. Otherwise 0 month installment offline from BCA will be used.
Click to show internal directories.
Click to hide internal directories.