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
Steve Karsch edited this page Jun 15, 2017
·
3 revisions
Firstly, copy an existing data provider class file (e.g. restful/src/Plugin/resource/DataProvider/DataProviderDbQuery.php) to your custom module, in a similar file path.
Rename this file to reflect what your class will do, then edit the file:
change the various class references from the original to your new one e.g. * Contains \Drupal\restful\Plugin\resource\DataProvider\DataProviderDbQuery. etc
replace all the use statements with just those that your new class actually uses. It will need at least one, pointing at the original data provider class you're extending: