diff --git a/client/src/collection.js b/client/src/collection.js index 1f81cbb56f..0f2fae3a70 100644 --- a/client/src/collection.js +++ b/client/src/collection.js @@ -147,6 +147,13 @@ class Collection { */ lastSyncPromise = null + /** + * A parent model. To be used for own purposes. E.g. to have access to a parent from related models. + * + * @type {import('model').default} + */ + parentModel + /** * @param {Model[]|null} [models] Models. * @param {{ @@ -934,6 +941,7 @@ class Collection { collection.maxSize = this.maxSize; collection.maxMaxSize = this.maxMaxSize; collection.whereFunction = this.whereFunction; + collection.parentModel = this.parentModel; return collection; }