async list(params = { filters: {} }) {
    const { filters } = params;
    try {
      let results = [];
      await this.prepare("records", store => {
        createListRequest(this.cid, store, filters, _results => {
          // we have received all requested records that match the filters,
          // we now park them within current scope and hide the `_cid` attribute.
          results = _results.map(r => omitKeys(r, ["_cid"]));
        });
      });
      // The resulting list of records is sorted.
      // XXX: with some efforts, this could be fully implemented using IDB API.
      return params.order ? sortObjects(params.order, results) : results;
    } catch (e) {
      this._handleError("list", e);
    }
  }
/**
   * Lists all records from the IndexedDB database.
   *
   * @override
   * @param  {Object} params  The filters and order to apply to the results.
   * @return {Promise}
   */
Lists all records from the IndexedDB database.
@override
@param  {Object} params  The filters and order to apply to the results.
@return {Promise}
Lists all records from the IndexedDB database . @override @param { Object } params The filters and order to apply to the results . @return { Promise }
async list(params = { filters: {} }) {
    const { filters } = params;
    try {
      let results = [];
      await this.prepare("records", store => {
        createListRequest(this.cid, store, filters, _results => {
          results = _results.map(r => omitKeys(r, ["_cid"]));
        });
      });
      return params.order ? sortObjects(params.order, results) : results;
    } catch (e) {
      this._handleError("list", e);
    }
  }
async list ( params = { filters : { } } ) { const { filters } = params ; try { let results = [ ] ; await this . prepare ( "records" , store => { createListRequest ( this . cid , store , filters , _results => { results = _results . map ( r => omitKeys ( r , [ "_cid" ] ) ) ; } ) ; } ) ; return params . order ? sortObjects ( params . order , results ) : results ; } catch ( e ) { this . _handleError ( "list" , e ) ; } }
Lists all records from the IndexedDB database.
Lists all records from the IndexedDB database .
// we have received all requested records that match the filters, // we now park them within current scope and hide the `_cid` attribute. // The resulting list of records is sorted. // XXX: with some efforts, this could be fully implemented using IDB API.