Questions and discussion about developing processes and programming in PHP, JavaScript, web services & REST API.

Moderator: amosbatto

Forum rules: Please search to see if a question has already asked before creating a new topic. Please don't post the same question in multiple forums.
#813681
Are you talking about the Panel control in Dynaforms?

If the content of your Panel is static, then create a trigger which assigns the content of the panel to a case variable like this:
Code: Select all
@@panelvariableID = "<h3><center>Acme Goods</center></h3>
<p>Product List:</p>
<ul><li>Roadrunner trap</li>
<li>Coyote bomb</li></ul>"; 
Set this trigger to fire at some point before the Output Document step in your process.

Then, edit the HTML code of your Output Document template and place this line in it:
Code: Select all
@#panelvariableID
If the content of your panel is dynamic, then you can add code to your DynaForm's submit event to save the content of the panel in a hidden variable which then can be used in your Output Document's template in the same way.
#814771
amosbatto wrote: Thu Mar 15, 2018 10:01 am If the content of your panel is dynamic, then you can add code to your DynaForm's submit event to save the content of the panel in a hidden variable which then can be used in your Output Document's template in the same way.
I'd like to make it dynamic, so that the users can make the necessary changes on the WYSIWYG dynaform themselves if I'm ever away. Can you please share the code for the trigger?
#814790
Works great with output doc, but any ideas how to have the variables be displayed on the panel as well? For e.g. @@CompanyName appears in panel and the output doc but not the company name itself when viewed on the web, is there any way for this to be dynamic from the WYSIWYG?

I have seen your response for: Dynaform Panel and PM Variables but it is hard-coded and not exactly what I'd like to achieve.

Regards
#814800
PipSqueak wrote:Works great with output doc, but any ideas how to have the variables be displayed on the panel as well? For e.g. @@CompanyName appears in panel and the output doc but not the company name itself when viewed on the web, is there any way for this to be dynamic from the WYSIWYG?
Let's say that you have a text field associated with the variable "companyName" in Form1.
Then, in Form2, create a hidden field associated with the variable "companyName". Then add the following JavaScript to Form2 to copy the hidden value of "companyName" to a panel with the ID "showCompany":
Code: Select all
var company = $("#companyName").getValue();
$("#productListPanel").find("div.panel-body").html(company);
Attached is a process that shows how to do this:
(31.82 KiB) Downloaded 8 times

Thanks Amos, it kinda of worked. But the API respo[…]

Data table in the panel

Create a hidden field associated with the variab[…]

Timo, that code has been moved to: workflow/engine[…]

routeCase SOAP API error

There is no web service function to get all the va[…]