Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

API now has a "document store" class bean #65

Merged

Conversation

DJWalker42
Copy link
Contributor

I have created a "ProposalDocumentStore" class bean. This can create the necessary store path locations, save and delete files, write a string to a file, list files in a given directory, and copy one directory to another. This is used internally only i.e., there is no client exposure.

Using this new class, the API can now copy the supporting document and justification files when cloning a proposal.

Noticed that I have changed the 'uploadSupportingDocument' implementation such that it either adds a new supporting document OR it overwrites an existing file if the file-upload filename matches an existing file in the Store. This was prompted by the need to simplify the location where the supporting document files are stored that in turn made the cloning of proposals easier. Instead of saving supporting document files to individual subdirectories using their DB id, they are more simply stored directly in the "supportingDocuments" subdirectory of the store. As a consequence, the "replace" supporting document api call is now obsolete so I have removed it.

… and justifications, change config property to 'document-store.root', works but needs to be able to copy files on proposal clone.
…hs to the correct location in the store, change config property name to document-store.proposals.root
@DJWalker42 DJWalker42 linked an issue Dec 5, 2024 that may be closed by this pull request
Copy link

github-actions bot commented Dec 5, 2024

Test Results

34 tests  ±0   34 ✅ ±0   7s ⏱️ -1s
12 suites ±0    0 💤 ±0 
12 files   ±0    0 ❌ ±0 

Results for commit 663c53e. ± Comparison against base commit 7ff70d6.

@AllanEngland AllanEngland merged commit c6014cb into master Dec 6, 2024
2 checks passed
@AllanEngland AllanEngland deleted the 63-java-class-or-classes-needed-for-document-store branch December 6, 2024 16:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Java Class or classes needed for document store
2 participants