commit ed328c293e606ecb0562d0f88c26e88acd5d1855 Author: Jonathan Druart Date: Tue Nov 4 09:22:06 2025 +0100 Bug 40943: Fix Koha/BackgroundJob.t We should not log/leak session_id! Failed test 'Context set from userenv + interface' at t/db_dependent/Koha/BackgroundJob.t line 132. Structures begin differing at: $got->{session_id} = undef $expected->{session_id} = Does not exist Looks like you failed 1 test of 10. Failed test 'enqueue() tests' at t/db_dependent/Koha/BackgroundJob.t line 135. Failed test 'Userenv set from job context on process' at t/db_dependent/Koha/BackgroundJob.t line 240. Structures begin differing at: $got->{session_id} = undef $expected->{session_id} = Does not exist Looks like you failed 1 test of 5. Signed-off-by: Lucas Gass commit 67e2f80e8560787808f5134a61b30b645c181ef3 Author: Jonathan Druart Date: Tue Nov 4 09:14:53 2025 +0100 Bug 40943: Fix Script_cron.t Failed with: at t/Koha/Script_cron.t line 28. Structures begin differing at: $got->{session_id} = undef $expected->{session_id} = Does not exist session_id is now part of userenv Signed-off-by: Lucas Gass commit 451e835129d38d88dbf7d9d1a2c9e7d1c20ce08d Author: Jonathan Druart Date: Tue Nov 4 09:13:07 2025 +0100 Bug 40943: Fix Serials.t We need to mock userenv ERROR: Plugin dateaccessioned.pl: Can't use an undefined value as a HASH reference at /kohadevbox/koha/cataloguing/value_builder/dateaccessioned.pl line 30. Signed-off-by: Lucas Gass commit 17317d926beccbfaafe23824247147c924ffcab5 Author: David Cook Date: Fri Oct 31 02:17:57 2025 +0000 Bug 39860: (QA follow-up) fix XSS vulnerability and fix disabling of WYSIWYG Signed-off-by: David Cook Signed-off-by: Lucas Gass commit 0f5a3f6869a56ff58056777c894cf6ba76161259 Author: Lucas Gass Date: Wed Oct 15 00:19:32 2025 +0000 Bug 39860: Disable WYSIWYG for record display entries Signed-off-by: David Cook Signed-off-by: Lucas Gass commit 7463cb4fb5f0377003b3bcaf7f030141c98e2c55 Author: Lucas Gass Date: Wed Aug 27 17:18:26 2025 +0000 Bug 39860: Update scrubber profile and add Scrubber.t test Signed-off-by: David Cook Signed-off-by: Anneli Österman Signed-off-by: David Cook Signed-off-by: Lucas Gass commit 7ace056e45fc7b8875e33f82e6e69f46b4691aa7 Author: Lucas Gass Date: Thu Jul 3 17:49:04 2025 +0000 Bug 39860: Add record_display srubber profile Signed-off-by: David Cook Signed-off-by: Anneli Österman Signed-off-by: David Cook Signed-off-by: Lucas Gass commit 4189541772ddbba5ca037e303ac962c267bbbab1 Author: Lucas Gass Date: Thu Jun 5 20:55:03 2025 +0000 Bug 39860: Add options for opac/staff lists Signed-off-by: David Cook Signed-off-by: Anneli Österman Signed-off-by: David Cook Signed-off-by: Lucas Gass commit ff834d4b8bde9dd93a533e872d2bd953e5f615df Author: Lucas Gass Date: Thu Jun 5 20:39:22 2025 +0000 Bug 39860: Fix OPAC display location Signed-off-by: David Cook Signed-off-by: Anneli Österman Signed-off-by: David Cook Signed-off-by: Lucas Gass commit c55388dd8645afaece41cde28e90bd3091bf0eac Author: Lucas Gass Date: Thu Jun 5 20:17:00 2025 +0000 Bug 39860: Move display control from system preference to additional contents Signed-off-by: David Cook Signed-off-by: Anneli Österman Signed-off-by: David Cook Signed-off-by: Lucas Gass commit 9cdb95121e9880caf9734b962c3a8f591e8d2da2 Author: Lucas Gass Date: Wed May 7 21:39:18 2025 +0000 Bug 39860: Allow for the defining of custom MARC fields on the staff interface record display pages To test: 0. APPLY PATCH, restart_all 1. Find or create a record that has some MARC fields that don't show up by default in the record display. ( I tested using a 538$a ) 2. Go to Tools and you should see a new link for 'Record display customizations'. 3. From Record display customizations click 'New Entry' 4. Choose a display location, the choices should be StaffResultsPage, StaffDetailPage, OPACResultsPage, and OPACDetailPage 5. Add the following to the entry: [% IF record.subfield('538' , 'a') %] The 538a: [% record.subfield('538' , 'a') %] [% END %] 6. Go to the record from step 1, you should see the 538$a labeled as 'The 538a:' with the appropriate data in it. 7. This should display in the appropriate location depending on if you chose StaffResultsPage, StaffDetailPage, OPACResultsPage, or OPACDetailPage. Check each of the locations. 8. Make a new, or edit existing, Record display customization and mark the 'Library:' field for a specific branch. Make sure that the Record display customization only shows up when you are logged in at that branch. 9. Install a new language pack, I tested with es-ES. 10. Make a new, or edit existing, Record display customization and fill out the language specific tab. Make sure the Record display customization shows correctly with the language you chose. Signed-off-by: David Cook Signed-off-by: Anneli Österman Signed-off-by: David Cook Signed-off-by: Lucas Gass commit a7bd032affd624a7759921a4a4fd64bc1f4f1099 Author: Aleisha Amohia Date: Thu Oct 31 02:30:04 2024 +0000 Bug 38306: Only print EnhancedMessagingPreferences warning if run with verbose This enhancement will amend the automatic_renewals.pl script to only print a warning about the EnhancedMessagingPreferences system preference being disabled if the script was run with verbose. To test: 1. Disable EnhancedMessagingPreferences 2. Run misc/cronjobs/automatic_renewals.pl 3. Notice the warning is printed 4. Apply the patch and restart services 5. Run misc/cronjobs/automatic_renewals.pl and notice the warning is not printed 6. Run misc/cronjobs/automatic_renewals.pl --verbose and notice the warning is printed 7. Enable EnhancedMessagingPreferences 8. Run misc/cronjobs/automatic_renewals.pl and notice the warning is not printed Sponsored-by: Catalyst IT Signed-off-by: Brendan Lawlor Signed-off-by: Marcel de Rooy Signed-off-by: Lucas Gass commit 378847a3ae5af59622b914a2cf11a18c9836059d Author: Matt Blenkinsop Date: Thu Oct 23 15:51:55 2025 +0100 Bug 40942: Account for the order of split panes in split screen view Signed-off-by: Michaela Signed-off-by: Laura_Escamilla Signed-off-by: Lucas Gass commit ebe23282820631d56f2a05ebcade3dd835ee72c4 Author: Matt Blenkinsop Date: Thu Oct 23 14:56:25 2025 +0100 Bug 40942: Improve the display of vendor contracts Test plan: 1) Apply patch and yarn js:build 2) Navigate to a vendor and add some contacts 3) View the vendor record 4) The contacts table should now be at the bottom of the page and the full width of the screen 5) The Ordering information section should be at the top right of the screen Signed-off-by: Michaela Signed-off-by: Laura_Escamilla Signed-off-by: Lucas Gass commit d8c6286b1c1c639b9a09f45f65b2a1051678d1d5 Author: Fridolin Somers Date: Mon May 5 10:12:30 2025 +0200 Bug 39825: Add a direct link to items tag in MARC bibliographic framework page In MARC bibliographic framework page, add a direct link to items tag (952 in MARC21 and 995 in UNIMARC) can be very useful. Currently one needs to search for the tag, then click on actions, then click on "View subfields". Test plan : 1) Go to Administration > MARC bibliographic framework 2) View any framework MARC structure 3) You see in tools bar new button "View items tag (952)" 4) Click on it, you see this tag subfields Signed-off-by: Roman Dolny Signed-off-by: Laura_Escamilla Signed-off-by: Lucas Gass commit 96bb1ec97d359b13f219edc597910ce49a3aa4bd Author: Lisette Scheer Date: Mon Oct 20 17:18:36 2025 +0000 Bug 40827: Add context to plugin wrapper for report plugins This patch updates the plugin wrapper to include the reports menu and have the breadcrumbs list reports instead of admin or tools when method="report" To Test: 1. Install the Kitchen Sink Plugin 2. Navigate to Reports->Report plugins->Run Report. 3. Observe the admin menu shows 4. Apply the patch 5. Repeat step 2 6. Observe the report menu shows and the breadcrumbs are for the report module. 7. Check that the tools and configuration show the appropriate tool/admin context. Signed-off-by: David Cook Signed-off-by: Lucas Gass commit 88ffb14749344bea1b3085dab8bad46cc3bc68e3 Author: David Nind Date: Sat Oct 25 19:01:21 2025 +0000 Bug 41015: (QA follow-up) Update labels Updates to the search forms and labels: - Use sentence case for the Z39.50/SRU search form label - Update title text for the advanced search link - Update the title for the advanced search pop-up window to "Advanced Z39.50/SRU search" Signed-off-by: David Nind Signed-off-by: Lucas Gass commit f98c74b987a13db258a8d23755b14ce547a40389 Author: Andrew Fuerste-Henry Date: Tue Oct 14 15:02:47 2025 +0000 Bug 41015: Label Z39.50/SRU search in advanced cataloging The advanced cataloging editor has a Z39.50/SRU search form included on the page, but it's just labeled "Search," so it's not at all clear what it's for. Test plan: 1. Enable and go to advanced cataloging editor. 2. Note that the Z39.50/SRU search form is just labeled "Search". 3. Apply patch, reload page. 4. Note that it's now labeled "Z39.50/SRU search". 5. Note that the advanced search pop-up window is now labelled "Advanced Z39.50/SRU search". Signed-off-by: Phil Ringnalda Signed-off-by: David Nind Signed-off-by: Lucas Gass commit 06e04d3a02fc681181d6cc9e27a78bd7aaba4553 Author: Lucas Gass Date: Mon Nov 3 20:22:33 2025 +0000 Bug 20253: DBIC Signed-off-by: Lucas Gass commit 60803c88402bada4d558eec8a16c60f38111143f Author: Lucas Gass Date: Mon Nov 3 20:20:44 2025 +0000 Bug 20253: DBRev 25.06.00.031 Signed-off-by: Lucas Gass commit ebfca0edb47ab0405bd2a7dcd6622380dd9a136f Author: Martin Renvoize Date: Tue Oct 14 11:51:42 2025 +0100 Bug 20253: (follow-up) Fix undefined variable $b and test plan count In bug 40587 we renamed a variable from $b to $basketno. After rebasing, the auto-orders blocking code had a bug where it referenced an undefined variable $b instead of $basketno when checking for PO number conflicts. This caused warnings: "Use of uninitialized value $Koha::EDI::b in exists" This patch: - Renames $b to $basketno throughout the conflict checking code - Updates test plan from 7 to 8 to match actual subtest count Test plan: 1. Run prove t/db_dependent/Koha/EDI.t 2. Verify all tests pass without warnings 3. Confirm auto-orders blocking works correctly for duplicate PO numbers Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit e5add0fd964be4f1fc50c37dd17d1a3f61a422ee Author: Martin Renvoize Date: Wed Oct 1 12:07:24 2025 +0100 Bug 20253: (follow-up) Update tests for Bug 38489 rebase With the move to Koha::File::Transports we need to update the tests introduced in this patchset to match the others by generating a 'local' transport and using that. Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit 943bfe097e470294a41925ef678e5bd932ad1871 Author: Martin Renvoize Date: Thu Aug 7 15:39:51 2025 +0100 Bug 20253: (follow-up) Block auto_orders and UI ordering for duplicate PO numbers When po_is_basketname is enabled for a vendor, duplicate purchase order numbers should prevent both automatic ordering (auto_orders) and manual UI-triggered ordering to avoid conflicts with existing baskets. This patch implements blocking functionality that: 1. Auto-orders blocking: - Tracks baskets with PO number conflicts during quote processing - Skips auto-ordering for baskets with duplicate PO numbers - Logs clear warnings about blocked baskets 2. UI basket ordering blocking: - Adds duplicate checking in create_edi_order function - Returns detailed error information when conflicts detected - Prevents EDI order creation for conflicting baskets 3. User-friendly error handling: - Updates basket.pl to handle duplicate PO number errors - Stays on basket page to display error messages - Provides clear messaging about conflicts and resolution steps 4. Template messaging: - Adds clear error message explaining duplicate PO conflicts - Shows which existing basket uses the same PO number - Guides users on next steps to resolve the issue This ensures data integrity and prevents order processing conflicts while providing clear feedback to users about duplicate PO number issues. Test plan: 1. Set up a vendor with EDI account and enable "po_is_basketname" 2. Create a basket with a specific name (e.g., "PO12345") 3. Process an EDIFACT quote that contains the same PO number: - If auto_orders is enabled: verify the new basket is created but NOT automatically ordered - Check the logs show "Auto-order blocked" message 4. For UI testing, create another basket manually with the same name 5. Try to generate EDI order via "Generate EDI order" button 6. Verify: Error message appears stating duplicate PO number conflict 7. Verify: Basket remains open (not closed) 8. Verify: Error message shows which existing basket uses the PO number 9. Test with po_is_basketname disabled: verify normal operation continues 10. Test with unique PO numbers: verify orders process normally Signed-off-by: Hannah Dunne-Howrie Sponsored-by: Westminster City Council Sponsored-by: Royal Borough of Kensington and Chelsea Sponsored-by: OpenFifth Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit 81087d758427adcb78c4e8be078b613ebb1805c0 Author: Martin Renvoize Date: Tue Jul 8 15:19:10 2025 +0100 Bug 20253: (follow-up) Use purchase order number in BGM segment for outgoing ORDER messages When vendors are configured to use purchase order numbers for basket naming, the purchase order number should be included in outgoing ORDER messages as the document message number in the BGM segment for proper EDI workflow continuity. According to EDIFACT specifications, the purchase order number from incoming quote messages (RFF+ON segments) should be used as the document message number in the BGM segment of outgoing ORDER messages, rather than as a separate RFF+ON segment. This follow-up ensures that: 1. Purchase order numbers from incoming QUOTE messages are preserved 2. The same purchase order numbers are sent back in ORDER messages via BGM segment 3. Vendors receive the reference numbers they expect for order processing in the correct format. Implementation: - Added get_purchase_order_number() method to extract PO number from basket name when vendor is configured with 'po_is_basketname' - Modified beginning_of_message() to accept purchase order number parameter - Uses purchase order number in BGM segment when available, falls back to basketno - Added comprehensive tests for purchase order number handling in ORDER messages Test Plan: 1. Apply patches 2. Configure a vendor EDI account with "Basket name source" = "Purchase order number" 3. Process a QUOTE message containing RFF+ON segment 4. Verify basket is created with purchase order number as name 5. Generate ORDER message from the basket 6. Verify ORDER message contains purchase order number in BGM segment 7. Run tests: prove t/db_dependent/Koha/Edifact/Order.t This completes the round-trip EDI workflow for purchase order number handling according to EDIFACT standards: Quote RFF+ON → Basket Name → Order BGM Signed-off-by: Hannah Dunne-Howrie Sponsored-by: Westminster City Council Sponsored-by: Royal Borough of Kensington and Chelsea Sponsored-by: OpenFifth Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit 1e2e89e43f027a24ca0a99632a6e6bba8c8373e2 Author: Martin Renvoize Date: Fri Jul 11 12:31:34 2025 +0100 Bug 20253: (follow-up) Make basket name read-only when derived from EDI purchase order number When a basket is created from an EDI quote with the vendor EDI account configured to use purchase order numbers, the basket name should be protected from changes to maintain the integrity of the purchase order number reference. This patch: - Makes the basket name field read-only in the UI when the basket was created from EDI with purchase order number setting - Adds explanatory text when the field is protected - Implements server-side protection to prevent basket name changes even if the UI is bypassed - Preserves the original purchase order number derived name Signed-off-by: Hannah Dunne-Howrie Sponsored-by: Westminster City Council Sponsored-by: Royal Borough of Kensington and Chelsea Sponsored-by: OpenFifth Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit 458608b9c4f6ec539bd2724af5483a26dcc406ef Author: Martin Renvoize Date: Fri Jul 11 13:47:33 2025 +0100 Bug 20253: (follow-up) Add duplicate purchase order number validation When processing EDI quotes with purchase order numbers, validate that the purchase order number is unique for the vendor to prevent operational confusion. The validation: - Checks for existing baskets with the same purchase order number and vendor - Includes both open and closed baskets in the uniqueness check - Logs an error with the raw RFF+ON segment and details to the edifact_errors table - Continues processing (non-blocking) to prevent data loss - Provides system log warnings for monitoring The error logging includes: - Section: Raw RFF+ON segment (e.g., "RFF+ON:orders 23/1") - Details: Clear description of the duplicate purchase order number issue This ensures administrators can identify and resolve duplicate purchase order numbers while maintaining system functionality and audit trails. Signed-off-by: Hannah Dunne-Howrie Sponsored-by: Westminster City Council Sponsored-by: Royal Borough of Kensington and Chelsea Sponsored-by: OpenFifth Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit 4179211ce8d7ffe865233d737cea77965ef065f8 Author: Martin Renvoize Date: Tue Jul 8 14:45:19 2025 +0100 Bug 20253: Optionally use buyer's purchase order number from EDIFACT quote as basket name This enhancement allows libraries to configure vendors to use the buyer's purchase order number (from RFF+ON segments) as the basket name instead of the EDIFACT filename, improving searchability and reference tracking. Backend Changes: - Added purchase_order_number() method to Koha::Edifact::Message to extract RFF+ON segments from message-level data (before first LIN segment) - Modified process_quote() in Koha::EDI to use purchase order number for basket naming when configured, with fallback to filename Frontend Changes: - Updated admin/edi_accounts.pl to handle po_is_basketname parameter - Added "Use purhase order numbers" option to EDI accounts template Test Plan: 1. Apply patches and run database update 2. Go to Administration > Acquisitions > EDI accounts 3. Create or edit a vendor EDI account 4. Verify "Use purchase order numbers" option appears 5. Enable "Use purchase order numbers" and save 6. Process an EDIFACT quote file that contains RFF+ON segments 7. Verify the created basket name uses the purchase order number instead of filename 8. Process a quote file without RFF+ON segments 9. Verify the basket name falls back to the filename 10. Test with "Use purchase order numbers" disabled 11. Verify basket names use filenames regardless of RFF+ON presence 12. Run tests: prove t/Edifact.t t/db_dependent/Koha/EDI.t The feature is optional and backward compatible - existing behavior is unchanged unless explicitly configured. Signed-off-by: Hannah Dunne-Howrie Sponsored-by: Westminster City Council Sponsored-by: Royal Borough of Kensington and Chelsea Sponsored-by: OpenFifth Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit 168a5a9107667fd28269f9eaa8547dc93c4071af Author: Martin Renvoize Date: Tue Jul 8 14:43:55 2025 +0100 Bug 20253: Add po_is_basketname field to vendor_edi_accounts table This patch adds a new boolean field 'po_is_basketname' to the vendor_edi_accounts table to allow configuration of how basket names are used in EDIFACT. Changes: - Added atomicupdate for existing installations - Updated kohastructure.sql for new installations Signed-off-by: Hannah Dunne-Howrie Sponsored-by: Westminster City Council Sponsored-by: Royal Borough of Kensington and Chelsea Sponsored-by: OpenFifth Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit f6964f2ffa39b1b9392940a570a1f01ef5253036 Author: Martin Renvoize Date: Tue Jul 8 14:41:07 2025 +0100 Bug 20253: Add tests for RFF+ON segment handling and basket naming This patch adds tests for: 1. RFF+ON (Purchase Order Number) segment parsing in EDIFACT messages 2. Vendor configuration for basket naming preferences 3. Basket naming logic in QUOTE processing Test coverage includes: - Message-level RFF+ON segment extraction - Validation that RFF+ON processing stops at LIN segments - Multiple RFF segment handling - Database field storage and constraints - Basket naming configuration logic - Fallback behavior when purchase order number unavailable Signed-off-by: Hannah Dunne-Howrie Sponsored-by: Westminster City Council Sponsored-by: Royal Borough of Kensington and Chelsea Sponsored-by: OpenFifth Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit 78aa42e969ab0c2d0bf47a28ec678b7b9fb6f5a9 Author: Martin Renvoize Date: Fri Jul 18 15:31:05 2025 +0100 Bug 40334: (follow-up) Terminology The envelope level of EDIFACT is called an 'Interchange'. This patch updates our UI terminology to match the official protocol terminology as what we're actually displaying here is the Interchange file that contains the related messages for the Basket. The interchange file will often contain other messages of the same type that came through at the same time of the this basket generation. Sponsored-by: Open Fifth Signed-off-by: Hannah Dunne-Howrie Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit 4f120d8666fd7f0f667d1fbf82115bcedcf53fea Author: Martin Renvoize Date: Wed Jul 9 17:06:51 2025 +0100 Bug 40334: Add EDIFACT message display to basket page This patch extends the EDIFACT message display functionality from the invoice page to the basket page, providing comprehensive access to EDIFACT messages and error reporting. Features added: - Toolbar buttons for viewing EDIFACT messages (quote/order) - Smart button display: single button for one message type, dropdown for multiple - EDIFACT parsing errors section with inline error display - Errors grouped by message type with detailed information - Conditional display: only shows when relevant data exists Changes: - acqui/basket.pl: Added EDIFACT message and error collection logic - basket.tt: Added toolbar buttons and parsing errors section - Uses existing modal system for raw message display Sponsored-by: Open Fifth Signed-off-by: Hannah Dunne-Howrie Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit 17cea3929c2e0c804bcec0490c506932c0ce7267 Author: Matt Blenkinsop Date: Fri Oct 18 14:18:23 2024 +0000 Bug 38208: Provide a link from vendors to ERM This patch provides a link in the left hand menu so that from a vendor record you can access ERM agreements and licenses relevant to that vendor Test plan: 1) Apply patch and reset_all 2) Navigate to ERM and create some agreements and licenses that link to a vendor and some that don't 3) Navigate to a vendor record 4) There should be links in the left hand menu for agreements and licenses 5) Click on these and you should be taken to ERM and see a filtered table based on that vendor Signed-off-by: Roman Dolny Signed-off-by: Laura_Escamilla Signed-off-by: Lucas Gass commit e5575d6c0c613aba2f4a8a18c254d42ca98ed881 Author: Marcel de Rooy Date: Fri Oct 10 11:29:12 2025 +0200 Bug 40943: (QA follow-up) Add a few POD lines for new sub This clears qa warnings. Test plan: Read the POD. Signed-off-by: Marcel de Rooy Signed-off-by: David Cook Signed-off-by: Lucas Gass commit 01514e3aa4cc84f35fbea9d591e95f39ba70e1ec Author: Jonathan Druart Date: Tue Sep 24 15:22:59 2024 +0200 Bug 40943: Use session_id from userenv instead of cookie for value_builder Signed-off-by: Marcel de Rooy [EDIT] Inline tidy. Moved set_userenv_from_session before POD of next sub. Signed-off-by: David Cook Signed-off-by: Lucas Gass commit b34d5194f5ae18db5072c90d59ac869de4bb419e Author: Jonathan Druart Date: Tue Sep 24 15:22:34 2024 +0200 Bug 40943: Store session_id in userenv Signed-off-by: Marcel de Rooy [EDIT] Inline tidy. Signed-off-by: David Cook Signed-off-by: Lucas Gass commit 7e576e58f88c9a96bccc2cb78347659028aa5b41 Author: Martin Renvoize Date: Fri Oct 17 15:43:52 2025 +0100 Bug 38115: (follow-up) Use File::Basename to extract filename for remote upload When --filename contains a path (e.g., /tmp/records.mrc), the script was uploading to the remote server with the full path, creating unwanted directory structures (e.g., uploads/tmp/records.mrc). This patch uses File::Basename::fileparse() to extract just the filename portion for the remote upload, while still using the full path for local file operations. Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit e7307ddc05abf754232fc02bafd10fe2de5c1abe Author: Martin Renvoize Date: Tue Sep 23 21:52:01 2025 +0100 Bug 38115: (follow-up) Improve error handling and connection management Enhance the export_records.pl script with better error handling and connection lifecycle management: 1. Connection Management: - Always call disconnect() after file transport operations - Ensure connections are cleaned up even on errors 2. Error Handling: - Replace unusual die+pod2usage with clear error messages - Add file existence validation before upload attempts - Provide detailed error messages with context - Consistent error message formatting 3. User Experience: - Add validation for --delete_local_after_run without --destination_server_id - Provide informative success messages to STDERR - Better error messages with specific failure reasons 4. Robustness: - Check if output file was created before upload - Check if file exists before attempting deletion - Graceful handling of missing upload directories These improvements make the script more reliable and user-friendly while maintaining all existing functionality. Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit 631a14ec2e80f2545cf5e619d586c12bdc6b9693 Author: Tomás Cohen Arazi Date: Thu Sep 18 16:49:31 2025 -0300 Bug 38115: (follow-up) Update terminology from SFTP/FTP to file transport This follow-up patch updates the terminology in export_records.pl to use generic 'file transport' language instead of specific 'FTP/SFTP' references, aligning with the recent renaming of the underlying classes to File::Transports. Changes: - Replace $sftp_server variable with $file_transport for clarity - Update error messages to use 'file transport server' terminology - Fix incorrect error message for report_id validation - Update POD documentation to reference 'file transport servers' - Maintain consistency with the renamed admin interface and API This ensures the script terminology matches the current class structure and admin interface naming conventions. Signed-off-by: Martin Renvoize Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit 1ee76c6a9fac237ad2b84d710eeb754c566fa901 Author: Jake Deery Date: Tue Feb 18 14:08:09 2025 +0000 Bug 38115: Add destination_server_id to export_records This patch adds two new flags to the export_records.pl script. * --destination_server_id=ID This flag will, when passed, upload the file generated by this script to the destination server, as configured in the FTP/SFTP Servers settings. * --delete_local_after_run This flag will, when passed, cause the script to unlink (delete) the generated marc or CSV file found on the local disk. This is useful for folk who want to upload the file, but not necessarily keep a local copy, filling up the server's storage medium TO TEST: a) APPLY PATCH, reset_all b) Create valid FTP/SFTP Server in Koha settings, ensuring that the server you create is valid and passes testing c) Run ./misc/export_records.pl with no agruments 1) Notice how koha.mrc file is generated d) Run ./misc/export_records.pl --destination_server_id=1 1) Notice how koha.mrc file is generated 2) On your FTP/SFTP Server, notice how koha.mrc is now present in the upload directory e) Run ./misc/export_records.pl --delete_local_after_run 1) Notice how koha.mrc file is NOT generated locally f) Run ./misc/export_records.pl --destination_server_id=1 --delete_local_after_run 1) Notice how koha.mrc file is NOT generated locally 2) On your FTP/SFTP Server, notice how koha.mrc is still present in the upload directory AND the file age is fresh Signed-off-by: Martin Renvoize Signed-off-by: Kyle M Hall Signed-off-by: Lucas Gass commit b6233aeb84aa7b0ca5480199f7111b88ffee958c Author: Pedro Amorim Date: Wed Jul 30 11:28:48 2025 +0000 Bug 40551: Make patron page holds table use API endpoint for cancellation Test plan, k-t-d, patches applied: 1) Search for 'music': http://localhost:8081/cgi-bin/koha/catalogue/search.pl?q=music 2) Click the 'Select all' link on the left of the search toolbar 3) Click the 'Place hold' button on the same toolbar 4) On the patron input, add 'koha' 5) You need to pick the 'Pickup location' specifically for each hold. Click 'Place holds' 6) On this screen (reserve/request.pl) ensure the table(s) work. Selecting all works. Canceling selected works (it doesn't refresh immediatelly, it's a background job). Suspend works as before, sorting, etc. 7) Now visit the patron details page: http://localhost:8081/cgi-bin/koha/members/moremember.pl?borrowernumber=51 8) Click the 'Holds' tab. 9) Test that selecting multiple holds and canceling selected works. 10) Test that canceling a specific hold works. 11) Repeat steps 8-10 but for the circulation page from patron details at: http://localhost:8081/cgi-bin/koha/circ/circulation.pl?borrowernumber=51 Signed-off-by: Phillip Berg Signed-off-by: Andrew Fuerste Henry Signed-off-by: Lucas Gass commit ec1869faa23f9d054d2d90de4b1cd01621b278dd Author: Lucas Gass Date: Mon Nov 3 20:06:12 2025 +0000 Bug 40550: (RM follow-up) Adjust number of API tests Signed-off-by: Lucas Gass commit 09673df356a74d892189b7c26fbd556bb5b7e4fa Author: Pedro Amorim Date: Wed Jul 30 11:28:16 2025 +0000 Bug 40550: Add cancellation_bulk API endpoint Signed-off-by: Phillip Berg Signed-off-by: Andrew Fuerste Henry Signed-off-by: Lucas Gass commit 353e3b6da8aee19d3c58341ea1832f56851ce3ad Author: Pedro Amorim Date: Wed Jul 30 11:27:49 2025 +0000 Bug 40550: Add API tests prove t/db_dependent/api/v1/holds.t Signed-off-by: Phillip Berg Signed-off-by: Andrew Fuerste Henry Signed-off-by: Lucas Gass commit d7d4566810595dfcb8e0734fb23cff118840d8a9 Author: Lucas Gass Date: Mon Nov 3 21:08:18 2025 +0000 Bug 40552: (RM follow-up) Fix forbidden pattern complaint Signed-off-by: Lucas Gass commit 53841886f51265d4945c4c3263d732cf56ea2045 Author: Pedro Amorim Date: Wed Jul 30 11:32:58 2025 +0000 Bug 40552: Allow selecting all holds from a group Test plan, k-t-d, patches applied: 1) Search for 'test': http://localhost:8081/cgi-bin/koha/catalogue/search.pl?q=test 2) Click the 'Select all' link on the left of the search toolbar 3) Click the 'Place hold' button on the same toolbar 4) On the patron input, add 'koha' 5) You need to pick the 'Pickup location' specifically for each hold. Click 'Place holds' 6) Now visit the patron details page: http://localhost:8081/cgi-bin/koha/members/moremember.pl?borrowernumber=51 7) Click the 'Holds' tab. 8) Click the top most checkbox to select all holds. Click the 'group selected' button. Notice the holds are grouped and the 'group hold' column shows the hold group number accordingly. 9) Test that selecting the hold group number opens the hold group modal and a new 'select group holds' buttons exist. 10) Click that button, ensure it selects the group holds. Test with more holds, more groups, unselecting all beforehand, selecting all beforehand, etc. Signed-off-by: Anneli Österman Signed-off-by: Andrew Fuerste Henry Signed-off-by: Lucas Gass commit 8c4d956247a65f1c7196d1c15733a72d53c29133 Author: Pedro Amorim Date: Wed Jul 30 11:32:26 2025 +0000 Bug 40552: Preparation: Move patron page logic for reusability Signed-off-by: Anneli Österman Signed-off-by: Andrew Fuerste Henry Signed-off-by: Lucas Gass commit ad23ace00e5fd8d4b5e834f5b5597e21ef874c3a Author: Lucas Gass Date: Mon Nov 3 19:54:39 2025 +0000 Bug 40529: DBIC Signed-off-by: Lucas Gass commit 954910e2b34698244c7f6f603ed7b7b85301248e Author: Lucas Gass Date: Mon Nov 3 19:52:53 2025 +0000 Bug 40529: DBRev 25.06.00.030 Signed-off-by: Lucas Gass commit 877390de6a58818687d1e6af60bc6084292e73ba Author: Pedro Amorim Date: Wed Oct 29 17:56:49 2025 +0000 Bug 40529: (QA follow-up): Fix DB changes Add UNIQUE KEY entries to table definition The UNIQUE KEY are required as a hold group 'might have' a target hold, not 'has many' target holds. This update and the other things this patch updates in atomicupdate + kohastructure should fix the error thrown by command: perl /kohadevbox/misc4dev/run_tests.pl --instance=kohadev --db-password=password --run-db-compare-only --compare-with=HEAD This command no longer produces any errors. Also in this patch: Renamed table from 'hold_group_target_holds' to 'hold_groups_target_holds' and move it alphabetically to be after 'hold_groups' in kohastructure.sql This is cleaner, as it matches the 'hold_groups' related table, and allows for alphabetical sorting on kohastructure.sql that makes sense i.e. hold_groups is created first, then hold_group_target_holds is created second with an FK to the former. All of this passes: prove ./t/db_dependent/Koha/Hold.t prove ./t/db_dependent/Reserves/HoldGroup.t prove ./t/db_dependent/Circulation* prove ./t/db_dependent/Hold* prove ./t/db_dependent/Reserves* Signed-off-by: Lucas Gass commit 028826c560caba2125f9bad321b6d9e3ec13430c Author: Pedro Amorim Date: Tue Sep 23 13:49:26 2025 +0000 Bug 40529: (QA follow-up) Rebase and fix tests This further rebases on top of 40058 which removed RevertWaitingStatus. It also fixes a warning where 'eq was being utilized on initialized' coming from sub remove_as_hold_group_target Signed-off-by: Andrew Fuerste Henry Signed-off-by: Lucas Gass