I'm trying to configure a modal lookup window by following Example 2 in this academy page https://academy.creatio.com/documents/technic-sdk/7-15/creating-detail-selection-lookup and everything works as described, but I cannot figure out how to add a default sort to the modal lookup window - are there some parameters which can be added to the config object passed to the this.openLookup method call?
While on that subject, are there any other potential parameters which can be added to this config object which might be useful for other tasks?
Like
Dear Harvey,
There is no description for all parameters of the lookup config. The possible way is to check the existing openLookup calls.
Sorting can be specified in sortedColumns parameter.
You can find the example in method selectPeriod in the ForecastTab.
Collection of columns with sorting parameters is passed to it this way:
var config = {
entitySchemaName: "Contact",
multiSelect: false,
columns: ["Name", "Account.Name"],
sortedColumns: [{
name: "Account.Name",
orderPosition: 0,
orderDirection: this.Terrasoft.core.enums.OrderDirection.ASC
}]
};
this.openLookup(config, this.lookupCallback, this);
Kind regards,
Roman