We are in need of a way to attach or link to an existing document in Laserfiche from within a Laserfiche Form. If the file uploader could have an option to select from a repository even as a link that would be helpful. Currently the document up loader only supports attaching documents from local file
Question
Question
Forms - Attach or Reference an existing document in Laserfiche from Forms
Replies
Hi there,
Thanks for your feature request, can you tell us more about your use case so that we can have a better understanding of the feature request? What does the business process look like, what are the documents being used for?
The use case is something that has a bunch of variations, I can provide one I have run into.
Say we have a refund request form. We want to have users that find a document or folder containing documents that require a refund to start a form and provide the document that has caused them to start this process. Currently, that means exporting the document or creating a document shortcut on your desktop and uploading that to the file upload in the form.
However, why duplicate information? It would instead be better to include a window where they can find and select a document from the repository to reference in the form. Additionally, if during an approval process, the selected document from the repository we able to be previewed in an iFrame or directly opened in the option of the LF Client or Web Access, that would allow for easier/quicker processing of such a request.
Kenneth,
I've done something similar where the use case was to choose a client and branch from the LF folder structure and then record notes from a telephone call. The LF workflow took the form and stored the resultant form directly to the client folder.
The folder structure was built using a Common Table Entity (CTE) query against the Laserfiche database to get a list of parent and child folders below a specified root folder. If your documents sit below a common root folder with not too many levels of folders to browse, it would be easy enough to make this documents instead of folders.
I initially built this with a web service running on the LF server (to run the CTE) called by an asynchronous AJAX call in the form, with JS populating a parent dropdown with a trigger to populate the child.
With 9.2 handling stored procedures properly, I've started rewriting this to use a stored procedure to run the CTE, returning a list of parent folder name/child folder name/child folder entry ID items. I'll drop this into a select field, then use JS to iterate through and populate the dropdowns as above so that there's no need for a web service. When the parent and child are chosen, a trigger populates a hidden field with the entry ID that can be used by the LF workflow (would be the entry ID of the document in your case).
hope this helps and give me a bell if you want the query...
Andrew.