Hello, we have a client who wants to update the information of their employees.
Their employees use a public format and do not have any laserfiche license, upload their data and add probatory documents.
Now they require that to update those data they can also visualize the documents uploaded to laserfiche beforehand.
As a first step we have made an almost empty form that executes a Workflow that exports the existing documents to pdf and makes them available for consultation by the employee; fill a table with the corresponding URL, use a search rule and show it in an html field to download.
I've been looking at the @ben-birns options for the spinner and onloadlookupfinished but they just did not cover my need.
What we intend is to use the first form to execute the workflow, redirect immediately to the second form, execute some kind of delay of approximately 20 seconds to allow time for the workflow to finish and then execute the way in which it will update the data and for that then the urls and the PDF files will be ready for our query.
Do you have any idea how to achieve it?
Any suggestions to achieve the same goal in a different way ?.
Question
Question
Delay a entire Form
Replies
Are you trying to redirect to a second form with the public/anonymous user who submitted the first form, or is it going to a licensed user?
If I'm understanding you correctly, I don't know if this is possible because I'm pretty sure you cannot assign a task (such as a second form in the same business process) to an anonymous user.
However, you could
- Create a "loading" screen with a custom HTML element on the form then set a hidden field and field rules that show the loading message and hide the fields when it is empty.
- Create a JavaScript function that repeats every 10, 20, or 30 seconds and fires the change event on the Lookup field until it detects a change in the hidden field's value.
- Create a "lookup complete" event for the Lookup field that checks for the desired results of the lookup and populates the hidden field to show the form, hide the loading screen, and end the looping process.
EDIT: Since you can't assign tasks to unlicensed users anyway, a better option might be to split it off into two Business Processes and just send the user a link when it is ready.
The first form would collect the initial information and trigger the workflow, the workflow would populate an external database then email a URL to the user once it is complete.
You could have Workflow build the URL to pre-populate a lookup field on the second form with some kind of unique identifier that would pull the data in from your database.
Thanks for the response
Yes, i try to send to another Business process, because is a public format , they don´t have license for this users.
BP A
Form almost empty form that executes a Workflow and redirect to BP B
BP B
Form with a delay,15-20 seconds to let the export and populate database workflow finish.
We did offer your third point , sending a email but the client didn´t accept
Although there are ways to do what you are asking, allowing unauthenticated/public forms submissions to directly update a database and/or download any file from the repository seems rather dangerous and insecure.
Not really, we use a Hash, password and validate vs database with a front end before the form. If the user dont pass the hash no one workflow can execute.
Please comment what ways you know to do what i am asking.