orderBy method

QueryBuilder orderBy(
  1. String column, [
  2. String direction = 'ASC'
])

Add an "order by" clause to the query.

Implementation

QueryBuilder orderBy(String column, [String direction = 'ASC']) {
  if (_orderBy == '') {
    _orderBy = '$column $direction';
  } else {
    _orderBy = '$_orderBy, $column $direction';
  }
  return this;
}