feat: fully implement profile controller;
feat: implement file upload handling in controller with size and type validation; feat: add custom validation rules for bio and color hex fields; refactor: enhance request handling with dedicated client info extraction; chore: update profile DTOs with validation tags; docs: profile controller swagger
This commit is contained in:
@@ -31,7 +31,7 @@ type ProfileService interface {
|
||||
UpdateProfile(cinfo dto.ClientInfo, newProfile dto.ProfileDto) (bool, error)
|
||||
GetProfileSettings(cinfo dto.ClientInfo) (dto.ProfileSettingsDto, error)
|
||||
UpdateProfileSettings(cinfo dto.ClientInfo, newProfileSettings dto.ProfileSettingsDto) (bool, error)
|
||||
UploadAvatar(cinfo dto.ClientInfo, filePath string)
|
||||
UploadAvatar(cinfo dto.ClientInfo, filePath string) (string, error)
|
||||
}
|
||||
|
||||
type profileServiceImpl struct {
|
||||
@@ -64,6 +64,6 @@ func (p *profileServiceImpl) UpdateProfileSettings(cinfo dto.ClientInfo, newProf
|
||||
panic("unimplemented")
|
||||
}
|
||||
|
||||
func (p *profileServiceImpl) UploadAvatar(cinfo dto.ClientInfo, filePath string) {
|
||||
func (p *profileServiceImpl) UploadAvatar(cinfo dto.ClientInfo, filePath string) (string, error) {
|
||||
panic("unimplemented")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user