As described in Updating a transaction after K2BTools has been applied, K2BEntityServices updates the transaction’s definition. When the developer wants to include custom code in the transaction (both in the Events and the Rules parts), the developer must work with the “Slots” defined by the pattern.
A “slot” is a code section that was created by the pattern to implement a specific feature or set of features. The section is delimited by comments, as shown below.
|Code slot example in events
Basically, a code slot starts with a comment with the form:
Where “<owner>” is the pattern that generated the slot, “<functionality>” is the name of the feature it implements.
The slot ends with a line containg this comment “//-”.
The postfix “.Fixed” may appear or not, depending on the slot. Slots that include the “Fixed” postfix are called “Fixed Slots”, while the rest are called “Non-Fixed Slots”.
|Non-fixed slot example in rules
||Fixed slot example in rules
The following rules must be followed by the developer:
- The developer can add code outside the slots.
- The developer can add or update code in “Non-Fixed slots”.
- The developer can NOT add add code in “Fixed slots”.