Hello,
I have set FALSE IN the property required in a file upload widget but when I run the process and let the widget empty I get the next error:
INFORMACIÓN: org.restlet.Component.BonitaRestletApplication Error while validating expected inputs
Explanations:
{} cannot be assigned to FILE
I have found that I need to put null in the definition of the json variable. When I press the submit button apparently the form is submitted but the process do not continue to the next actor and I cannot do anything else because the process seems to be in a kind of limbo.
Please, can you help me with that.?
Thanks in advance.
Regards
Geovanny C.
In your return function you need to specify an if statement something as follows:
return { fileUploaded(filename); }
function fileUploaded(filename){
if (filename!==null){ return filename }
else{return null}
}
regards
Seán
PS: As this reply answers your question, please mark as resolved by ticking the tick mark on the left of this reply.
Thanks for your response Sean.
I got the idea but I don´t know how to implement it in my task.
The forminput variable of my task have the next information (JSON):
{ "registrarCeseFuncionesInput" : { "informeValidado" : false, "regresarA" : "Seleccione una opción" }, "informeRecursosHumanosDocumentInput" : { } }
where informeRecursosHumanosDocumentInput is the variable of the document.
The formouput variable of my task have the next information (JavaScript Expression)
return { 'registrarCeseFuncionesInput': $data.formInput.registrarCeseFuncionesInput, 'informeRecursosHumanosDocumentInput': $data.formInput.informeRecursosHumanosDocumentInput };
and this is my form:
How could I implement your code in my variables?
Thanks in advance.
Regards.
Geovanny C.