Bug 22421: (QA follow-up) Update API mapping and specs

We missed some cases where the API specs and mappings were missing for
the new old_issue_id field.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This commit is contained in:
Martin Renvoize 2024-11-08 15:57:39 +00:00 committed by Katrin Fischer
parent abbd9e59bd
commit c10c244a28
No known key found for this signature in database
GPG Key ID: 0EF6E2C03357A834
6 changed files with 14 additions and 1 deletions

View File

@ -48,6 +48,7 @@ sub to_api_mapping {
borrowernumber => 'patron_id',
branchcode => 'library_id',
issue_id => undef,
old_issue_id => undef,
itemnumber => undef,
manager_id => 'user_id',
note => 'internal_note',

View File

@ -48,6 +48,7 @@ sub to_api_mapping {
borrowernumber => 'patron_id',
branchcode => 'library_id',
issue_id => 'checkout_id',
old_issue_id => 'old_checkout_id',
itemnumber => 'item_id',
manager_id => 'user_id',
note => 'internal_note',

View File

@ -982,6 +982,7 @@ sub to_api_mapping {
borrowernumber => 'patron_id',
branchcode => 'library_id',
issue_id => 'checkout_id',
old_issue_id => 'old_checkout_id',
itemnumber => 'item_id',
manager_id => 'user_id',
note => 'internal_note',

View File

@ -24,6 +24,11 @@ properties:
- integer
- "null"
description: Internal identifier for the checkout the account line is related to
old_checkout_id:
type:
- integer
- "null"
description: Internal identifier for the old checkout the account line is related to
credit_number:
type:
- string

View File

@ -23,6 +23,11 @@ properties:
- integer
- "null"
description: Internal identifier for the checkout the account line is related to
old_checkout_id:
type:
- integer
- "null"
description: Internal identifier for the old checkout the account line is related to
date:
type: string
format: date-time

View File

@ -90,7 +90,7 @@ subtest 'get_balance() tests' => sub {
$debit_2->discard_changes;
$t->get_ok("//$userid:$password@/api/v1/patrons/$patron_id/account")
->status_is(200)->json_is(
->status_is(200)->or(sub { diag $t->tx->res->body } )->json_is(
{
balance => 100.01,
outstanding_debits => {