Bug 30674 - x-koha-override should use collectionFormat: csv
Summary: x-koha-override should use collectionFormat: csv
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: REST API (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Tomás Cohen Arazi
QA Contact: Martin Renvoize
URL:
Keywords:
Depends on: 30194
Blocks:
  Show dependency treegraph
 
Reported: 2022-05-03 18:03 UTC by Tomás Cohen Arazi
Modified: 2022-12-12 21:23 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
22.05.00


Attachments
Bug 30674: x-koha-override should use collectionFormat: csv (2.09 KB, patch)
2022-05-03 18:10 UTC, Tomás Cohen Arazi
Details | Diff | Splinter Review
Bug 30674: x-koha-override should use collectionFormat: csv (2.13 KB, patch)
2022-05-04 02:14 UTC, David Nind
Details | Diff | Splinter Review
Bug 30674: x-koha-override should use collectionFormat: csv (2.20 KB, patch)
2022-05-04 12:14 UTC, Martin Renvoize
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Tomás Cohen Arazi 2022-05-03 18:03:49 UTC
Now that we use a fixed version of the stack, we should fix this. Bug 30663 already implements overrides like this and we should, for consistency, use it in the other occurences.
Comment 1 Tomás Cohen Arazi 2022-05-03 18:10:15 UTC
Created attachment 134556 [details] [review]
Bug 30674: x-koha-override should use collectionFormat: csv

This patch makes this header parameter rely on the OpenAPI spec to
validate and document the available options.

Right now the only place is in POST and PUT /holds.

To test:
1. Run:
   $ kshell
  k$ prove t/db_dependent/api/v1/holds.t \
           t/db_dependent/api/v1/auth_authenticate_api_request.t
=> SUCCESS: Tests pass
2. Apply this patch
3. Repeat 1
=> SUCCESS: Tests still pass!
4. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 2 David Nind 2022-05-04 02:14:26 UTC
Created attachment 134563 [details] [review]
Bug 30674: x-koha-override should use collectionFormat: csv

This patch makes this header parameter rely on the OpenAPI spec to
validate and document the available options.

Right now the only place is in POST and PUT /holds.

To test:
1. Run:
   $ kshell
  k$ prove t/db_dependent/api/v1/holds.t \
           t/db_dependent/api/v1/auth_authenticate_api_request.t
=> SUCCESS: Tests pass
2. Apply this patch
3. Repeat 1
=> SUCCESS: Tests still pass!
4. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: David Nind <david@davidnind.com>
Comment 3 Martin Renvoize 2022-05-04 12:14:17 UTC
Created attachment 134607 [details] [review]
Bug 30674: x-koha-override should use collectionFormat: csv

This patch makes this header parameter rely on the OpenAPI spec to
validate and document the available options.

Right now the only place is in POST and PUT /holds.

To test:
1. Run:
   $ kshell
  k$ prove t/db_dependent/api/v1/holds.t \
           t/db_dependent/api/v1/auth_authenticate_api_request.t
=> SUCCESS: Tests pass
2. Apply this patch
3. Repeat 1
=> SUCCESS: Tests still pass!
4. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 4 Martin Renvoize 2022-05-04 12:14:42 UTC
Great call.. all looks good here.

Passing QA
Comment 5 Tomás Cohen Arazi 2022-05-05 13:34:05 UTC
Pushed for 22.05. Thanks everyone.