You are viewing limited content. For full access, please sign in.

Question

Question

Clear a field variable after submission

asked on November 2, 2020

I have a Interview participants form that once submitted, goes to a workflow to do some magic then gets reassigned to the initiator to fill it out again for round 2, 3 etc of interviews .   I have a drop down that they select what round of interviews it is.  What i would like to do is when this form gets reassigned to the initiator, reset that "Round" dropdown to blank since it is a required field.   If i leave it the way it is now, it retains the last value that was used which i do not want.  (Note: i do use the number from the "Round" in the name of the docs being saved to the repository)

0 1

Answer

SELECTED ANSWER
replied on November 2, 2020

Hi Marce,

 

You can use Javascript

//Document is ready
$(document).ready(function ()
	{
  		//Set select value to nothing
  		$('#q1 select').val(0);
	})

 

3 0
replied on November 5, 2020

Thanks Olivier!  this worked great!!  Now, if i also want to clear the " Question" multi-line field on that form what would i add  to the js? 

0 0
replied on November 13, 2020

add after line 5

$('#qx textarea').val(''); //Replace qx by your question's id

 

0 0
replied on February 28, 2022

Thanks for the JS Olivier.

Having tested this with LF Cloud though it appears as though despite JS capability slowly introduced, this particular functionality doesn't yet work in Cloud?

0 0
replied on May 10, 2022

Hi Duncan,

Sorry I don't know anything about the LF Cloud. Hope you find your answer.

1 0
replied on May 10, 2022

Hi Olivier. Yes we did get an answer - which is that you can now just set the 'File Upload' field to a value of nothing (empty) using Output Parameters in workflow, and that clears any file that had been previously uploaded.

It's new functionality that LF have introduced in a recent update.

1 0
replied on August 2, 2024

Hi Duncan, 

 

Could you elaborate on "set the 'File Upload' field to a value of nothing (empty) using Output Parameters in workflow"?

 

When I use the Set Business Variables activity in Workflow, I can't see the Attachment type in the "Choose Fields" pane. How did you do it?

I can see the Attachment type in the Retrieve Business Process Variables" activity, but not on the Set Business Process Variables. 

Thank you. 

0 0
replied on August 4, 2024 Show version history

Hi Patricia,

Sounds like you are working in Self-Hosted Laserfiche?

I should've been more clear, but my comments are related only to Cloud. In Cloud Workflow you use Input/Output tokens to set variables in processes, rather than the 'Retrieve Business Process Variables' and 'Set Business Process Variables' workflow activities (which don't exist in Cloud Workflow).

0 0

Replies

You are not allowed to reply in this post.
You are not allowed to follow up in this post.

Sign in to reply to this post.