Skip to content

[TASK] Add createdAt Field to FriendRequest Object as LocalDateTime #339

@walidoow

Description

@walidoow

Issue Summary

The frontend team requires a createdAt timestamp field and "profilePictureURL" for the friendRequest object to calculate the time elapsed since an invitation was sent.

Task Description

  • Add a createdAt field to the friendRequest object in the backend. This field should be a LocalDateTime indicating when the friend request was created.
  • Add a profilePictureURL to the friendRequest object in the backend. This field should be a string indicating the url of the sender's profile picture.

Current Object Structure

{
    "friendRequestUsername": "string",
    "friendRequestUserId": "string",
    "status": "SENT",
    "requestId": "string"
}

Updated Object Structure

{
    "friendRequestUsername": "string",
    "friendRequestUserId": "string",
    "status": "SENT",
    "requestId": "string",
    "createdAt": "LocalDateTime" // Example: "2023-10-05T14:48:00"
    "profilePictureURL" : "string"
}

Acceptance Criteria

  • Add a createdAt field to the friendRequest object as a LocalDateTime.
  • Add a profilePictureURL field to the friendRequest object as a string.
  • Populate createdAt upon creation of the friend request.
  • Populate profilePictureURL upon creation of the friend request.
  • Ensure data consistency and backward compatibility.

Notes

  • Use the appropriate format for LocalDateTime.
  • Coordinate with the frontend team to ensure they can access and use the new field appropriately.

Metadata

Metadata

Labels

backendBackend related, server side
No fields configured for Feature.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions