src/js/pagination/paging-collection.js
function(fieldName, toggleDirection) {
                var direction = toggleDirection ? 0 - this.state.order : this.state.order;
                if (fieldName !== this.state.sortKey || toggleDirection) {
                    this.setSorting(fieldName, direction);
                    this.isStale = true;
                }
            }
function(fieldName, toggleDirection) {
                var direction = toggleDirection ? 0 - this.state.order : this.state.order;
                if (fieldName !== this.state.sortKey || toggleDirection) {
                    this.setSorting(fieldName, direction);
                    this.isStale = true;
                }
            }
function ( fieldName , toggleDirection ) { var direction = toggleDirection ? 0 - this . state . order : this . state . order ; if ( fieldName !== this . state . sortKey || toggleDirection ) { this . setSorting ( fieldName , direction ) ; this . isStale = true ; } }
Sets the field to sort on and marks the collection as
stale.

@param fieldName {string} name of the field to sort on
@param toggleDirection {boolean} if true, the sort direction is
toggled if the given field was already set
Sets the field to sort on and marks the collection as stale .