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
The following code goes in ROOT\vendor\pokemon-tcg\pokemon-tcg-sdk-php\src\Resources\QueryableResource.php inside of the prepare method (replacing what should be roughly lines 65 - 73).
The user then passes in an array with the first value being "OR" or "AND" (i.e.: 'types' => ['OR', 'fire', 'water']).
A whole query would then look something like: Pokemon::Card()->where(['types' => ['OR', 'fire', 'water'], 'subtypes' => 'mega'])->all();
NOTE: This is a rudimentary fix that should support basic OR/AND. I may add to this to work towards supporting more complex queries and/or direct queries.
Provide a method to pass in raw query strings.
The text was updated successfully, but these errors were encountered: