-
Notifications
You must be signed in to change notification settings - Fork 55
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Description
Currently, room names are entered manually while booking, which can lead to inconsistencies and errors.
We need to introduce a dedicated rooms table/collection and use it to populate a dropdown in the booking UI.
Proposed Database Schema
Create a new table/collection:
Room {
room_id: String,
location: String,
allowed_roles: [String]
}Example
{
"room_id": "SCITECH_101",
"location": "SciTech Building, Floor 1",
"allowed_roles": [
"scitech_core",
"scitech_coordinator",
"gensec_scitech"
]
}- By default,
allowed_roles = ["all"] - Restricted rooms (e.g., SciTech rooms) will have limited access
Backend Requirements
- Create Room model/schema
- CRUD APIs for rooms (admin only)
- API to fetch available rooms based on user role
- Validate room access during booking
Frontend Requirements
- Replace text input with dropdown
- Fetch rooms from backend
- Show only rooms user is allowed to book
- Disable/Hide unauthorized rooms
Authorization Rules
-
Backend must verify:
- User role ∈ room.allowed_roles
-
Prevent bypass via API calls
Acceptance Criteria
- Rooms stored in dedicated DB collection
- Dropdown replaces manual input
- Role-based filtering works
- Unauthorized bookings are blocked
- Admins can manage rooms
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request