Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIClient ¶
type APIClient interface {
UpdateWorkplace(info *model.WorkplaceInfo) error
}
APIClient server api client
type ClientService ¶
type ClientService struct {
// contains filtered or unexported fields
}
ClientService describe workplace client side
func NewClientService ¶
func NewClientService(client APIClient) *ClientService
NewClientService create a new client service
func (*ClientService) UpdateWorkplace ¶
func (s *ClientService) UpdateWorkplace() (*model.WorkplaceInfo, error)
UpdateWorkplace performing workplace creating or updating
type WorkplaceRepository ¶
type WorkplaceRepository interface { Add(ctx context.Context, entity *model.WorkplaceInfo) error Delete(ctx context.Context, ID int) error }
WorkplaceRepository describe workplace repository
type WorkplaceService ¶
type WorkplaceService struct {
// contains filtered or unexported fields
}
WorkplaceService describe workplace service
func NewWorkplaceService ¶
func NewWorkplaceService(r WorkplaceRepository) *WorkplaceService
NewWorkplaceService get workplace service
func (WorkplaceService) Add ¶
func (s WorkplaceService) Add(ctx context.Context, workplaceInfo *model.WorkplaceInfo) e.Error
Add adds a new workplace
Click to show internal directories.
Click to hide internal directories.