Transaction Templates

Templates are generic objects in which you will be able to define multiple settings in order to automatize the behavior of your KB. Not only you will be able to customize the layout of your screens but also, you will be able to add event blocks, automatic rules, and automatic conditions. 

TemplatesTransactionTemplates_img01

The "Transaction templates" section contains at least one template for each generated object within the transaction:

  • Transaction
  • Selection
  • Prompt
  • Prompt Multiple
  • View,
  • Association
  • Association Selection.

The purpose of the Template node is to define a structure template that will be instantiated for some instance's transactions. When we create a new transaction and then apply WorkWithPlus pattern, the instance will be generated based on some of these templates.

As we can appreciate, the template definition has a very similar structure to a particular transaction's pattern instance. Many nodes are exactly the same as the ones presented in the transaction's pattern instances, but there are also generic nodes that represent general controls within the template. 

The Challenge

The customer needs that every transaction form shows the actions (confirm and cancel) at the top of the attributes instead of at the bottom of them.

As it is a massive modification, WorkWithPlus provides a mechanism for making this change just once and propagates the changes automatically: perform the change in the transaction template by cutting and pasting the "Action Group" containing the buttons inside "Table Main" and do the Update Instances in that template.

TemplatesTransactionTemplates_img02

Open any transaction and use the preview, in order to verify that the instance has been updated (you should visualize the buttons "Confirm" and "Cancel" at the top of the attributes).

Run the application and visualize the results at runtime.

Summary

Well done! You should now be able to:

  • Understand the importance of templates in order to automatize your KB
  • Customize a template
  • Apply the "Update Instance" process to propagate your customizations