-
Notifications
You must be signed in to change notification settings - Fork 17
IBX-9060: Added $query parameter for filtering notifications count and loading #520
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
Conversation
5a21d61
to
3b8e815
Compare
3b8e815
to
8bd2a39
Compare
In order to be consistent and avoid leaking implementation details, we need to approach problem differently. Introduce
You will also need to introduce criteria classes for type, status, creation date alongside with logical operator: and, or, not. Feel free to reach out to me if you have any questions 😉 |
6961c45
to
d3df305
Compare
…ry class and filtering criteria
d3df305
to
b5a96d8
Compare
…ifications` and `findNotifications`, updated related tests and handlers
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.
API-wise it looks okay, however implementation of criteria dispatching needs some improvements (see the diff comment) :-)
src/contracts/Repository/Values/Notification/Query/Criterion.php
Outdated
Show resolved
Hide resolved
src/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabase.php
Outdated
Show resolved
Hide resolved
src/contracts/Repository/Values/Notification/Query/Criterion/NotificationQuery.php
Outdated
Show resolved
Hide resolved
src/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabase.php
Outdated
Show resolved
Hide resolved
src/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabase.php
Outdated
Show resolved
Hide resolved
src/lib/Persistence/Legacy/Notification/Gateway/ExceptionConversion.php
Outdated
Show resolved
Hide resolved
tests/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabaseTest.php
Outdated
Show resolved
Hide resolved
tests/lib/Repository/Decorator/NotificationServiceDecoratorTest.php
Outdated
Show resolved
Hide resolved
…updated NotificationQuery, Gateway, tests and services
156ffd1
to
626debe
Compare
…e`, updated handlers, NotificationQuery, and Gateway to align with new interface structure
…e`, updated handlers, NotificationQuery, and Gateway to align with new interface structure
… into ibx_9060-notification-filtering
…cessary caching for filtered queries
…ation and added getters/setters for criteria properties
src/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabase.php
Outdated
Show resolved
Hide resolved
src/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabase.php
Outdated
Show resolved
Hide resolved
...lib/Persistence/Legacy/Notification/Gateway/CriterionHandler/DateCreatedCriterionHandler.php
Outdated
Show resolved
Hide resolved
...lib/Persistence/Legacy/Notification/Gateway/CriterionHandler/DateCreatedCriterionHandler.php
Outdated
Show resolved
Hide resolved
src/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabase.php
Outdated
Show resolved
Hide resolved
src/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabase.php
Outdated
Show resolved
Hide resolved
src/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabase.php
Outdated
Show resolved
Hide resolved
src/lib/Resources/settings/storage_engines/legacy/notification.yml
Outdated
Show resolved
Hide resolved
src/lib/Persistence/Legacy/Notification/Gateway/DoctrineDatabase.php
Outdated
Show resolved
Hide resolved
…tor_to_array` in DoctrineDatabase Gateway
bcdf9e9
to
8b26279
Compare
src/lib/Resources/settings/storage_engines/legacy/notification.yml
Outdated
Show resolved
Hide resolved
|
- | ||
message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Notification\\Gateway\:\:loadUserNotifications\(\) return type has no value type specified in iterable type array\.$#' | ||
identifier: missingType.iterableValue | ||
message: '#^Method Ibexa\\Core\\Persistence\\Legacy\\Notification\\Gateway\\DoctrineDatabase\:\:__construct\(\) has parameter \$criterionHandlers with generic interface Ibexa\\Contracts\\Core\\Repository\\Values\\Notification\\CriterionHandlerInterface but does not specify its types\: T$#' |
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.
@tbialcz I'm coming a bit late to the party, but the issues in new code need to be resolved instead of being added to the baseline.
Description: