Bug 33556: Path parameters are handled explicitly in the controllers

In the case of $c->objects->search_rs, the variable is just not used.
In the case of /acq/orders, it's a leftover from when we removed in the
helper. Check there are tests with path params everywhere (including
orders) and it has no effect.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This commit is contained in:
Tomás Cohen Arazi 2023-06-08 11:52:11 -03:00
parent 39496af98f
commit dcbd3e6929
Signed by: tomascohen
GPG key ID: 0A272EA1B2F3C15F
2 changed files with 5 additions and 4 deletions

View file

@ -157,8 +157,7 @@ controller, and thus shouldn't be called twice in it.
$query_fixers //= []; $query_fixers //= [];
# Extract reserved params # Extract reserved params
my ( $filtered_params, $reserved_params, $path_params ) = my ( $filtered_params, $reserved_params ) = $c->extract_reserved_params($args);
$c->extract_reserved_params($args);
if ( exists $reserved_params->{_order_by} ) { if ( exists $reserved_params->{_order_by} ) {

View file

@ -46,8 +46,10 @@ sub list {
return try { return try {
my $only_active = delete $c->validation->output->{only_active}; my $only_active = $c->param('only_active');
my $order_id = delete $c->validation->output->{order_id}; my $order_id = $c->param('order_id');
$c->req->params->remove('only_active')->remove('order_id');
my $orders_rs; my $orders_rs;