Documentation ¶
Index ¶
Constants ¶
View Source
const ( GET_REPORT_SELLER = "" /* 126-byte string literal not displayed */ INSERT = "INSERT INTO localities (zip_code, locality_name, province_name, country_name) VALUES (?,?,?,?)" GETALL = "SELECT * FROM localities" GETBYID = "SELECT * FROM localities WHERE id = ?" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ReportSeller ¶
type Repository ¶
type Repository interface { GetAll(ctx context.Context) ([]Locality, error) GetById(ctx context.Context, id int) (Locality, error) Create(ctx context.Context, zipCode, localityName, provinceName, countryName string) (Locality, error) ReportSellers(ctx context.Context, id int) (ReportSeller, error) }
func NewMariaDBRepository ¶
func NewMariaDBRepository(db *sql.DB) Repository
type Service ¶
type Service interface { GetAll(ctx context.Context) ([]Locality, error) GetById(ctx context.Context, id int) (Locality, error) ReportSellers(ctx context.Context, id int) (ReportSeller, error) Create(ctx context.Context, zipCode, localityName, provinceName, countryName string) (Locality, error) }
func NewService ¶
func NewService(r Repository) Service
Click to show internal directories.
Click to hide internal directories.