Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Realm Connection - Update Schemas to Mirror Database #31

Open
xavjones8 opened this issue Mar 26, 2024 · 0 comments
Open

Realm Connection - Update Schemas to Mirror Database #31

xavjones8 opened this issue Mar 26, 2024 · 0 comments
Labels

Comments

@xavjones8
Copy link
Member

Acceptance Criteria:

  1. For each model we have, refactor the class name to have Display added to the end (eg. SchoolDisplay). Be sure to use Android Studio Rename Refactoring to rename all variables in the project.
    We want to do this so that we can play with the database schemas without affecting the front-end.
    Example:
data class ClubDisplay(
    var _id: UUID = UUID.randomUUID(),
    var color: Long = 0,
    var events: List<EventDTO> = listOf<EventDisplay>(),
    var fullName: String = "",
    var imageUrl: String = "",
    var members: List<UserDTO> = listOf<UserDisplay>(),
    var posts: List<PostDTO> = listOf<PostDisplay>(),
    var school: SchoolDTO? = null,
    var shortName: String = ""
)
  1. Next, add a new class for each model in the database, using the schema MongoDB provides like so:
    Screenshot 2024-03-26 at 1 10 26 PM.
  2. Be sure the app runs, and check through existing compostables to ensure no degradation in function.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant