-
Notifications
You must be signed in to change notification settings - Fork 78
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add analytics module to handle /analytics endpoints (#403)
* feat(AnalyticsRouter): move /analytics routes into own router * feat(AnalyticsService): add getUsersCount function * refactor(AnalyticsRouter): replace handler for /users endpoint * feat(AnalyticsService): add getSubmissionsCount * feat(AnalyticsCtl): add handler for /submissions endpoint * refactor(AnalyticsRouter): replace handler for /submissions endpoint * feat(FeatureManager): add stronger typings and export type from index * feat(SubmissionModel): add static method findFormsWithSubsAbove * feat(FormStatsModel): add static method aggregateFormCount * feat(AnalyticsService): add getFormCount methods stats/subs collection * feat(AnalyticsFty): add factory to generate getFormCount method * refactor(AnalyticsRouter): replace handler for /forms endpoint * refactor(Analytics): rename handler functions to be more concise * feat(FormStatsModel): add missing formId key * test(SubmissionModel): add tests for static findFormsWithSubsAbove fn * test(FormStatsModel): add tests for static aggregateFormCount fn * test(AnalyticsService): add tests for getFormCount* methods Also remove form count related jasmine tests * test(AnalyticsService): add tests for getUserCount * test(AnalyticsService): add tests for getSubmissionCount * test(CoreCtl): remove tests for functions already refactored away * test(AnalyticsFty): add tests * test(AnalyticsCtl): add tests * fix(AnalyticsService): correct logged meta action names * test(AnalyticsCtl): tighten res.status call checks * feat: add private JSDoc key to factory invoked methods
- Loading branch information
Showing
19 changed files
with
1,110 additions
and
389 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.