Bug 39816 - Allow embedding `late_since_days`in baskets
Summary: Allow embedding `late_since_days`in baskets
Status: Needs Signoff
Alias: None
Product: Koha
Classification: Unclassified
Component: REST API (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Tomás Cohen Arazi (tcohen)
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks: 32266
  Show dependency treegraph
 
Reported: 2025-05-02 13:13 UTC by Tomás Cohen Arazi (tcohen)
Modified: 2025-05-08 11:55 UTC (History)
5 users (show)

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


Attachments
Bug 39816: Allow embedding `late_since_days` in baskets (2.79 KB, patch)
2025-05-02 17:20 UTC, Tomás Cohen Arazi (tcohen)
Details | Diff | Splinter Review
Bug 39816: (follow-up) Harmonize embeds in baskets (1.59 KB, patch)
2025-05-02 17:20 UTC, Tomás Cohen Arazi (tcohen)
Details | Diff | Splinter Review
Bug 39816: Allow embedding `late_since_days` in baskets (2.79 KB, patch)
2025-05-02 17:31 UTC, Tomás Cohen Arazi (tcohen)
Details | Diff | Splinter Review
Bug 39816: (follow-up) Harmonize embeds in baskets (1.23 KB, patch)
2025-05-02 17:31 UTC, Tomás Cohen Arazi (tcohen)
Details | Diff | Splinter Review
Bug 39816: Allow embedding `late_since_days` in baskets (2.79 KB, patch)
2025-05-08 11:54 UTC, Tomás Cohen Arazi (tcohen)
Details | Diff | Splinter Review
Bug 39816: (follow-up) Harmonize embeds in baskets (1.23 KB, patch)
2025-05-08 11:55 UTC, Tomás Cohen Arazi (tcohen)
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 (tcohen) 2025-05-02 13:13:02 UTC
Some places, like the late orders table, display this info.
Comment 1 Tomás Cohen Arazi (tcohen) 2025-05-02 17:20:31 UTC Comment hidden (obsolete)
Comment 2 Tomás Cohen Arazi (tcohen) 2025-05-02 17:20:33 UTC Comment hidden (obsolete)
Comment 3 Tomás Cohen Arazi (tcohen) 2025-05-02 17:31:17 UTC
Created attachment 181881 [details] [review]
Bug 39816: Allow embedding `late_since_days` in baskets

This patch adds the option to embed the return value of the
`late_since_days` method in basket objects in the REST API.

It does so by just adding it to the list of embeds in the spec. It is
added in every place baskets can be returned.
Comment 4 Tomás Cohen Arazi (tcohen) 2025-05-02 17:31:34 UTC
Created attachment 181882 [details] [review]
Bug 39816: (follow-up) Harmonize embeds in baskets

As I traversed the REST API spec to add the `late_since_days` embed
option, I noticed an inconsistency in the embed options we defined in
each place a basket is to be returned.

This patch makes all the places have the same embed options.
Comment 5 Emmi Takkinen 2025-05-08 06:28:01 UTC
Patch doesn't apply:

Applying: Bug 39816: Allow embedding `late_since_days` in baskets
Using index info to reconstruct a base tree...
M	api/v1/swagger/definitions/basket.yaml
M	api/v1/swagger/paths/acquisitions_baskets.yaml
M	api/v1/swagger/paths/acquisitions_orders.yaml
Falling back to patching base and 3-way merge...
Auto-merging api/v1/swagger/paths/acquisitions_orders.yaml
Auto-merging api/v1/swagger/paths/acquisitions_baskets.yaml
CONFLICT (content): Merge conflict in api/v1/swagger/paths/acquisitions_baskets.yaml
Auto-merging api/v1/swagger/definitions/basket.yaml
CONFLICT (content): Merge conflict in api/v1/swagger/definitions/basket.yaml
error: Failed to merge in the changes.
Patch failed at 0001 Bug 39816: Allow embedding `late_since_days` in baskets
hint: Use 'git am --show-current-patch=diff' to see the failed patch
When you have resolved this problem run "git bz apply --continue".
If you would prefer to skip this patch, instead run "git bz apply --skip".
To restore the original branch and stop patching run "git bz apply --abort".
Patch left in /tmp/Bug-39816-Allow-embedding-latesincedays-in-baskets-7u_k12.patch
Comment 6 Tomás Cohen Arazi (tcohen) 2025-05-08 11:54:43 UTC
Created attachment 182069 [details] [review]
Bug 39816: Allow embedding `late_since_days` in baskets

This patch adds the option to embed the return value of the
`late_since_days` method in basket objects in the REST API.

It does so by just adding it to the list of embeds in the spec. It is
added in every place baskets can be returned.
Comment 7 Tomás Cohen Arazi (tcohen) 2025-05-08 11:55:06 UTC
Created attachment 182070 [details] [review]
Bug 39816: (follow-up) Harmonize embeds in baskets

As I traversed the REST API spec to add the `late_since_days` embed
option, I noticed an inconsistency in the embed options we defined in
each place a basket is to be returned.

This patch makes all the places have the same embed options.