Skip to content

Conversation

Vriti62
Copy link
Contributor

@Vriti62 Vriti62 commented Aug 29, 2025

Closes: #1195
Parent issue: #1180

Project Published URL 🔗

N/A (Backend implementation only) >

Describe the add-ons or changes you've made 📃

  • Implemented a backend endpoint to delete a saved project from a user’s collection.
  • Endpoint verifies:
    • The user exists (req.user from auth middleware).
    • The project exists in the given collection before deletion.
  • Deletes the document from the Collection model

Screenshots 📷

image fig: successful deletion of project in collection

Type of change ☑️

What sort of change have you made:

  • [x ] New feature
  • [x ] Database update

Note to reviewers 📄

This is part of the Saved Projects Feature with Sorting Options .

  • Tested using Postman with sample collection and project IDs.

Always open to any suggestions or feedbacks!!

Copy link

vercel bot commented Aug 29, 2025

@Vriti62 is attempting to deploy a commit to the avdheshvarshney's projects Team on Vercel.

A member of the Team first needs to authorize it.

Copy link

netlify bot commented Aug 29, 2025

Deploy Preview for code-a2z canceled.

Name Link
🔨 Latest commit 4008112
🔍 Latest deploy log https://app.netlify.com/projects/code-a2z/deploys/68b16d34d02f0c000873cf89

Copy link

Thank you for submitting your pull request! We'll review it as soon as possible. For further communication, join our discord server https://discord.gg/tSqtvHUJzE.

@Avdhesh-Varshney Avdhesh-Varshney linked an issue Aug 30, 2025 that may be closed by this pull request
const userID = req.user;
const collectionID = req.params.cid;
const projectID = req.params.project_id;
console.log(userID , projectID, collectionID);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove logs

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay sir! will edit the same.

This comment was marked as resolved.

@Avdhesh-Varshney
Copy link
Member

@Vriti62 Need your updates and also resolve conflicts

@Vriti62 Vriti62 force-pushed the feature/backend/delete-saved-projects branch from 4008112 to 0047bec Compare September 8, 2025 20:39
@Vriti62
Copy link
Contributor Author

Vriti62 commented Sep 8, 2025

hey!
ive just updated and committed the code in my branch in this pull request, also updates the screenshot in the description !
And the conflicts are resolved!
Please let me know for any more changes or if i should start with my next endpoints!

@Vriti62 Vriti62 force-pushed the feature/backend/delete-saved-projects branch from 8a024da to 8c77b5f Compare September 16, 2025 17:23
const userID = req.user;
const collectionID = req.params.cid;
const projectID = req.params.project_id;
console.log(userID , projectID, collectionID);

This comment was marked as resolved.

@Avdhesh-Varshney Avdhesh-Varshney merged commit 23602c9 into Code-A2Z:main Sep 17, 2025
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Backend : Delete Entire Collection with Projects Backend: Create Remove Saved Project Endpoint

2 participants