Added document upload feature (frontend + backend integration) - #26
Open
Raghavjha60570 wants to merge 2 commits into
Open
Added document upload feature (frontend + backend integration)#26Raghavjha60570 wants to merge 2 commits into
Raghavjha60570 wants to merge 2 commits into
Conversation
Owner
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 pull request implements the feature requested in issue #5, allowing users to upload documents directly from the dashboard. The uploaded documents are stored securely on the server and can be accessed within the workspace or project view.
##Changes Made
Added a new component DocumentUploader.jsx to handle document upload from the frontend.
Integrated the upload functionality in Dashboard.jsx.
Implemented a new backend API route /api/upload-document using multer for handling file uploads.
Configured server-side validation to allow only PDF, DOC, DOCX, and TXT files with a size limit of 10MB.
Created the directory structure uploads/documents for storing uploaded files.
##How to Test
Start both backend and frontend servers.
Navigate to the Dashboard page.
Click on the Upload Document button.
Select a document file (PDF/DOC/DOCX/TXT).
Confirm that the upload completes successfully and the file appears in the uploads/documents directory.
Related Issue
fixed #5