Documentation ¶
Index ¶
- type CategoryService
- type CategoryServiceImpl
- func (services *CategoryServiceImpl) Create(ctx context.Context, request web.CategoryCreateRequest) web.CategoryResponse
- func (services *CategoryServiceImpl) Delete(ctx context.Context, categoryId int)
- func (services *CategoryServiceImpl) FindAll(ctx context.Context) []web.CategoryResponse
- func (services *CategoryServiceImpl) FindById(ctx context.Context, categoryId int) web.CategoryResponse
- func (services *CategoryServiceImpl) Update(ctx context.Context, request web.CategoryUpdateRequest) web.CategoryResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CategoryService ¶
type CategoryService interface { Create(ctx context.Context, request web.CategoryCreateRequest) web.CategoryResponse Update(ctx context.Context, request web.CategoryUpdateRequest) web.CategoryResponse Delete(ctx context.Context, categoryId int) FindById(ctx context.Context, categoryId int) web.CategoryResponse FindAll(ctx context.Context) []web.CategoryResponse }
func NewCategoryService ¶
func NewCategoryService(categoryRepository repository.CategoryRepository, DB *sql.DB, validate *validator.Validate) CategoryService
type CategoryServiceImpl ¶
type CategoryServiceImpl struct { CategoryRepository repository.CategoryRepository DB *sql.DB Validate *validator.Validate }
func (*CategoryServiceImpl) Create ¶
func (services *CategoryServiceImpl) Create(ctx context.Context, request web.CategoryCreateRequest) web.CategoryResponse
func (*CategoryServiceImpl) Delete ¶
func (services *CategoryServiceImpl) Delete(ctx context.Context, categoryId int)
func (*CategoryServiceImpl) FindAll ¶
func (services *CategoryServiceImpl) FindAll(ctx context.Context) []web.CategoryResponse
func (*CategoryServiceImpl) FindById ¶
func (services *CategoryServiceImpl) FindById(ctx context.Context, categoryId int) web.CategoryResponse
func (*CategoryServiceImpl) Update ¶
func (services *CategoryServiceImpl) Update(ctx context.Context, request web.CategoryUpdateRequest) web.CategoryResponse
Click to show internal directories.
Click to hide internal directories.