Commit Graph

56265 Commits

Author SHA1 Message Date
Owen Leonard 4fa4464601
Bug 35808: Remove obsolete responsive table markup from several pages in the OPAC
This patch removes span.tdlabel from several templates. The markup is
obsolete now that we use the DataTables responsive feature.

To test, apply the patch and rebuild the OPAC CSS
(https://wiki.koha-community.org/wiki/Working_with_SCSS_in_the_OPAC_and_staff_client)

- Log in to the OPAC as a user with checkouts, suggestions, and tags.
- Check these pages to confirm that the tables on each one have the
  correct responsive behavior at varying browser widths:
  - OPAC home -> Most popular
  - Your account
  - Your account -> Checkout history
  - Your account -> Suggestions
  - Your account -> Tags
* The recalls history page is fixed in Bug 37158

Sponsored-by: Athens County Public Libraries
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 2627cfbe1d)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:49 +01:00
Eric Garcia 3565e9c59a
Bug 33454: Improved breadcrumbs for patron lists
To test:
1. Apply patch
2. Tools -> Patron lists
3. Create a new patron list
4. Click on the name of your new list
5. Notice the breadcrumbs are changed to "Add patron to 'LIST NAME'"
6. Return to Patron lists
7. In your patron list select Actions -> Add patrons
8. Notice the breadcrumbs are the same

Signed-off-by: Fiona Borthwick <fiona.borthwick@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 3c6ea779e7)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:48 +01:00
Owen Leonard 4f397d23db
Bug 38221: Add Bootstrap styling to pagination in authority plugin search results
This patch updates the markup of pagination links in the authority
search popup so that they have Bootstrap styling consistent with other
pages (e.g. catalog search results).

The pagination markup has also been moved to a BLOCK so that it can be
reused instead of duplicated on the page.

To test, apply the patch and go to Cataloging -> New record (using the
basic MARC editor).

- Switch to tab 1 and click the tag editor link next to tag 100 subfield
  a.
- Perform a search in the popup window which will return multiple pages
  of results (an empty search will work with default testing data).
- Confirm that the pagination links are styled like catalog search
  results.
- Confirm that the search links work correctly and that the correct
  number is highlighted as you page through results.

Sponsored-by: Athens County Public Libraries
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit a762f61faa)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:48 +01:00
Owen Leonard df9f5d17ab
Bug 37826: Remove the use of the script_name variable where it is unnecessary
Most of the places where a "script_name" variable used it is not
strictly necessary. Because it is also used inconsistently, I think it's
better to simply remove the use of the variable where it isn't strictly
necessary.

This patch removes creation of the template variable from several
scripts and updates the corresponding template with the URL itself.

To test, apply the patch and restart services. Test the following pages,
including the various permutations where they are present, e.g. New,
Edit, Delete.

- Administration -> Cities and towns -> Search via the header search
  form
- Administratoin -> Currencies and exchange rates -> Search via the
  header search form
- Administration -> Desks
- Administration -> Budgets
- Administration -> Authority types
- Administration -> Authority types -> MARC structure -> Subfields
- Administration -> Classification configuration
- Administration -> MARC bibliographic framework
- Administration -> MARC bibliographic framework -> MARC structure ->
  Subfields
- Administration -> Record matching rules
- Administration -> OAI repositories
- Administration -> Patron attribute types
- Administration -> System preferences -> Local use
- Administration -> Z39.50/SRU servers
- Acquisitions -> Vendor -> Contracts
- Acquisitions -> Vendor -> Basket -> Export as CSV
- Acquisitions -> Vendor -> Basket -> Edit basket
- Acquisitions -> Vendor -> Basket groups
- Tools -> Import patrons
- Tools -> Notices and slips

Sponsored-by: Athens County Public Libraries
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 8a433d4f20)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:47 +01:00
Tomas Cohen Arazi 87e8effead
Bug 38684: Improve translatability in cat-toolbar.inc
This patch converts strings using

* *subscription(s)*
* *item(s)*

into different strings for the singular and plural forms. This helps
translating and is also more accurate for the end user.

To test:
1. Have a record with 2 items and 2 subscriptions
2. hover on the _Edit > Delete record_  dropdown item
   => FAIL: Mixed form string about items
3. Delete one item at a time, repeating 2
   => FAIL: Mixed form string at each step
4. Once items are deleted, repeat 2
   => FAIL: Mixed form string about subscriptions
5. Delete one subscription at a time, repeating 2
   => FAIL: Mixed form string at each step
6. Apply this patch
7. Repeat 1-5
   => SUCCESS: Different message in singular and plural forms
   => SUCCESS: The message is correct
8. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 03392b660e)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:47 +01:00
Emily Lamancusa 3d9aa17407
Bug 38735: Add preferred_name to default search fields for new installations
To test:
1. Attach patch first, and then start up KTD or sandbox to see the
   behavior for a new installation
2. Go to Administration > System Preferences and search for
    DefaultPatronSearchFields
3. Click to edit
--> Confirm preferred_name is checked in the modal that displays
4. Edit a patron to give them a preferred name that is different from
   their first name
5. Search for the patron by the newly set preferred_name
--> Confirm the patron correctly autocompletes and appears in the search
    results

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit deccd6eb7e)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:46 +01:00
Lari Taskula 0c965868d9
Bug 35975: Show biblionumber when download cart as BibTeX
To test:
1. In OPAC, add a record to your cart
2. Go to your cart
3. Click Download -> BibTeX
4. Observe downloaded file in your favorite text editor
5. Observe Koha::Hash(xxx) within file contents
6. Apply patch
7. Repeat steps 3 and 4
8. Observe Koha::Hash has been replaced with biblionumber

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit f66379c075)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:46 +01:00
Owen Leonard 74f85e12a9
Bug 38753: Missing table cells breaks OPAC charges table
This patch adds a couple of instances of the empty cell required by
DataTables to enable responsive behavior. The mismatch between table
headers and table cells causes DataTables to fail.

To test you must log in to the OPAC as a user with charges and credit.

- Apply the patch and go to Patrons in the staff interface.
- Find and view a patron record. Click "Accounting" in the sidebar menu.
- Use the "Create manual invoice" and "Create manual credit" tabs to
  create at least one charge and a credit which is greater than the
  charges.
- Log in to the OPAC as that user and go to their Charges tab.
- The charges table shoud look correct, with DataTables sorting
  indicators on the table headers to indicate that DataTables is
  working.

Sponsored-by: Athens County Public Libraries
Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit b49cac544f)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:45 +01:00
Magnus Enger 2b5fe6fc76
Bug 38617: Fix warning about auto increment and biblioitems
To reproduce:
- Delete a bibliographic, noting the biblionumber (let's call it X)
- Run this in the database:
    UPDATE deletedbiblioitems SET biblionumber = X;
- Go to About Koha > System information
- Notice the warning compares two tables that are not equivalent:
  "The following IDs exist in both tables biblio and deletedbiblioitems"

To test:
- Apply the patch
- Reload the System information
- The warning should now read:
  "The following IDs exist in both tables biblioitems and deletedbiblioitems"

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 44e15f5b99)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:45 +01:00
Owen Leonard 8571b91840
Bug 38349: Fix style of sidebar form submit button on tags review page
This patch fixes the markup of the sidebar form on the tags
review page and removes an incorrect "btn-sm" class from the
submit button.

To test, apply the patch and go to Tools -> Tags.

In the sidebar form, confirm that the submit button has the same yellow
"primary" style as other submit buttons, and that it fills the width of
the sidebar.

Sponsored-by: Athens County Public Libraries
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit f6c4663d85)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:44 +01:00
Owen Leonard e9a32d369c
Bug 38285: Replace instances of obsolete Bootstrap class "pull-right"
This patch fixes instances where the pre-Bootstrap-5 class "pull-right"
was missed during the upgrade. Most cases were on dropdown menus, and
in all of these cases the class can be removed because Bootstrap 5 menus
have better responsive behavior.

Other changes: Added "dropdown-item" classes to some menu items which
lacked it; Added some custom style for the "Filter" form in the patron
permissions toolbar.

To test, apply the patch and rebuild the staff interface CSS. Test that
the following menus look correct and work correctly:

- Catalog -> Bibliographic details page -> Holdings table: The "Edit"
  secondary menu shown for each item (requires that the LocalCoverImages
  system preference be enabled.
- Administration -> Z39.50 servers: The "Actions" menu for each server
  in the list of servers.
- Circulation -> Article requests: The "Actions" menu for each title and
  under each tab (New, Pending, and Processing).
- Tools -> Patron lists: "Actions" menu.
- Administration -> Plugins: "Actions" menu (requires that you have at
  least one plugin installed).
- Reports -> Saved SQL reports: The secondary menu on each saved
  report's "Run" button .
- Cataloging -> Rotating collections: "Actions" menu.
- Serials -> Subscription search results: In the "Open" tab, the
  secondary menu on the "Serial receive" button on each subscription. In
  the "Closed" tab, the "Actions" menu.
- Acquistions -> Suggestions: The secondary menu on each title's
  "Edit" button.
- Tools -> HTML customizations: The secondary menu on the "New
  entry" button; The secondary menu on each entry's
  "Edit" button; Edit entry -> The secondary menu on the "Save" button.
- Cataloging -> Stock rotation: The "Manage" menu on each rota.

A non-menu change:
- Patrons -> Patron details -> More -> Set permissions: CSS has been
  added to correctly align the "Filter" menu.

Sponsored-by: Athens County Public Libraries
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit b6c04435c5)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:44 +01:00
Jonathan Druart 6081e6972b
Bug 37761: Add focus on patron search when on the tab
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 4fb4b7527e)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:43 +01:00
Sukhmandeep Benipal 7973987d35
Bug 37761: Fix redirection on the tabs and buttons
To test:
- Apply the patch and enable the CurbsidePickup system preference if
  necessary.
- Properly testing requires testing data. You can run this command to
  REPLACE your curbside pickup data with sample data:

  bash <(curl -s https://gitlab.com/-/snippets/2572579/raw/main/test_curbside_pickups.sh)

- Go to Circulation -> Curbside pickups.
- Confirm that the tabs look correct. The first tab should be active
  by default.
- Confirm that the right content is displayed when you click each tab.
- Under the "Schedule pickup" tab, search for a patron.
- After you submit the search the page should reload and the "Schedule
  pickup" tab should be open.
- Go on each tab and try each button to verify you're staying on the
  same tab.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit ffb344c580)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:42 +01:00
Owen Leonard 2bd04b1899
Bug 37761: Use tab WRAPPER for circulation curbside pickups tabs
The tabs on Circulation -> Curbside pickups look broken because they
were not updated to use the tab WRAPPER markup. This patch revises the
template so that the tabs look correct and makes additional changes to
ensure that the correct tab is preselected.

To test:
- Apply the patch and enable the CurbsidePickup system preference if
  necessary.
- Properly testing requires testing data. You can run this command to
  REPLACE your curbside pickup data with sample data:

  bash <(curl -s https://gitlab.com/-/snippets/2572579/raw/main/test_curbside_pickups.sh)

- Go to Circulation -> Curbside pickups.
- Confirm that the tabs look correct. The first tab should be active
  by default.
- Confirm that the right content is displayed when you click each tab.
- Under the "Schedule pickup" tab, search for a patron.
- After you submit the search the page should reload and the "Schedule
  pickup" tab should be open.

Sponsored-by: Athens County Public Libraries
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 1311b8c01c)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:42 +01:00
Alexander Wagner e33343ccd6
Bug 38711: Wrong font-weight in tables during printing from staff interface
Fix last columns of tables to be printed in `bold`. This affects
various functions of Koha e.g. Notices and Slips, Pages etc.

1. Go to `Home / Tools / Additional content / Pages`
2. Select `Add new entry using text editor`
3. Add the following html

```html
<table>
   <tbody>
      <tr>
         <td>col 11</td>
         <td>col 12</td>
      </tr>
      <tr>
         <td>col 21</td>
         <td>col 22</td>
      </tr>
</tbody>
</table>
```

4. Save
5. Use the `Staff`-URL from `Additional content: Pages`
   to open the page in a new tab
6. Select `File / Print`
   (or fire up the dev console via F12 and apply the Print-css)
7. The entries `col 12` and `col 22` appear in bold face.
8. Apply the patch
9. Reload the page
10. The entries `col 12` and `col 22` appear in normal font.

Sponsored-by: Deutsches Elektronen-Synchrotron DESY, Library
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit ec0ced1652)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:41 +01:00
Emily Lamancusa 823faed9a5
Bug 38748: Pass the correct branchcode value to transfer slip
To test:
1. Find or create an item belonging to a library other than the
   logged-in library
2. Check the item in and print slip
--> The transfer slip says "Transfer to" but the library name is blank
3. Apply patch and restart_all
4. Cancel the transfer or find a different item
5. Check the item in and print slip
--> The library name now appears on the slip

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 4ee3accfb3)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:41 +01:00
Owen Leonard 8463b1097f
Bug 38667: Point of sale transaction history should not appear to be sortable
This patch adds configuration options to the Point of sale "Transactions
to date" and "Older transactions" tables so that they don't appear to be
sortable. Both have an option that makes their sorting fixed.

To test, apply the patch and go to Point of Sale.

- Enable 'EnablePointOfSale' and 'UseCashRegisters' system preferences.
- Add a least one cash register (Administration -> Cash registers).
- Add a least one debit type (Administration -> Debit types). Check "Can
  be sold."
- Go to the Point of Sale page.
  - Under "Items for purchase" click "Add" next to an item.
  - Under "Collect payment," fill out the form, including the cash
    register selection, and submit.
- Click "Transaction history for..." in the sidebar menu. (You may have
  to click "Cash summary for..." and then the name of the register you
  used in your transaction.
  - Check that the "Transactions to date" and "Older transactions"
    tables do not have sorting indicators in the table headers.

Sponsored-by: Athens County Public Libraries
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit eaeb05b5e1)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:40 +01:00
David Nind 1c69ac42c1
Bug 36609: Update index type labels for search engine configuration
This fixes the labels used for the type options when configuring
Elasticsearch search fields so that they use:
- sentence case
- the full name, instead of abbreviations (to make it clearer
  for translators)

Test plan:
1. Go to Administration > Catalog > Search engine
   configuration (Elasticsearch).
2. In the search fields tab, select the type column dropdown list
   for any field. Note the labels used for these options:
   - <empty entry> (the default option)
   - Std. Number
   - Call Number
3. Apply the patch.
4. Refresh the page.
5. Repeat step 2 and note that the option labels are now:
   - Default (instead of being blank)
   - Identfier (instead of Std. Number)
   - Call number (instead of Call Number)
6. Sign off D:

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit f549427e3d)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:39 +01:00
Owen Leonard 9723475364
Bug 38665: Fix markup error in Additional fields template title
The logic of the title tag construction should not result in a caret
preceding the first element on the Additional fields main page.

To test, apply the patch and go to Administration -> Additional fields.
There should be no caret appearing at the start of the page title
information:

Additional fields > Administration > Koha

Other pages (listing additional fields, adding additional fields, etc)
should have the correct title, e.g.

New field > Table 'aqbasket' > Additional fields > Administration > Koha

Sponsored-by: Athens County Public Libraries
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit ca170081b8)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:39 +01:00
Owen Leonard d69a007eb7
Bug 38077: Fix minor spacing issue in self checkout login page
This patch adjusts the markup and CSS of the self checkout login screen
so that form layout is consistent and readable. I have adjusted the
template conditional so that it re-uses more form elements like
<legend>.

To test, apply the patch and enable WebBasedSelfCheck if necessary.

- Set the SelfCheckoutByLogin system preference to 'cardnumber'
- Go to the self-checkout page (/cgi-bin/koha/sco/sco-main.pl)
  - The login form should be labeled "Log in to your account" followed
    by the label, form field, and submit button arranged vertically.
- Set the SelfCheckoutByLogin preference to "username and password"
- Reload the self-checkout page. The form should look the same with the
  addition of the password field.

Sponsored-by: Athens County Public Libraries
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 4d67788ad1)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:38 +01:00
Phil Ringnalda c01e819a61
Bug 38462: Remove unused code for pagination in OPAC authority search
The remote branch for bug 13618 started out when OPAC authority search did its
own pagination in a template block, then bug 2735 replaced that with
pagination_bar, the template var passed from the script, then at some point
before bug 13618 landed the second time, a rebase error put the template block
back in. And since it's not at all obvious it is dead code unless you look for
where "pagination" rather than "pagination_bar" is used, we've kept updating
it, and bug 36032 thought the way it used >> instead of > for next ought to be
fixed while one that was actually used was fixed.

Time to get rid of it, before we 'fix' it again.

Test plan:
 1. Without the patch, in the OPAC go to Authority Search and do a search that
    will return pages of results, like the letter a
 2. Note that the button for the next page uses ">" rather than the "Next >>"
    in the block this patch removes
 3. Apply patch, click the browser Back button, refresh page
 4. Verify that when you search for something that returns more than one
    page of results, the page navigation hasn't changed from what it was
    before the patch, telling you that what the patch removes was unused

Sponsored-by: Chetco Community Public Library
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 8c9fd0f5d3)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:37 +01:00
David Nind e59e6e6c44
Bug 38771: (follow-up) Fix the authentication log not enabled message
This corrects the display of the "Log not enabled" message for the
authentication module in the log viewer.

If either AuthFailureLog or AuthSuccessLog system preferences are
set to "Don't log":
- the "Log not enabled" warning icon is now shown
- clicking the triangle icon now links to the two system
  preferences

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 86e8835da0)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:37 +01:00
Roman Dolny 3f45fc8402
Bug 38771: Typo 'AuthScuccessLog' system preference
Typo in system preference 'AuthScuccessLog' -> 'AuthSuccessLog'.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 2f5c51383a)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:36 +01:00
Roman Dolny 656baf068f
Bug 38772: Typo 'minPasswordPreference' system preference
Typo in system preference 'minPasswordPreference' -> 'minPasswordLength'
in opac/opac-password-recovery.pl

There is no 'minPasswordPreference' system preference in database.
Bug 23816 added the capability to override minPasswordLength.

Test plan:
==========
1. Check 'minPasswordPreference' appearances:
   git grep -i 'minPasswordPreference' **/*
--> Note: only one in opac-password-recovery.pl; no one in sysprefs.sql
2. Apply the patch.
3. Repeat p. 1. Note there is not 'minPasswordPreference' at all.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 4b8db36d2a)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:35 +01:00
Yanjun Li c10aba6a2d
Bug 38302: Add delete confirmation dialog
To test:

1. Create a list in the staff interface
2. Go to lists
3. See "Your lists" tab and find "Delete" button in "Actions" col, click "delete", no confirmation dialog pop up
4. Create another list
5. Go to lists and view the list detail
6. See "Edit" dropdown and click "Delete Lists" button, see confirmation dialog pop up
7. Apply patch
8. Try step 1 through 3 again
9. "Delete" button in "actions" column has the same confirmation dialog, and delete function works

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Brendan Lawlor <blawlor@clamsnet.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 0a5591bdaa)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:34 +01:00
Pedro Amorim d84b3f4b23
Bug 38782: mock_userenv in API tests
Reorder logic slightly for each to only create the counter_file after the mock_userenv has taken place

prove t/db_dependent/api/v1/erm_custom_reports.t

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 1e7c49ab98)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:34 +01:00
Pedro Amorim 35b520f4b0
Bug 38782: Apply same fix for CounterFile.t
prove t/db_dependent/Koha/ERM/EUsage/CounterFile.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Edit: tidy (tcohen)
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit a297c42394)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:33 +01:00
Pedro Amorim 597a95d18b
Bug 38782: Remove concat in background process
The ud_provider->{report_type} is only defined on ->harvest_sushi, meaning it'll never be defined here.
We don't need this anyway. The filename should be the filename of the file being manually uploaded. We only need this concat logic for COUNTER files being generated by Koha following a SUSHI harvest, and that works.
This also gets rid of a warning when running the tests

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 0231911c98)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:32 +01:00
Pedro Amorim 74189746c7
Bug 38782: Mock userenv->{number}
prove t/db_dependent/Koha/BackgroundJobs/ErmSushiHarvester.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Edit: tidy (tcohen)
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit c3e8b9b851)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:31 +01:00
Pedro Amorim b08bc8fc60
Bug 36039: (QA follow-up): Improve audit messages
Improve messages clarity.
Show success message if no schema diff was found from audit.
Code refactor to ensure the title+message shown in UI is the same as the one shown in CLI and are all translatable.

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 7834d25fb4)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:31 +01:00
Pedro Amorim 1d6fb756f9
Bug 36039: (QA follow-up): Address i18n for print messages
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 42c1e109af)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:30 +01:00
Martin Renvoize dff1628187
Bug 36039: (follow-up) Move view logic to script/template
This patch updates the module as suggested by David to handle just the
diff code and leaves the display logic up to the templates and script.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: JesseM <jesse@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 534fba2691)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:29 +01:00
Pedro Amorim 501b1860ca
Bug 36039: New 'datatabase audit' tab in about page
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: JesseM <jesse@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 6940167048)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:28 +01:00
Pedro Amorim b7c7075dd4
Bug 36039: Move audit_database script logic to a dedicated module
Test plan #1 ensure same script functionality (same as bug 34064):
0. Apply patch
1. vi ./installer/data/mysql/kohastructure.sql
2. Comment out some columns, change NULL status, or whatever you like
3. perl misc/maintenance/audit_database.pl \
    --filename /kohadevbox/koha/installer/data/mysql/kohastructure.sql
4. Note that the output includes SQL commands to change the database
to match the new kohastructure.sql

5a. Try using koha-foreach and note that the database name appears above
the database comparison
5b. koha-foreach "perl misc/maintenance/audit_database.pl \
    --filename /kohadevbox/koha/installer/data/mysql/kohastructure.sql"

Test plan #2:
1. After doing test plan #1, access the new 'database audit' tab, visit:
<staff_url>/cgi-bin/koha/about.pl?tab=database
2. Ensure the output is the same as test plan #1

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: JesseM <jesse@bywatersolutions.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 09bb85409d)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:28 +01:00
Lucas Gass 36bf9321ff
Bug 37398: Fix test in basic_workflow.t
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 2350a2ada8)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:27 +01:00
Lucas Gass a4552b54a7
Bug 37398: Add CSS for the important class
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 9b7dcb46ea)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:26 +01:00
Jonathan Druart fa84dfb770
Bug 37398: Adjust tests
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 3fe252f6a8)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:26 +01:00
Jonathan Druart 7eb1ed012c
Bug 37398: Do not rely on the columns names but data type instead
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit d2a6915010)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:25 +01:00
Lucas Gass ee18a0549d
Bug 37398: Adjust CSS for flatpickr
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 125d8ec1cf)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:24 +01:00
Lucas Gass 9521ce51bf
Bug 37398: Add set to today function to calendar.inc
To test:
1. Try editing some items with a empty value in the flatpickr.
2. Make sure the empty date fields get a date set to today when you click on the empty field.
3. Try a datetime field, making sure the datetime is correctly set.

Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 0d5bd311d4)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:24 +01:00
Lucas Gass 7e6d3f4c3f
Bug 37398: Add a unit test
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit b2f317a767)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:23 +01:00
Lucas Gass 2d4b406742
Bug 37398: Make sure subfield and subfield_date are defined
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit d32218fb68)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:22 +01:00
Lucas Gass b5e8bcbd81
Bug 37398: Adjust CSS for wrapped flatpickr
Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit f049a13ef8)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:21 +01:00
Lucas Gass d2bfa731c8
Bug 37398: Make date and date time fields have date picker by default
To test:
1. APPLY PATCH, restart_all
2. Pick a framework, I choose BKS in k-t-d
3. Make sure that a few date and datetime fields are exposed in the editor.
4. On additem.tt a date picker should be instantiated on the date or datetime fields.
5. Make sure the date pickers work on each field.
6. If it is a datetime field you should have the option to add hours and minutes. ( datelastseen )
7. Edit the framework and remove the dateaccessioned.pl plugin from any of these date fields.
8. Even without the dateaccessioned.pl plugin a date picker should be present on the field.
9. Add the dateaccessioned.pl plugin to a non date/datetime field.
10. Make sure the dateaccessioned.pl plugin works properly on the non date/datetime field.
11. Mark one of the date/datetime fields as mandatory, make sure it still acts as mandatory.
12. Hide date/datetime from the editor, make sure it hides properly.

+----------------------+-------------+
| COLUMN_NAME          | COLUMN_TYPE |
+----------------------+-------------+
| dateaccessioned      | date        |
| replacementpricedate | date        |
| datelastborrowed     | date        |
| datelastseen         | datetime    |
| onloan               | date        |
+----------------------+-------------+

Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit aa4ee79f6e)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:21 +01:00
Pedro Amorim 868cfccf44
Bug 36627: (QA follow-up): Rename borrowernumber -> patron_id
To test:
$ prove t/db_dependent/api/v1/erm_counter_logs.t

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 15803e4f29)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:20 +01:00
Katrin Fischer b2a45e2e5f
Bug 36627: Fix typo "embeded"
A search turned up more of these in other files. Fixed as well.

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 3b86455e02)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:19 +01:00
Jonathan Druart 3ce6813527
Bug 36627: (follow-up) Use patron_to_html in 'Imported by' column
We don't need those 2 lines

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 5d6af90d76)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:19 +01:00
Pedro Amorim 891e4ef163
Bug 36627: (QA follow-up): Add missing tests
1) Apply patch
2) $ yarn api:bundle
3) $ prove t/db_dependent/Koha/ERM/EUsage/CounterLog.t
4) $ prove t/db_dependent/api/v1/erm_counter_logs.t

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 8a314ea750)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:18 +01:00
Pedro Amorim 685c34be80
Bug 36627: Add tests
k-t-d, from /kohadevbox/koha, run:
yarn run cypress run --spec "./t/cypress/integration/ERM/DataProviders_spec.ts"

Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 7faa42505f)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:17 +01:00
Pedro Amorim d9235cee09
Bug 36627: Use patron_to_html in 'Imported by' column
For consistency, and to avoid 'null koha' for a file imported by
the koha user (no first name).

Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit f70a5ffc67)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
2025-03-24 18:12:17 +01:00