Documentation ¶
Index ¶
- func NewGormDB(dns string) (*gorm.DB, error)
- type AuthGormService
- type AuthService
- type CategoryGormService
- func (service *CategoryGormService) CreateCategoryRecord(category *models.Category) error
- func (service *CategoryGormService) DeleteCategoryRecordById(id uint) error
- func (service *CategoryGormService) GetAllCategories() ([]models.Category, error)
- func (service *CategoryGormService) GetCategoryById(id uint) (*models.Category, error)
- func (service *CategoryGormService) UpdateCategoryRecord(category *models.Category) error
- type CategoryNotFoundError
- type CategoryService
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AuthGormService ¶
type AuthGormService struct {
// contains filtered or unexported fields
}
func NewAuthGormService ¶
func NewAuthGormService(db *gorm.DB) *AuthGormService
func (*AuthGormService) CreateUserRecord ¶
func (service *AuthGormService) CreateUserRecord(user *models.User) error
func (*AuthGormService) GetAllUsers ¶
func (service *AuthGormService) GetAllUsers() ([]models.User, error)
func (*AuthGormService) GetUserByEmail ¶
func (service *AuthGormService) GetUserByEmail(email string) (*models.User, error)
type AuthService ¶
type CategoryGormService ¶
type CategoryGormService struct {
// contains filtered or unexported fields
}
func NewCategoryGormService ¶
func NewCategoryGormService(db *gorm.DB) *CategoryGormService
func (*CategoryGormService) CreateCategoryRecord ¶
func (service *CategoryGormService) CreateCategoryRecord(category *models.Category) error
func (*CategoryGormService) DeleteCategoryRecordById ¶
func (service *CategoryGormService) DeleteCategoryRecordById(id uint) error
func (*CategoryGormService) GetAllCategories ¶
func (service *CategoryGormService) GetAllCategories() ([]models.Category, error)
func (*CategoryGormService) GetCategoryById ¶
func (service *CategoryGormService) GetCategoryById(id uint) (*models.Category, error)
func (*CategoryGormService) UpdateCategoryRecord ¶
func (service *CategoryGormService) UpdateCategoryRecord(category *models.Category) error
type CategoryNotFoundError ¶
type CategoryNotFoundError struct{}
func (*CategoryNotFoundError) Error ¶
func (e *CategoryNotFoundError) Error() string
type CategoryService ¶
Click to show internal directories.
Click to hide internal directories.