domain: client
language: javascript
class Item class
Use the set_order_by
method to define and store internally the order_by
option that will be used by the
open
method, when its own order_by
option is not specified. The
open
method clears internally stored parameter value.
The field_list
parameter is a list of field names. If there is a sign ‘-‘
before a field name, then on this field records will be sorted in decreasing
order.
The result of the execution of following code snippets wil be the same:
item.open({order_by: ['-invoicedate']});
item.set_order_by(['-invoicedate']);
item.open();