upes-open / OSoC-24-BizSync

GNU Affero General Public License v3.0
1 stars 12 forks source link

Staff Management API #22

Closed akshit-bhutani-19 closed 2 months ago

akshit-bhutani-19 commented 3 months ago

Develop the backend API for Staff Management, including endpoints for retrieving, adding, and updating staff details.

Requirements:

GET /api/staff: Retrieve a list of all staff members. POST /api/staff: Add a new staff member. PUT /api/staff/:id: Update an existing staff member.

Database Schema:

Staff Member: name (String) position (String) contactInfo (Object) : email (String) and phone (String) status (String) roles (Array of Strings)

Perform unit testing using Postman

shradiphylleia commented 2 months ago

pls assign

rampantvoid commented 2 months ago

@Akki019 can you assign me this

rampantvoid commented 2 months ago

@Akki019 have made the apis, if you can assign me, ill raise a pr asap

rampantvoid commented 2 months ago

@Akki019 have raise pr, also accounted for the staffs being unique to each user, modiefied the existing schema by adding user: { type:Schemas.Types.ObjectId, ref:"User" }