Hi,
we have requirement like on Button Click entire SAIL form(many fields) has to fill with some demo data. this will save a lot of time while giving the demo to client.
will it be possible to fill the data on click of a button?
Can you provide some thoughts on this, if possible some sample form.
We don't want to send the data from Process because we don't want to fill the form with default data.
Thanks in advance.
-Ram
Discussion posts and replies are publicly visible
There is no need to create the rule to return CDT value local variable in load created with type constructor should be fine. If say CDT is Employee, you can create local variable of type Employee like this: load( local!anEmployee: type!Employee( id: 123, name: abc, /*rest of CDT fields and values */ ) /*rest of the code */ )
Note: if CDT is not created, you can use the dictionary (adhoc structure). Even CDT is not a must. And then you can save it in rule variable when the button is clicked.
In actual implementation - 90% of the times the data comes from rule inputs which come from activity class parameters of the user input task in the process model. The additional rule creation step that you have mentioned is just returning you a CDT. Please go through the approach I have suggested, in my approach I am already specifying to use the rule input of type CDT/dictionary. It is just the source of inputs to the SAIL components which in real projects also comes from rule input variables (and not expression rules). Now those rule input variables are passed by the caller (which maybe a user input task, another parent expression rule/a parent SAIL interface etc.)
It's up-to the caller to decide what and how to pass the rule inputs (any of the above methods).
You never know in advance how it will be called in a real project implementation.
So - creating an expression rule for just returning a test CDT instance offers no advantage.