-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature: Model for statistics #205
Conversation
Adds test for creating audit events to existing test infrastructure.
Adds the model, migration and factory and updates the schema. Additionally, it introduces a "has_many" connection to the item model. It destroys the item with the audit events, because they won't be relevant anymore.
Introduces the audit event helper as interface for audit event. User are aware of available audit event types now.
Adds the creation of audit events to the existing infrastructure (mostly in item controller). Therefore, I had to disable the rubocop abc-metric for a function, because I couldn't reduce the complexity.
Introduces empty statistics helper to add functions for calculating statistics and metrices in the future.
I had to expand disabling the rubocop abc-metric for another function, because I couldn't reduce the complexity.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great so far! Especially the simple interface for adding a new audit event. I personally would test for more properties in the tests (as proposed below).
Additionally, I don't fully understand why some fields in the data-model are necessary.
spec/features/notifications/return_request_notifications_spec.rb
Outdated
Show resolved
Hide resolved
spec/features/notifications/return_request_notifications_spec.rb
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Found one more little thing.
Co-authored-by: Luke <[email protected]>
I'll clean the commit history with the squash 😇 I'm sorry for the mess |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Description of Functionality looks good to me! Keep up the good work team!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! I haven't confirmed if there are conflicts with @Greenscreen23's changes on dev. We should probably check that.
spec/features/notifications/return_request_notifications_spec.rb
Outdated
Show resolved
Hide resolved
spec/features/notifications/return_request_notifications_spec.rb
Outdated
Show resolved
Hide resolved
Thank you very much for the review again @SaturnHafen It's very helpful 😇 |
Co-authored-by: Lietze <[email protected]>
Co-authored-by: Luke <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Keep up the good work team!!🎉
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Thanks for all the changes, and sorry for being so picky :)
Fixes #138
This PR introduces audit event logs, to collect data of items for future statistics.
We can improve the performance in the future by calculating results of metrices on a regular basis with a cronjob.
PR checklist