Commit graph

12 commits

Author SHA1 Message Date
smavros
02f2156c1e Changes response of POST,PUT and DELETE:
For being able to easily debug and test the checkpoints which are
    adding, modifying or deleting a user the response should be the
    affected user object. Not only its ID.
2019-08-18 17:17:16 +02:00
smavros
c2429394ed Renames VisitorAuthenticate() to RegisterAuthenticate() 2019-08-15 14:52:19 +02:00
smavros
8ce554b6d7 Modifies user/ endpoint:
Functions `addUser()`, `updateUser()` and `deleteUser()` now return
    a body of `{ "id": $userID }`.
2019-08-15 14:34:35 +02:00
smavros
7529f4803f Improves PUT /user/$ID {$updatedUser} endpoint:
- Improves the semantics and scope of the updatedUser() by moving
    operations in updateUserRequest's updatedUser() method.
    - Fixes the marshaling of the updateUserRequest by renaming and
    embedding the already existing type.
    - Fixes bug of password hashing by using `omitempty` tags in the
    update struct.
2019-08-15 00:36:03 +02:00
smavros
74b27f7525 Remove redundant structs and methods:
UserSerializer, UsersSerializer, AuthResponse, UserResponse.
2019-08-13 16:40:54 +02:00
smavros
42f473cde0 Fix bug of User marshaling:
Instead of using the json.Marshal() we can user `gin.H` type of the
    response that will be passed through an XMLMarshaler. In that case
    we don't even need the responses structs!!
2019-08-13 16:20:58 +02:00
smavros
28d81e52c2 Derpecates UsersSerializer() from user endpoints 2019-08-13 16:17:37 +02:00
smavros
50b1902bf3 Deprecates common.UserSerializer() from user endpoints 2019-08-13 15:49:33 +02:00
smavros
e6c8fff397 Merge remote-tracking branch 'origin/master' into user-validators 2019-07-26 15:29:45 +02:00
Sonja Happ
e9ed836ba3 fix typo in registration of user endpoints 2019-07-23 17:19:42 +02:00
Sonja Happ
9faec2e805 return user in auth response 2019-07-18 15:25:06 +02:00
Sonja Happ
f0be5cce00 file renaming 2019-07-18 13:25:41 +02:00
Renamed from routes/user/userEndpoints.go (Browse further)