Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Add Support for Batch File Uploads #131

Open
6 tasks done
mahid797 opened this issue Dec 19, 2024 · 0 comments
Open
6 tasks done

Add Support for Batch File Uploads #131

mahid797 opened this issue Dec 19, 2024 · 0 comments
Assignees
Labels
Backend Backend Related Issue 🛠️Backlog Low-priority tasks that may be worked on in the future but not essential
Milestone

Comments

@mahid797
Copy link
Collaborator

mahid797 commented Dec 19, 2024

Update the existing file upload API to support batch uploads. The API should allow multiple files to be uploaded in a single request, with appropriate validation and error handling for individual files in the batch. Additionally, integrate the updated Upload Modal frontend with the backend to ensure seamless functionality.


Tasks

  • Modify the existing file upload API (/api/documents/upload) to handle multiple files in one request.
  • Update validation logic to:
    • Ensure each file meets the allowed formats and size limits.
    • Return specific error messages for invalid files while continuing to process valid ones.
  • Save metadata for each uploaded file to the database.
  • Add logic to rollback or clean up partial uploads if the batch processing fails.
  • Ensure proper error handling and logging for batch uploads.
  • New Task: Integrate the updated Upload Modal with the backend:
    • Ensure the modal triggers the batch upload API correctly.
    • Update the modal to display server-side errors (e.g., invalid files, upload failures) as toasts or in the UI.
    • Show a success message upon completion of the upload process.
    • Validate that all uploaded files appear in the document list on successful submission.

Notes

  • This API must be backward compatible with single-file uploads.
  • Review the related issue (Update File Upload Modal #132) to better understand requirements and align the backend functionality accordingly.
  • [Update]: The Upload Modal Issue Update File Upload Modal #132 has been reviewed and merged into the master branch via PR feat/new upload modal #129. Ensure that the updated Upload Modal aligns with the API and functionality.
  • [Update]: If certain functionalities\UI are too complex or time-consuming to implement, they should be skipped due to the approaching deadline.
@mahid797 mahid797 added New Feature New feature to be implemented Backend Backend Related Issue labels Dec 19, 2024
@mahid797 mahid797 added this to the 1.0 milestone Dec 19, 2024
@mahid797 mahid797 mentioned this issue Dec 19, 2024
7 tasks
@mahid797 mahid797 changed the title Add Support for Batch File Uploads in Backend API Add Support for Batch File Uploads Dec 19, 2024
@mahid797 mahid797 linked a pull request Jan 15, 2025 that will close this issue
@mahid797 mahid797 removed the New Feature New feature to be implemented label Jan 16, 2025
@mahid797 mahid797 modified the milestones: v0.1.0-alpha, v0.1 Feb 18, 2025
@mahid797 mahid797 added the 🛠️Backlog Low-priority tasks that may be worked on in the future but not essential label Feb 22, 2025
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Backend Backend Related Issue 🛠️Backlog Low-priority tasks that may be worked on in the future but not essential
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants