| Summary: | AutoILLBackendPriority should consider a 'yellow' stage | ||
|---|---|---|---|
| Product: | Koha | Reporter: | Pedro Amorim <pedro.amorim> |
| Component: | ILL | Assignee: | Pedro Amorim <pedro.amorim> |
| Status: | Needs Signoff --- | QA Contact: | Testopia <testopia> |
| Severity: | enhancement | ||
| Priority: | P5 - low | CC: | lisette, pedro.amorim, tomascohen |
| Version: | Main | ||
| Hardware: | All | ||
| OS: | All | ||
| GIT URL: | Initiative type: | --- | |
| Sponsorship status: | --- | Crowdfunding goal: | 0 |
| Patch complexity: | Trivial patch | Documentation contact: | |
| Documentation submission: | Text to go in the release notes: | ||
| Version(s) released in: | Circulation function: | ||
| Attachments: |
Bug 41111: Add an yellow state to ILLAutoBackendPriority
Bug 41111: Add an yellow state to ILLAutoBackendPriority Bug 41111: Add an yellow state to ILLAutoBackendPriority |
||
|
Description
Pedro Amorim
2025-10-27 15:41:47 UTC
Created attachment 188478 [details] [review] Bug 41111: Add an yellow state to ILLAutoBackendPriority Originally, AutoILLBackendPriority only considered 2 states: green or red. This patch introduces a yellow state. Yellow means the Staff UI can pick that backend, but Koha will only suggest that as the goto backend if no other 'green' backends exist. If both green and yellow backends are returned, Koha will suggest the top green in priority. OPAC will never consider 'yellow' backends. Functionality there stays the same: Pick first 'green' backend in priority or default to Standard. Created attachment 188520 [details] [review] Bug 41111: Add an yellow state to ILLAutoBackendPriority Originally, AutoILLBackendPriority only considered 2 states: green or red. This patch introduces a yellow state. Yellow means the Staff UI can pick that backend, but Koha will only suggest that as the goto backend if no other 'green' backends exist. If both green and yellow backends are returned, Koha will suggest the top green in priority. OPAC will never consider 'yellow' backends. Functionality there stays the same: Pick first 'green' backend in priority or default to Standard. Test plan: 1) Enable ILLModule 2) Install this dummy backend plugin designed for testing purposes only: https://github.com/openfifth/koha-ill-backend-plugin 3) Enable AutoILLBackendPriority by ticking "PluginBackend" 4) Create a new ILL request, visit: <staff_url>/cgi-bin/koha/ill/ill-requests.pl?method=create&backend=Standard 5) If you put 'red' as title, the backend will return unavailable. If you put 'green' on title the backend will return available. If you put 'yellow' on the backend it'll return the new 'yellow' stage. If title doesnt match that it'll return one of the 3 at random. Created attachment 188521 [details] [review] Bug 41111: Add an yellow state to ILLAutoBackendPriority Originally, AutoILLBackendPriority only considered 2 states: green or red. This patch introduces a yellow state. Yellow means the Staff UI can pick that backend, but Koha will only suggest that as the goto backend if no other 'green' backends exist. If both green and yellow backends are returned, Koha will suggest the top green in priority. OPAC will never consider 'yellow' backends. Functionality there stays the same: Pick first 'green' backend in priority or default to Standard. Test plan: 1) Enable ILLModule 2) Install this dummy backend plugin designed for testing purposes only: https://github.com/openfifth/koha-ill-backend-plugin/releases/tag/v2.0.7 3) Enable AutoILLBackendPriority by ticking "PluginBackend" 4) Create a new ILL request, visit: <staff_url>/cgi-bin/koha/ill/ill-requests.pl?method=create&backend=Standard 5) If you put 'red' as title, the backend will return unavailable. If you put 'green' on title the backend will return available. If you put 'yellow' on the backend it'll return the new 'yellow' stage. If title doesnt match that it'll return one of the 3 at random. |