Documentation
¶
Index ¶
- func NewSessionPostgresqlRepository(db *sql.DB) user.Repository
- type PostgresqlRepository
- func (r *PostgresqlRepository) AddProfile(user *models.ProfileUser) (uint64, error)
- func (r *PostgresqlRepository) SelectProfileById(userId uint64) (*models.ProfileUser, error)
- func (r *PostgresqlRepository) UpdateAvatar(userId uint64, avatarUrl string) error
- func (r *PostgresqlRepository) UpdateProfile(userId uint64, user *models.UpdateUser) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewSessionPostgresqlRepository ¶
func NewSessionPostgresqlRepository(db *sql.DB) user.Repository
Types ¶
type PostgresqlRepository ¶
type PostgresqlRepository struct {
// contains filtered or unexported fields
}
func (*PostgresqlRepository) AddProfile ¶
func (r *PostgresqlRepository) AddProfile(user *models.ProfileUser) (uint64, error)
Add new user profile
func (*PostgresqlRepository) SelectProfileById ¶
func (r *PostgresqlRepository) SelectProfileById(userId uint64) (*models.ProfileUser, error)
Select one profile by id
func (*PostgresqlRepository) UpdateAvatar ¶
func (r *PostgresqlRepository) UpdateAvatar(userId uint64, avatarUrl string) error
Update user avatar
func (*PostgresqlRepository) UpdateProfile ¶
func (r *PostgresqlRepository) UpdateProfile(userId uint64, user *models.UpdateUser) error
Update info in user profile
Click to show internal directories.
Click to hide internal directories.