diff --git a/Koha/REST/V1/Acquisitions/Orders.pm b/Koha/REST/V1/Acquisitions/Orders.pm index ae9c1bafbc..d5a0fe73c6 100644 --- a/Koha/REST/V1/Acquisitions/Orders.pm +++ b/Koha/REST/V1/Acquisitions/Orders.pm @@ -183,9 +183,11 @@ sub list { $c->add_pagination_headers( { - total => ($orders->is_paged ? $orders->pager->total_entries : $orders->count), - base_total => $total, - params => $args, + base_total => $total, + page => $reserved_params->{_page}, + per_page => $reserved_params->{_per_page}, + query_params => $args, + total => ( $orders->is_paged ? $orders->pager->total_entries : $orders->count ), } ); diff --git a/Koha/REST/V1/ERM/EHoldings/Packages/EBSCO.pm b/Koha/REST/V1/ERM/EHoldings/Packages/EBSCO.pm index defd5ea0a7..ccdad76922 100644 --- a/Koha/REST/V1/ERM/EHoldings/Packages/EBSCO.pm +++ b/Koha/REST/V1/ERM/EHoldings/Packages/EBSCO.pm @@ -60,9 +60,11 @@ sub list { $c->add_pagination_headers( { - base_total => $base_total, - total => $total, - params => $args, + base_total => $base_total, + page => $args->{_page}, + per_page => $args->{_per_page}, + query_params => $args, + total => $total, } ); return $c->render( status => 200, openapi => \@packages ); diff --git a/Koha/REST/V1/ERM/EHoldings/Resources/EBSCO.pm b/Koha/REST/V1/ERM/EHoldings/Resources/EBSCO.pm index abd4433ac8..a404c03998 100644 --- a/Koha/REST/V1/ERM/EHoldings/Resources/EBSCO.pm +++ b/Koha/REST/V1/ERM/EHoldings/Resources/EBSCO.pm @@ -104,9 +104,11 @@ sub list { $total = 10000 if $total > 10000; $c->add_pagination_headers( { - base_total => $base_total, - total => $total, - params => $args, + base_total => $base_total, + page => $page, + per_page => $per_page, + query_params => $args, + total => $total, } ); return $c->render( status => 200, openapi => \@resources ); diff --git a/Koha/REST/V1/ERM/EHoldings/Titles/EBSCO.pm b/Koha/REST/V1/ERM/EHoldings/Titles/EBSCO.pm index cf3c788cda..05c672c7fb 100644 --- a/Koha/REST/V1/ERM/EHoldings/Titles/EBSCO.pm +++ b/Koha/REST/V1/ERM/EHoldings/Titles/EBSCO.pm @@ -83,9 +83,11 @@ sub list { $c->add_pagination_headers( { - #base_total => $base_total, - total => $total, - params => $args, + #base_total => $base_total, + page => $page, + per_page => $per_page, + query_params => $args, + total => $total, } ); return $c->render( status => 200, openapi => \@titles );