ucsb-cs184-f24 / team02-bathroom

MIT License
0 stars 1 forks source link

Setup Firestore #27

Closed Bravo-Luis closed 1 week ago

Bravo-Luis commented 1 week ago

Added

bathrooms & reviews collection + created firestoreManager

firestore schema as of now (we can add/unadd stuff)

Users Collection: Fields: authProvider: string fullName: string email: string createdAt: timestamp lastLoginAt: timestamp reviews: array of references to reviews

Bathrooms Collection: Fields: buildingName: string floor: string or integer location: geopoint (latitude and longitude) image: URL averageRating: number (optional, calculated based on reviews) totalReviews: integer (for rating purposes) createdAt: timestamp

Reviews Collection: Fields: bathroomId: reference to a document in the Bathrooms collection userId: reference to a document in the Users collection rating: number (e.g., 1–5) comment: string createdAt: timestamp