From 2988f9e3b8597bc6e54995efba79c1f365e077c1 Mon Sep 17 00:00:00 2001 From: Marshall Date: Wed, 2 Sep 2020 12:48:33 -0600 Subject: [PATCH] Add count methods to the Model types --- src/service-module/types.ts | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/service-module/types.ts b/src/service-module/types.ts index 196be9a3..e781235a 100644 --- a/src/service-module/types.ts +++ b/src/service-module/types.ts @@ -246,6 +246,17 @@ export interface ModelStatic extends EventEmitter { */ findInStore(params?: Params): Paginated + /** + * A proxy for the `count` action + * @param params Find params + */ + count(params?: Params): Promise> + /** + * A proxy for the `count` getter + * @param params Find params + */ + countInStore(params?: Params): Paginated + /** * A proxy for the `get` action * @param id ID of record to retrieve