merchant

package
v0.0.0-...-1985c56 Latest Latest
Warning

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

Go to latest
Published: Apr 8, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package merchant represents our merchant apis and especially types.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Merchant

type Merchant struct {
	gorm.Model
	ebs_fields.Merchant
	// contains filtered or unexported fields
}

Merchant is a fully qualified noebs merchant

func New

func New(db *gorm.DB) *Merchant

New generates a new merchant struct to be used later

func (Merchant) AddBilling

func (m Merchant) AddBilling(c *gin.Context)

AddBilling to a specific biller ID via `MerchantMobileNumber`

func (*Merchant) ByID

func (m *Merchant) ByID(id string) (*ebs_fields.Merchant, error)

ByID get a merchant profile using their id

func (Merchant) GetMerchant

func (m Merchant) GetMerchant(c *gin.Context)

GetMerchant from existing merchants in noebs

func (*Merchant) Init

func (m *Merchant) Init(db *gorm.DB, log *logrus.Logger)

Init populates merchant with db pointer

func (Merchant) Login

func (m Merchant) Login(c *gin.Context)

Login creates new noebs merchant

func (*Merchant) SetDB

func (m *Merchant) SetDB(db *gorm.DB)

SetDB assigns db to merchant instance

func (Merchant) Update

func (m Merchant) Update(c *gin.Context)

Update to a specific biller ID via `MerchantMobileNumber`

func (*Merchant) Write

func (m *Merchant) Write() error

Jump to

Keyboard shortcuts

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