Skip to content

Data provider: move to function apart isListRequest function#1002

Open
omarlopesino wants to merge 1 commit intoRESTful-Drupal:7.x-2.xfrom
omarlopesino:7.x-2.x-data-provider-is-list-request
Open

Data provider: move to function apart isListRequest function#1002
omarlopesino wants to merge 1 commit intoRESTful-Drupal:7.x-2.xfrom
omarlopesino:7.x-2.x-data-provider-is-list-request

Conversation

@omarlopesino
Copy link

Hi.

The changes from this PR are make a method in Drupal\restful\Plugin\resource\DataProvider class to check is a list request. In this way other class can extend and determine if this is a list request by themselves.

Use case: a resource wich is using path like this 'resource/%' with only one value, no commas, that returns a list of entities using a custom data provider. This is useful because the custom data provider can use the filters in his query for list.

Please review, thanks!

@omarlopesino
Copy link
Author

omarlopesino commented Sep 5, 2017

There is a strange error in travis console The program 'drush' is currently not installed. To run 'drush' please ask your administrator to install the package 'drush', but the changes of PR shouldn't be the cause.

What can be happening?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant