electrodb 2.2.5 → 2.2.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/entity.js +5 -1
package/package.json
CHANGED
package/src/entity.js
CHANGED
|
@@ -54,7 +54,7 @@ class Entity {
|
|
|
54
54
|
this._whereBuilder = new WhereFactory(this.model.schema.attributes, FilterOperations);
|
|
55
55
|
this._clausesWithFilters = this._filterBuilder.injectFilterClauses(clauses, this.model.filters);
|
|
56
56
|
this._clausesWithFilters = this._whereBuilder.injectWhereClauses(this._clausesWithFilters);
|
|
57
|
-
|
|
57
|
+
|
|
58
58
|
this.query = {};
|
|
59
59
|
for (let accessPattern in this.model.indexes) {
|
|
60
60
|
let index = this.model.indexes[accessPattern].index;
|
|
@@ -75,6 +75,10 @@ class Entity {
|
|
|
75
75
|
this.schema = model;
|
|
76
76
|
}
|
|
77
77
|
|
|
78
|
+
get scan() {
|
|
79
|
+
return this._makeChain(TableIndex, this._clausesWithFilters, clauses.index, {_isPagination: true}).scan();
|
|
80
|
+
}
|
|
81
|
+
|
|
78
82
|
setIdentifier(type = "", identifier = "") {
|
|
79
83
|
if (!this.identifiers[type]) {
|
|
80
84
|
throw new e.ElectroError(e.ErrorCodes.InvalidIdentifier, `Invalid identifier type: "${type}". Valid identifiers include: ${u.commaSeparatedString(Object.keys(this.identifiers))}`);
|