You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+9
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,14 @@
1
1
# Changelog
2
2
3
+
## v3.1.15
4
+
5
+
### Bug fixes
6
+
7
+
*[07c9989eb](https://github.com/api-platform/core/commit/07c9989eb2717d8881801c843706194499b6c903) fix(metadata): notexposed no urivariables inheritance (#5765)
8
+
*[8d04dcf5f](https://github.com/api-platform/core/commit/8d04dcf5f63c152ffa4e9ae00c8d6624c97f2855) fix(metadata): fix POST on subresource (#5734)
9
+
*[a774f4c51](https://github.com/api-platform/core/commit/a774f4c51167dbbe585269f14a7c51a3f9e38c3c) fix(doctrine): searchfilter with nested custom identifiers (#5760)
10
+
*[b7258ef38](https://github.com/api-platform/core/commit/b7258ef38302c92869ab23d0dc83a2cb411526a7) fix: error 500 on request with 'empty' accept headers, e.g. 'accept: 0' or 'accept: ' (#5767)
Copy file name to clipboardExpand all lines: features/doctrine/search_filter.feature
+19
Original file line number
Diff line number
Diff line change
@@ -1033,3 +1033,22 @@ Feature: Search filter on collections
1033
1033
Then the response status code should be 200
1034
1034
And the response should be in JSON
1035
1035
And the JSON node "hydra:totalItems" should be equal to 1
1036
+
1037
+
@!mongodb
1038
+
@createSchema
1039
+
Scenario: Search on nested sub-entity that doesn't use "id" as its ORM identifier
1040
+
Given there is a dummy entity with a sub entity with id "stringId" and name "someName"
1041
+
When I send a "GET" request to "/dummy_with_subresource?subEntity=/dummy_subresource/stringId"
1042
+
Then the response status code should be 200
1043
+
And the response should be in JSON
1044
+
And the JSON node "hydra:totalItems" should be equal to 1
1045
+
1046
+
@!mongodb
1047
+
@createSchema
1048
+
Scenario: Filters can use UUIDs
1049
+
Given there is a group object with uuid "61817181-0ecc-42fb-a6e7-d97f2ddcb344" and 2 users
1050
+
And there is a group object with uuid "32510d53-f737-4e70-8d9d-58e292c871f8" and 1 users
1051
+
When I send a "GET" request to "/issue5735/issue5735_users?groups[]=/issue5735/groups/61817181-0ecc-42fb-a6e7-d97f2ddcb344&groups[]=/issue5735/groups/32510d53-f737-4e70-8d9d-58e292c871f8"
1052
+
Then the response status code should be 200
1053
+
And the response should be in JSON
1054
+
And the JSON node "hydra:totalItems" should be equal to 3
* Can we do better? This is not the ApiResource the call was made on,
237
+
* so we don't get any kind of api metadata for it without (a lot of?) work elsewhere...
238
+
* Let's just pretend it's always the ORM id for now.
239
+
*/
240
+
if (!$this->hasValidValues([$value], $doctrineTypeField)) {
241
+
$this->logger->notice('Invalid filter ignored', [
242
+
'exception' => newInvalidArgumentException(sprintf('Values for field "%s" are not valid according to the doctrine type.', $associationFieldIdentifier)),
trigger_deprecation('api-platform/core', '3.0', sprintf('Injecting "%s" within "%s" is not needed anymore and this dependency will be removed in 4.0.', ResourceMetadataCollectionFactoryInterface::class, self::class));
0 commit comments