The table of customer subscriptions loaded at the start of the flow consists of the following, hardcoded columns.
The list of columns to display and its order is driven by the apex class "Get Subscriptions Table Columns"
How to configure your subscription table columns
In Limio release v12.29, a no-code tool became available to our users. It allows to modify a set of columns, reorder and relabel them, learn more about it in No-code tool to customise Customer Subscriptions table columns
More complex customisation might still require some Apex. Get Subscriptions Table Columns in the flow can be replaced with a custom apex class to return an updated set of columns. The output generated by the new class must be of the following type:
List<i42as.DatatableColumn>
where i42as is the namespace for Limio for Salesforce. The DatatableColumn apex class is a global class with the following properties
The first constructor is a pair column label-column name, formatted as generic string.
The second constructor allows to pass columns with specific formatting, such as date and currency.
All possible fields that can be selected as columns map to the properties of the SubscriptionRefined Apex class.
Build your own columns
Below is an example that returns the list of columns currently displayed
List<i42as.DatatableColumn> columns = new List<i42as.DatatableColumn>();
columns.add(new i42as.DatatableColumn('Name', 'subscriptionName'));
columns.add(new i42as.DatatableColumn('Status', 'status'));
columns.add(new i42as.DatatableColumn('Offer', 'offerName'));
columns.add(new i42as.DatatableColumn('Start Date', 'startDate', 'date'));
columns.add(new i42as.DatatableColumn('End Date', 'endDate', 'date'));
columns.add(new i42as.DatatableColumn('Latest Schedule Date', 'billingPeriodStart', 'date'));
columns.add(new i42as.DatatableColumn('Latest Charge', 'latestCharge', 'currency'));
columns.add(new i42as.DatatableColumn('Next Schedule Date', 'billingPeriodEnd', 'date'));
columns.add(new i42as.DatatableColumn('Next Charge','nextCharge', 'currency'));
columns.add(new i42as.DatatableColumn('action'));
return new List<List<i42as.DatatableColumn>>{ columns };
NOTE: if implemented as a Salesforce flow @InvocableMethod, the return type must be of type
The generated output can be stored on the Table_Columns variable of the flow, that is of the same type.
Tips
- for properties of type List<String> (offerAllowedCountries, offerProducts) use type "arrayToString"
- for offerTerm - use type "nestedObjectProperty"
Examples:
new i42as.DatatableColumn('Renewal Term Type', 'offerTerm', 'nestedObjectProperty');
new i42as.DatatableColumn('Products', 'offerProducts', 'arrayToString');
Comments
0 comments
Please sign in to leave a comment.