Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- “Student”
- Create “Student”
- Users can create new students. Students have an ID, name, age, active.
- “active” determines if the student is active or not (shows up in listings).
- IDs are unique among students.
- Read “Student”
- Users can show the details of existing students by entering their ID.
- All “Application” of student shows up here.
- Read “Students”
- Users can list the IDs and names of all students in the system.
- Update “Student”
- Users can update the details of existing students by first entering their ID and then the information (name, age) to be updated.
- IDs cannot be updated.
- Activate/Deactivate “Student”
- Users can activate/deactivate students by entering their ID.
- Delete “Student”
- Users can delete existing students by entering their ID.
- Students cannot be deleted if they have an existing “Application”.
- ---------------------------------------------------------------------------------------------------------------------------
- “Company”
- Create “Company”
- Users can create new companies. Companies have an ID, name.
- IDs and names of companies are unique amongst other companies.
- Read “Company”
- Users can show the details of existing companies by entering their ID.
- All “Position” of a company shows up here.
- Read “Companies”
- Users can list the IDs and names of all companies in the system.
- Update “Company”
- Users can update the details of existing companies by first entering their ID and then the information (name) to be updated.
- IDs cannot be updated.
- Company names can be updated, but they should stay unique.
- Delete “Company”
- Users can delete existing companies by entering their ID.
- Companies cannot be deleted if they have an existing “Position”.
- ---------------------------------------------------------------------------------------------------------------------------
- “Position”
- Create “Position”
- Users can create new positions. A position has an ID, description, number of seats and a “Company ID”.
- Position IDs are unique amongst other positions.
- Descriptions cannot be empty.
- The number of seats must be greater than 0.
- Company ID must exist.
- Read “Position”
- Users can show the details of existing positions by entering their ID.
- “Students” already applied are shown here.
- Read “Positions”
- Users can list existing positions. All attributes of a position are visible plus it’s displayed how many seats are already taken (e.g 2/1, one out of two seats are taken).
- Update “Position”
- Users can update the details of existing positions by first entering their ID and then the information needs to be updated.
- Only the description can be updated, nothing else.
- Delete “Position”
- Users can delete existing positions by entering their ID.
- Positions cannot be deleted if they have an existing “Application”.
- ---------------------------------------------------------------------------------------------------------------------------
- “Application”
- Create “Application”
- Users can create new applications. An application has an ID, an “accepted” field, a “Student ID” and a “Position ID”.
- IDs are unique amongst other applications.
- Student and Position IDs must exist.
- The “accepted” field stores whether the application was accepted by a company or not.
- Update “Application”
- Users can update existing applications by entering their ID.
- Only the “accepted” status can be changed.
- Delete “Application”
- Users can delete existing applications by entering their IDs.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement