Documentation ¶
Index ¶
- type AuthService
- func (s *AuthService) Login(ctx context.Context, req request.LoginRequest) (res transformer.LoginTransformer, err error)
- func (s *AuthService) Me(ctx context.Context, user utils.AuthUser) (res transformer.MeTransformer, err error)
- func (s *AuthService) Register(ctx context.Context, req request.RegisterRequest) (res transformer.RegisterTransformer, err error)
- type BlogService
- func (s *BlogService) Create(ctx context.Context, req request.CreateBlogRequest) (result transformer.BlogTransformer, err error)
- func (s *BlogService) Delete(ctx context.Context, id uint64) (err error)
- func (s *BlogService) GetAllBlog(ctx context.Context) (result []transformer.BlogTransformer, err error)
- func (s *BlogService) GetByID(ctx context.Context, id uint64) (result transformer.BlogTransformer, err error)
- func (s *BlogService) Update(ctx context.Context, id uint64, req request.UpdateBlogRequest) (result transformer.BlogTransformer, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuthService ¶
type AuthService struct { Core *core.Core UserRepo *repository.UserRepository }
func NewAuthService ¶
func NewAuthService(c *core.Core, userRepo *repository.UserRepository) *AuthService
func (*AuthService) Login ¶
func (s *AuthService) Login(ctx context.Context, req request.LoginRequest) (res transformer.LoginTransformer, err error)
func (*AuthService) Me ¶
func (s *AuthService) Me(ctx context.Context, user utils.AuthUser) (res transformer.MeTransformer, err error)
func (*AuthService) Register ¶
func (s *AuthService) Register(ctx context.Context, req request.RegisterRequest) (res transformer.RegisterTransformer, err error)
type BlogService ¶
type BlogService struct { Core *core.Core BlogRepo *repository.BlogRepository }
func NewBlogService ¶
func NewBlogService(c *core.Core, blogRepo *repository.BlogRepository) *BlogService
func (*BlogService) Create ¶
func (s *BlogService) Create(ctx context.Context, req request.CreateBlogRequest) (result transformer.BlogTransformer, err error)
func (*BlogService) Delete ¶
func (s *BlogService) Delete(ctx context.Context, id uint64) (err error)
func (*BlogService) GetAllBlog ¶
func (s *BlogService) GetAllBlog(ctx context.Context) (result []transformer.BlogTransformer, err error)
func (*BlogService) GetByID ¶
func (s *BlogService) GetByID(ctx context.Context, id uint64) (result transformer.BlogTransformer, err error)
func (*BlogService) Update ¶
func (s *BlogService) Update(ctx context.Context, id uint64, req request.UpdateBlogRequest) (result transformer.BlogTransformer, err error)
Click to show internal directories.
Click to hide internal directories.