Refactor: Remove Dummy Data and Use Actual Backend Data#5
Open
zaibamachhaliya wants to merge 1 commit into
Open
Refactor: Remove Dummy Data and Use Actual Backend Data#5zaibamachhaliya wants to merge 1 commit into
zaibamachhaliya wants to merge 1 commit into
Conversation
- Added api.ts service for backend API calls - Updated Analytics.tsx to fetch real data from backend - Updated MyFiles.tsx with backend integration - Removed all localStorage dummy data - Added file management routes (GET, DELETE, bulk-delete) - Added File model and controller - Added .env.example for environment setup - Fixed Cloudinary upload integration Closes imanchalsingh#1
👷 Deploy request for file-sharingsystem pending review.Visit the deploys page to approve it
|
|
@zaibamachhaliya is attempting to deploy a commit to the imanchalsingh Team on Vercel. A member of the Team first needs to authorize it. |
Owner
|
Thank you for contribution ✨ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR fixes Issue #1 - Removes all dummy data and connects the UI with real backend APIs.
What Changed?
Frontend:
api.ts- Central file for all backend API callsAnalytics.tsx- Now shows real data from databaseMyFiles.tsx- File upload, share, delete now work with backendBackend:
File.jsmodel - Stores file info in MongoDBfileController.js- Handles file operationsfiles.jsroutes - New API endpoints for filesNew APIs Added:
GET /api/files/my-files- Get user filesDELETE /api/files/:id- Delete one fileDELETE /api/files/bulk-delete- Delete multiple filesResult:
Closes #1