Pricefx Classic UI is no longer supported. It has been replaced by Pricefx Unity UI.

 

RAT Groovy API

Rebate Agreement Templates use a Groovy logic to construct rebate agreements with a builder-like API. (The same pattern as for charts, headers etc.). You "chain" your requirements for a rebate agreement and then call the build method at the end. The logic is defined in the Configuration.

Most used methods and objects:

  • "ROOT" – ID for the root line item, the rebate agreement itself.
  • ratBuilder – Groovy binding which is available in the template context.
    • fromParams(params) – Creates a new rebate agreement with parameters, available parameters are: label, startDate, endDate.
    • addOrUpdateInput(lineId, params) – Adds/updates the input.
    • addLineItemWithId(lineId, type) – Adds a new line item to the rebate agreement, specified with the string type – rebate type unique name.
    • build() – Build function which has to be called after all requested modifications.



Found an issue in documentation? Write to us.

Â