Documentation ¶
Index ¶
- func NewMediaTaskStorage(dataSource string) (storage.MediaTaskStorage, error)
- func NewSecStorage(dataSource string) (storage.SECStorage, error)
- func NewTeamStorage(dataSource string) (storage.TeamStorage, error)
- func NewTextTaskStorage(dataSource string) (storage.TextTaskStorage, error)
- func NewUserAuthStorage(dataSource string) (repository.IUserAuthStorage, error)
- func NewUserStorage(dataSource string) (storage.UserStorage, error)
- type MediaTaskStorage
- func (s *MediaTaskStorage) CheckAnswerOnMediaTaskById(answerMediaTaskId int, teamId int) (exist bool, err error)
- func (s *MediaTaskStorage) CreateAnswerOnMediaTask(teamId int, pointTaskId int) (id int, err error)
- func (s *MediaTaskStorage) GetAllAnswerOnMediaTasks() (tasks []domain.MediaTask, err error)
- func (s *MediaTaskStorage) GetAllMediaTaskByTeam(teamId int) (tasks []domain.MediaTask, err error)
- func (s *MediaTaskStorage) GetAnswerOnMediaTaskById(answerMediaTaskId int) (task domain.MediaTask, err error)
- func (s *MediaTaskStorage) GetAnswersOnMediaTasksByFilter(status string) (tasks []domain.MediaTask, err error)
- func (s *MediaTaskStorage) GetDateAnswerOnMediaTaskById(answerMediaTaskId int) (timeAnswer time.Time, err error)
- func (s *MediaTaskStorage) GetLastMediaTask(teamId int) (task domain.MediaTask, err error)
- func (s *MediaTaskStorage) GetMediaTaskByTeamById(teamId int, answerId int) (task domain.MediaTask, err error)
- func (s *MediaTaskStorage) GetNewMediaTask(teamId int) (task domain.MediaTask, err error)
- func (s *MediaTaskStorage) GetPointsOnMediaTask(mediaTaskId int) (points int, err error)
- func (s *MediaTaskStorage) GetStatusLastMediaTask(teamId int) (status string, err error)
- func (s *MediaTaskStorage) GetUpdateTimeAnswerOnMediaTask(taskId int) (time time.Time, err error)
- func (s *MediaTaskStorage) UpdateAnswerOnMediaTask(taskId int, task domain.MediaAnswer) (err error)
- func (s *MediaTaskStorage) UpdatePointsOnMediaTask(status string, taskId int, points int, comment string) (err error)
- type SecStorage
- func (s *SecStorage) CheckIntersectionTimeInterval(masterClassId, teamId int) (bool, error)
- func (s *SecStorage) CheckMasterClassBusyPlaceById(masterClassId, teamId int) (int, error)
- func (s *SecStorage) CheckMasterClassIsExist(masterClassId int) (bool, error)
- func (s *SecStorage) CheckMasterClassTime(masterClass int) (bool, error)
- func (s *SecStorage) CheckRegisterOnMasterClass(masterClassId, teamId int) (bool, error)
- func (s *SecStorage) CheckRegisterOnSec(secId, teamId int) (bool, error)
- func (s *SecStorage) CreateRegisterOnSEC(masterClassId, teamId int) error
- func (s *SecStorage) DeleteRegisterOnSEC(masterClassId, teamId int) error
- func (s *SecStorage) GetMasterClassByID(masterClassId int) (domain.Sec, error)
- func (s *SecStorage) GetSECAdmin() ([]domain.Sec, error)
- func (s *SecStorage) GetSECAdminById(secId int) ([]domain.Sec, error)
- func (s *SecStorage) GetSECByFilter() ([]domain.Sec, error)
- func (s *SecStorage) GetSecByID(secId int) ([]domain.Sec, error)
- func (s *SecStorage) GetSecByTeamId(teamId int) ([]domain.Sec, error)
- type TeamStorage
- func (s *TeamStorage) AddMemberToTeam(userId int, teamId int) error
- func (s *TeamStorage) CheckTeam(teamName string) (exists bool, err error)
- func (s *TeamStorage) CheckUserExistInTeam(userId, teamId int) (exist bool, err error)
- func (s *TeamStorage) CheckUserHasTeamByEmail(email string) (exists bool, err error)
- func (s *TeamStorage) CheckUserHasTeamById(userId int) (exists bool, err error)
- func (s *TeamStorage) CheckUserIsExistByEmail(email string) (id int, err error)
- func (s *TeamStorage) CheckUserRoleById(userId int, role int) (exists bool, err error)
- func (s *TeamStorage) CreateTeam(teamName string, userId int) (teamId int, err error)
- func (s *TeamStorage) DeleteMemberFromTeam(userId int, teamId int) error
- func (s *TeamStorage) DeleteTeam(userId, teamId int) error
- func (s *TeamStorage) GetAllTeams() ([]domain.Team, error)
- func (s *TeamStorage) GetCountUserInTeam(teamId int) (count int, err error)
- func (s *TeamStorage) GetMembersTeam(teamId int) ([]domain.Member, error)
- func (s *TeamStorage) GetTeamByFilter(count int) ([]domain.Team, error)
- func (s *TeamStorage) GetTeamByUserId(userId int) (domain.Team, error)
- func (s *TeamStorage) GetTotalPointsByTeamId(teamId int) (totalPoints int, err error)
- func (s *TeamStorage) SetTeamID(userId int, teamID int) error
- func (s *TeamStorage) UpdateGiverPointsByTeamId(teamId, deltaPoints int) error
- func (s *TeamStorage) UpdateSpendPointsByTeamId(teamId, deltaPoints int) error
- func (s *TeamStorage) UpdateTeamName(userId int, teamName string) error
- type TextTaskStorage
- func (s *TextTaskStorage) CheckDayNewTask(teamId int) (bool, error)
- func (s *TextTaskStorage) CreateAnswerOnTextTask(task domain.TextTask) error
- func (s *TextTaskStorage) GetLastTextTask(teamId int) (domain.TextTask, error)
- func (s *TextTaskStorage) GetNewTextTask(teamId int) (domain.TextTask, error)
- func (s *TextTaskStorage) GetStatusLastTextTask(teamId int) (status bool, err error)
- func (s *TextTaskStorage) UpdateAnswerOnTextTask(task domain.TextTask) error
- type UserAuthStorage
- func (r *UserAuthStorage) ChangeUserPassword(userID string, newPassword string) error
- func (r *UserAuthStorage) ChangeUserProfile(userID string, profile *request.ChangeProfile) error
- func (r *UserAuthStorage) CheckUser(email string) (exists bool, err error)
- func (r *UserAuthStorage) CheckUserExist(userID string) (bool, error)
- func (r *UserAuthStorage) CreateUser(user request.Register) (userID string, err error)
- func (r *UserAuthStorage) GetUserID(email string) (userID string, err error)
- func (r *UserAuthStorage) GetUserPassword(email string) (password string, err error)
- func (r *UserAuthStorage) GetUserPasswordById(userID string) (password string, err error)
- func (r *UserAuthStorage) GetUserProfile(userID string) (*response.UserProfile, error)
- type UserStorage
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewMediaTaskStorage ¶
func NewMediaTaskStorage(dataSource string) (storage.MediaTaskStorage, error)
func NewSecStorage ¶
func NewSecStorage(dataSource string) (storage.SECStorage, error)
func NewTeamStorage ¶
func NewTeamStorage(dataSource string) (storage.TeamStorage, error)
func NewTextTaskStorage ¶
func NewTextTaskStorage(dataSource string) (storage.TextTaskStorage, error)
func NewUserAuthStorage ¶
func NewUserAuthStorage(dataSource string) (repository.IUserAuthStorage, error)
func NewUserStorage ¶
func NewUserStorage(dataSource string) (storage.UserStorage, error)
Types ¶
type MediaTaskStorage ¶
type MediaTaskStorage struct {
// contains filtered or unexported fields
}
func (*MediaTaskStorage) CheckAnswerOnMediaTaskById ¶
func (s *MediaTaskStorage) CheckAnswerOnMediaTaskById(answerMediaTaskId int, teamId int) (exist bool, err error)
func (*MediaTaskStorage) CreateAnswerOnMediaTask ¶
func (s *MediaTaskStorage) CreateAnswerOnMediaTask(teamId int, pointTaskId int) (id int, err error)
func (*MediaTaskStorage) GetAllAnswerOnMediaTasks ¶
func (s *MediaTaskStorage) GetAllAnswerOnMediaTasks() (tasks []domain.MediaTask, err error)
func (*MediaTaskStorage) GetAllMediaTaskByTeam ¶
func (s *MediaTaskStorage) GetAllMediaTaskByTeam(teamId int) (tasks []domain.MediaTask, err error)
func (*MediaTaskStorage) GetAnswerOnMediaTaskById ¶
func (s *MediaTaskStorage) GetAnswerOnMediaTaskById(answerMediaTaskId int) (task domain.MediaTask, err error)
func (*MediaTaskStorage) GetAnswersOnMediaTasksByFilter ¶
func (s *MediaTaskStorage) GetAnswersOnMediaTasksByFilter(status string) (tasks []domain.MediaTask, err error)
func (*MediaTaskStorage) GetDateAnswerOnMediaTaskById ¶
func (s *MediaTaskStorage) GetDateAnswerOnMediaTaskById(answerMediaTaskId int) (timeAnswer time.Time, err error)
func (*MediaTaskStorage) GetLastMediaTask ¶
func (s *MediaTaskStorage) GetLastMediaTask(teamId int) (task domain.MediaTask, err error)
func (*MediaTaskStorage) GetMediaTaskByTeamById ¶
func (*MediaTaskStorage) GetNewMediaTask ¶
func (s *MediaTaskStorage) GetNewMediaTask(teamId int) (task domain.MediaTask, err error)
func (*MediaTaskStorage) GetPointsOnMediaTask ¶
func (s *MediaTaskStorage) GetPointsOnMediaTask(mediaTaskId int) (points int, err error)
func (*MediaTaskStorage) GetStatusLastMediaTask ¶
func (s *MediaTaskStorage) GetStatusLastMediaTask(teamId int) (status string, err error)
func (*MediaTaskStorage) GetUpdateTimeAnswerOnMediaTask ¶
func (s *MediaTaskStorage) GetUpdateTimeAnswerOnMediaTask(taskId int) (time time.Time, err error)
func (*MediaTaskStorage) UpdateAnswerOnMediaTask ¶
func (s *MediaTaskStorage) UpdateAnswerOnMediaTask(taskId int, task domain.MediaAnswer) (err error)
func (*MediaTaskStorage) UpdatePointsOnMediaTask ¶
type SecStorage ¶
type SecStorage struct {
// contains filtered or unexported fields
}
func (*SecStorage) CheckIntersectionTimeInterval ¶
func (s *SecStorage) CheckIntersectionTimeInterval(masterClassId, teamId int) (bool, error)
func (*SecStorage) CheckMasterClassBusyPlaceById ¶
func (s *SecStorage) CheckMasterClassBusyPlaceById(masterClassId, teamId int) (int, error)
func (*SecStorage) CheckMasterClassIsExist ¶
func (s *SecStorage) CheckMasterClassIsExist(masterClassId int) (bool, error)
func (*SecStorage) CheckMasterClassTime ¶
func (s *SecStorage) CheckMasterClassTime(masterClass int) (bool, error)
func (*SecStorage) CheckRegisterOnMasterClass ¶
func (s *SecStorage) CheckRegisterOnMasterClass(masterClassId, teamId int) (bool, error)
func (*SecStorage) CheckRegisterOnSec ¶
func (s *SecStorage) CheckRegisterOnSec(secId, teamId int) (bool, error)
func (*SecStorage) CreateRegisterOnSEC ¶
func (s *SecStorage) CreateRegisterOnSEC(masterClassId, teamId int) error
func (*SecStorage) DeleteRegisterOnSEC ¶
func (s *SecStorage) DeleteRegisterOnSEC(masterClassId, teamId int) error
func (*SecStorage) GetMasterClassByID ¶
func (s *SecStorage) GetMasterClassByID(masterClassId int) (domain.Sec, error)
func (*SecStorage) GetSECAdmin ¶
func (s *SecStorage) GetSECAdmin() ([]domain.Sec, error)
func (*SecStorage) GetSECAdminById ¶
func (s *SecStorage) GetSECAdminById(secId int) ([]domain.Sec, error)
func (*SecStorage) GetSECByFilter ¶
func (s *SecStorage) GetSECByFilter() ([]domain.Sec, error)
func (*SecStorage) GetSecByID ¶
func (s *SecStorage) GetSecByID(secId int) ([]domain.Sec, error)
func (*SecStorage) GetSecByTeamId ¶
func (s *SecStorage) GetSecByTeamId(teamId int) ([]domain.Sec, error)
type TeamStorage ¶
type TeamStorage struct {
// contains filtered or unexported fields
}
func (*TeamStorage) AddMemberToTeam ¶
func (s *TeamStorage) AddMemberToTeam(userId int, teamId int) error
func (*TeamStorage) CheckTeam ¶
func (s *TeamStorage) CheckTeam(teamName string) (exists bool, err error)
func (*TeamStorage) CheckUserExistInTeam ¶
func (s *TeamStorage) CheckUserExistInTeam(userId, teamId int) (exist bool, err error)
func (*TeamStorage) CheckUserHasTeamByEmail ¶
func (s *TeamStorage) CheckUserHasTeamByEmail(email string) (exists bool, err error)
func (*TeamStorage) CheckUserHasTeamById ¶
func (s *TeamStorage) CheckUserHasTeamById(userId int) (exists bool, err error)
func (*TeamStorage) CheckUserIsExistByEmail ¶
func (s *TeamStorage) CheckUserIsExistByEmail(email string) (id int, err error)
func (*TeamStorage) CheckUserRoleById ¶
func (s *TeamStorage) CheckUserRoleById(userId int, role int) (exists bool, err error)
func (*TeamStorage) CreateTeam ¶
func (s *TeamStorage) CreateTeam(teamName string, userId int) (teamId int, err error)
func (*TeamStorage) DeleteMemberFromTeam ¶
func (s *TeamStorage) DeleteMemberFromTeam(userId int, teamId int) error
func (*TeamStorage) DeleteTeam ¶
func (s *TeamStorage) DeleteTeam(userId, teamId int) error
func (*TeamStorage) GetAllTeams ¶
func (s *TeamStorage) GetAllTeams() ([]domain.Team, error)
func (*TeamStorage) GetCountUserInTeam ¶
func (s *TeamStorage) GetCountUserInTeam(teamId int) (count int, err error)
func (*TeamStorage) GetMembersTeam ¶
func (s *TeamStorage) GetMembersTeam(teamId int) ([]domain.Member, error)
func (*TeamStorage) GetTeamByFilter ¶
func (s *TeamStorage) GetTeamByFilter(count int) ([]domain.Team, error)
func (*TeamStorage) GetTeamByUserId ¶
func (s *TeamStorage) GetTeamByUserId(userId int) (domain.Team, error)
func (*TeamStorage) GetTotalPointsByTeamId ¶
func (s *TeamStorage) GetTotalPointsByTeamId(teamId int) (totalPoints int, err error)
func (*TeamStorage) UpdateGiverPointsByTeamId ¶
func (s *TeamStorage) UpdateGiverPointsByTeamId(teamId, deltaPoints int) error
func (*TeamStorage) UpdateSpendPointsByTeamId ¶
func (s *TeamStorage) UpdateSpendPointsByTeamId(teamId, deltaPoints int) error
func (*TeamStorage) UpdateTeamName ¶
func (s *TeamStorage) UpdateTeamName(userId int, teamName string) error
type TextTaskStorage ¶
type TextTaskStorage struct {
// contains filtered or unexported fields
}
func (*TextTaskStorage) CheckDayNewTask ¶
func (s *TextTaskStorage) CheckDayNewTask(teamId int) (bool, error)
func (*TextTaskStorage) CreateAnswerOnTextTask ¶
func (s *TextTaskStorage) CreateAnswerOnTextTask(task domain.TextTask) error
func (*TextTaskStorage) GetLastTextTask ¶
func (s *TextTaskStorage) GetLastTextTask(teamId int) (domain.TextTask, error)
func (*TextTaskStorage) GetNewTextTask ¶
func (s *TextTaskStorage) GetNewTextTask(teamId int) (domain.TextTask, error)
func (*TextTaskStorage) GetStatusLastTextTask ¶
func (s *TextTaskStorage) GetStatusLastTextTask(teamId int) (status bool, err error)
func (*TextTaskStorage) UpdateAnswerOnTextTask ¶
func (s *TextTaskStorage) UpdateAnswerOnTextTask(task domain.TextTask) error
type UserAuthStorage ¶
type UserAuthStorage struct {
// contains filtered or unexported fields
}
func (*UserAuthStorage) ChangeUserPassword ¶
func (r *UserAuthStorage) ChangeUserPassword(userID string, newPassword string) error
func (*UserAuthStorage) ChangeUserProfile ¶
func (r *UserAuthStorage) ChangeUserProfile(userID string, profile *request.ChangeProfile) error
func (*UserAuthStorage) CheckUser ¶
func (r *UserAuthStorage) CheckUser(email string) (exists bool, err error)
func (*UserAuthStorage) CheckUserExist ¶
func (r *UserAuthStorage) CheckUserExist(userID string) (bool, error)
func (*UserAuthStorage) CreateUser ¶
func (r *UserAuthStorage) CreateUser(user request.Register) (userID string, err error)
func (*UserAuthStorage) GetUserID ¶
func (r *UserAuthStorage) GetUserID(email string) (userID string, err error)
func (*UserAuthStorage) GetUserPassword ¶
func (r *UserAuthStorage) GetUserPassword(email string) (password string, err error)
func (*UserAuthStorage) GetUserPasswordById ¶
func (r *UserAuthStorage) GetUserPasswordById(userID string) (password string, err error)
func (*UserAuthStorage) GetUserProfile ¶
func (r *UserAuthStorage) GetUserProfile(userID string) (*response.UserProfile, error)
type UserStorage ¶
type UserStorage struct {
// contains filtered or unexported fields
}
func (*UserStorage) GetAllUsers ¶
func (s *UserStorage) GetAllUsers() ([]domain.Member, error)
func (*UserStorage) GetUserById ¶
func (s *UserStorage) GetUserById(id int) (domain.Member, error)
func (*UserStorage) GetUserWithCountTeam ¶
func (s *UserStorage) GetUserWithCountTeam(count int) ([]domain.Member, error)
func (*UserStorage) GetUserWithoutTeam ¶
func (s *UserStorage) GetUserWithoutTeam() ([]domain.Member, error)
Click to show internal directories.
Click to hide internal directories.