View | Details | Raw Unified | Return to bug 27760
Collapse All | Expand All

(-)a/Koha/REST/Plugin/Query.pm (-1 / +12 lines)
Lines 268-274 Merges parameters from $q_params into $filtered_params. Link Here
268
268
269
=head3 stash_overrides
269
=head3 stash_overrides
270
270
271
    # Stash the overrides
271
    $c->stash_overrides();
272
    $c->stash_overrides();
273
    #Use it
274
    my $overrides = $c->stash('koha.overrides');
275
    if ( $overrides->{pickup_location} ) { ... }
276
277
This helper method parses 'x-koha-override' headers and stashes the passed overriders
278
in the for of a I<hashref> for easy use in controller methods.
279
280
FIXME: With the currently used JSON::Validator version we use, it is not possible to
281
use the validated and coerced data (it doesn't validate array-type headers) so this
282
implementation relies on manual parsing. Look at the JSON::Validator changelog for
283
reference: https://metacpan.org/changes/distribution/JSON-Validator#L14
272
284
273
=cut
285
=cut
274
286
275
- 

Return to bug 27760