Commit graph

55054 commits

Author SHA1 Message Date
Phil Ringnalda
06f17d9f6a
Bug 37794: Fix form that POSTs without an op in Holds to pull
We intend not to have forms with method="post" without an op variable (so we
can check that the op starts with "cud-" as part of the CSRF protection), but
because of bug 37728 some were missed.

In Holds to pull that's the form which lets you change from the default
starting and ending date. Switching that to a GET at least lets you refresh
the page without getting a browser warning about resending a POST and maybe
having your credit card double-charged.

Test plan:
1. Without the patch, Circulation - Holds to pull - change the start date to
   something earlier and click Submit
2. Refresh the page, get a warning about resubmitting data
3. Apply patch, Circulation - Holds to pull - change the start date to
   something earlier and click Submit
4. Refresh the page, no warning

Sponsored-by: Chetco Community Public Library

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 16:36:17 +02:00
48d8ac7bef
Bug 37745: (follow-up) Remove "btn-default" from two controls.
If we use "btn-link" we don't need "btn-default".

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 16:36:16 +02:00
7e4db79ce6
Bug 37745: Remove more duplicated class attributes
Found using `egrep 'class=[^>]+class=' **/*.tt **/*.inc`

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 16:36:16 +02:00
d53b77fadb
Bug 37745: Fix change framework
Same problem as the previous patch when we try to change the bib
framework while editing a bib record

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 16:36:15 +02:00
593bad6502
Bug 37745: (bug 35402 follow-up) Fix "Rows per page" dropdown items
There were 2 class attributes.

Test plan:
Create a new report and run it
Use the "Rows per page" dropdown to select another value
=> Without this patch nothing happens
=> With this patch applied the page is reloaded and the correct number
of rows is displayed

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 16:36:15 +02:00
bae6560a26
Bug 33907: Improve translation of title tags: OPAC part 1
This patch updates a batch of OPAC templates so that title tags can
be more easily translated. Some templates have been updated for
consistency as well: Harmonizing page title, breaddrumb navigation, and
page headers.

To test, apply the patch and confirm that the following pages have
correct title tags:

- Log in to the OPAC by navigating directly to a user page like
    /cgi-bin/koha/opac-user.pl
- From your user summary page, click "Charges."
- Check the advanced search page.
- Search for a bibliographic record and view the details, and then click
  "MARC view" and "ISBD view."
- From this page click "Save to your lists" and check the title in the
  popup window."
- Still on a detail page, click "Add to your cart." Open the cart and
  check that page.
- Go to authority search (must have OpacAuthorities enabled).
  - Perform an authority search which will return results.
  - View the detail page for one of the results, and check the MARC view
    as well.
- With UseCourseReserves enabled, view the course reserves page, then
  the course reserve detail page.
- Search for a subscription which has patron notification enabled.
  - View the detail page, then open the "Subscriptions" tab. Click "More
    details."
    - On this page you should see a "Subscribe to email notification"
      button. Click it to open the subscription page.
- Check both /cgi-bin/koha/opac-browse.pl and
  /cgi-bin/koha/opac-browser.pl. Whether or not the features are enabled
  you should be able to check the title.
- Check /cgi-bin/koha/ilsdi.pl as well as one or more views linked to on
  that page.
- Navigate to a page in the OPAC which doesn't exist to test the error
  page template.
- Go to Administration -> System preferences and enable the
  OpacMaintenance preference.
  - Go to the OPAC and check the system maintenance page.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:52 +02:00
058a09b7d9
Bug 37046: Use template wrapper for OPAC curbside pickup tabs
This patch updates the OPAC curbside pickups template to use WRAPPERs
for the Bootstrap tabs markup.

To test, apply the patch and enable the "CurbsidePickup" system
preference if necessary.

- Log in to the OPAC and click the "Curbside pickups" tab in the sidebar
  of the user summary page.
  - With no curbside pickup policy defined, you shoul see a single tab,
    "Your pickups" and the message "No curbside pickups."
- In the staff interface go to Administration -> Curbside pickup.
  - Configure curbside pickups for at least one branch.
- Return to the OPAC and refresh the curbside pickups page.
  - You should now see a "Schedule a pickup" tab along with the "Your
    pickups" tab, and it should be active by default.
  - Schedule a pickup.
    - When the page refreshes, the "Your pickups" tab should now be
      active by default.

Sponsored-By: Athens County Public Libraries
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:52 +02:00
Lari Strand
9058725132
Bug 37033: Plugin intranet_js won't load in Cart popup (intranet-bottom.inc missing)
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:51 +02:00
David Nind
ca9297348e
Bug 34325: Rename "Barcode" to "Item barcode" on manual invoice and credit forms
The forms for adding a manual invoice and credit for patrons (in
the accounting section) have a field for entering a barcode. This
can cause confusion, as it is not clear if it is for an item
barcode or the patron card number.

This patch changes the form labels and error message for the
manual invoice and credit forms to clarify that this is for an
item barcode. Related table column headings are left as "Barcode".

Test plan:
1. Go to a patron's record: Patrons > search for a patron >
   select a patron.
2. Go to Accounting > Create manual invoice.
3. Note that there is a label "Barcode:"
4. Enter details for a manual invoice and 'Save':
   - Type: Manual fee
   - Barcode: an item barcode, for example 39999000011418
   - Amount: 15
   ==> Result: Manual invoice saved
5. Repeat step 4, but enter a patron card number for the barcode.
   For example: 23529000651225.
   ==> Result: You get an error message
               "Error: Invalid barcode entered, please try again".
6. Enter details for a manual credit and 'Save':
   - Credit type: Credit
   - Barcode: an item barcode, for example 39999000011418
   - Amount: 5
   ==> Result: Manual credit saved.
7. Check the tables listing transactions - note that the column
   heading is "Barcode". (Tables are Transactions, Make a payment,
   and Transactions > Details (under the Actions column).
8. Apply the patch.
9. Repeat steps 4 to 7. Note that:
   - The label is now "Item barcode:" for the manual invoice and
     manual credit forms.
   - The error message in step 5 is now "Error: Invalid item
     barcode entered, please try again".
   - For the tables in step 8, the column headings remain as
     "Barcode" - there is generally enough context that it doesn't
     need to be changed.
10. Sign off D:

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Brendan Lawlor <blawlor@clamsnet.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:51 +02:00
Jennifer Sutton
7d04a34064
Bug 32218: Update string grammar in identity-providers.tt
Adiministration > Identity Providers > New identity provider under allow
OPAC the language string was updated.

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:50 +02:00
5a249bc5ea
Bug 37491: Remove duplicate asset import
This patch removes a duplicated asset import from import_from_kbart_file.inc

Test plan:
1) Apply patch and look at import_from_kbart_file.inc to observe that where previously there were two uses of "[% Asset.js("js/job_progress.js") | $raw %]" and now there is just one

Signed-off-by: Sam Lau <samalau@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:49 +02:00
Caroline Cyr La Rose
1cd7339621
Bug 37436: Move EmailPatronWhenHoldIsPlaced to Holds policy sysprefs
This patch moves the EmailPatronWhenHoldIsPlaced system preference
from Circulation > Patron restrictions to Circulation > Holds policy.

To test:
1. Apply patch
2. Go to Administration > System preferences > Circulation > Holds
   policy
   --> EmailPatronWhenHoldIsPlaced should be right after
       emailLibrarianWhenHoldIsPlaced

Signed-off-by: hebah <hebah@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:49 +02:00
Katrina Bassett
db9e828a43
Bug 34183: Remove MARC format hint from OPACResultsLibrary system preference description
Test Plan
1. Navigate Koha Administration
2. Search for OPACResultsLibrary
3. Note that sentence "Please note that this feature is currently available for MARC21 and UNIMARC." is removed

Signed-off-by: Chloe Zermatten <chloe.zermatten@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:48 +02:00
6bf3bd942f
Bug 37515: Add common class to all places where an item type image is shown
This patch adds an "itemtype-image" class to templates in all places
where we show itemtype images. This patch affects both the OPAC and the
staff client.

To test you should have icons associated with multiple item types.

- Apply the patch and go to Administration -> System preferences
- Search for "itemtype"
  - noItemTypeImages should be set to "Show"
  - OpacNoItemTypeImages should be set to "Show"
  - BiblioItemtypeInfo should be set to "Show"
- Search for "usercss"
  - Add an obvious style rule for item type images to IntranetUserCSS
    and OPACUserCSS, e.g.

    .itemtype-image { border: 3px solid orange; }

- In the staff interface, check the following pages to confirm that your
  custom style is visible:

  - Administration -> Item types
    -> Edit
  - Administration -> Authorized values -> CCODE -> Edit a CCODE
  - Advanced search
    - Search results
    - Bibliographic details
  - Place hold
  - Lists -> List contents view (must set the item-level_itypes
    preference to "bibliographic record")

- In the OPAC:
  - Advanced search
    - Search results
      - Bibliographic details
  - Place hold
  - Log in as a user with checkouts ->
    - View the checkouts tab on the patron summary page
  - Lists -> List contents view (must set the item-level_itypes
    preference to "bibliographic record")

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>
2024-09-02 12:13:48 +02:00
8f0dc36f0d
Bug 37490: Add a test to detect when yarn.lock is not updated
to test...

1/ set koha repo to state where yarn.lock is not updated

    $ git reset --hard 67db70d4

2/ run test, observe FAIL

    $ prove ./xt/verify-yarnlock.t
    ./xt/verify-yarnlock.t .. error Your lockfile needs to be updated, but yarn was run with `--frozen-lockfile`.
    ./xt/verify-yarnlock.t .. 1/1
    #   Failed test 'verify yarn.lock file is updated correctly'
    ...
    Result: FAIL

3/ set koha repo to state where yarn.lock is updated

    $ yarn install

4/ note yarn.lock is now updated

    $ git status
    ...
    modified:   yarn.lock

5/ run test, observe SUCCESS

    $ prove -v ./xt/verify-yarnlock.t
    ./xt/verify-yarnlock.t ..
    ok 1 - verify yarn.lock file is updated correctly
    All tests successful.
    Files=1, Tests=1,  1 wallclock secs ( 0.02 usr  0.01 sys +  1.16 cusr  0.27 csys =  1.46 CPU)
    Result: PASS

Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:47 +02:00
6c162a8a95
Bug 33731: Allow for default sounds on SCO page
To test:
1. APPLY PATCH
2. Enable AudioAlerts system preferencce
3. Set up some audio alerts to trigger on the SCO page. ( I used #sco_main for east testing)
4. Make sure the sounds work properly.

Note: It is not my favorite thing to duplicate these assets for intranet and OPAC, is there a better way?

	modified:   koha-tmpl/opac-tmpl/bootstrap/en/modules/sco/sco-main.tt
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/IM_notification.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/beep.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/call.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/critical.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/device_connect.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/device_disconnect.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/ending.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/fail.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/incoming_call.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/loading.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/loading_2.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/maximize.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/minimize.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/new_mail_notification.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/opening.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/panic.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/popup.ogg
	new file:   koha-tmpl/opac-tmpl/bootstrap/sound/warning.ogg

Signed-off-by: Laura_Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:46 +02:00
8deb7f7795
Bug 37691: Improve visibility of password expiration reset link
This patch moves the password expiration reset link into the error box
so that it is more prominent.

To test, apply the patch and rebuild the staff interface
CSS:
https://wiki.koha-community.org/wiki/Working_with_SCSS_in_the_OPAC_and_staff_interface

Try to log in to the staff interface as a user whose password has
expired. You will probably have to use SQL to update a patron record
directly, e.g.

UPDATE borrowers SET password_expiration_date = '2022-01-01' WHERE borrowernumber = X;

When you submit your login details the page should reload with an error
message: "Error: Your password has expired." Within the red dialog you
should see the "You must reset your password" link.

Sponsored-by: Athens County Public Libraries
Signed-off-by: Sam Lau <samalau@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:46 +02:00
068d0c43c1
Bug 33925: Improve translation of title tags: Serials
This patch updates serials templates so that title tags can be more
easily translated. Some templates have been updated for consistency as
well: Harmonizing page title, breaddrumb navigation, and page headers;
Adding "page-section" <div> where it was lacking.

To test, apply the patch and confirm that the following pages have the
correct title tags:

- Serials home
  - Serials search results
    - Subscription details
      - Subscription edit
        - Search for vendor
        - Search for bibliographic record
      - Subscription renew
      - Serial collection
      - Create and modify routing list
        - Preview routing list
          - View routing slip
      - Claims
      - Check expiration
      - With a subscription which has manual history enabled, click the
        "Edit history" link under the "Planning" tab.
     - Select multiple serial search results and batch edit
  - New subscription
  - Manage frequencies: Create and edit
  - Manage numbering patterns: Create and edit

Signed-off-by: Loïc Vassaux-Artur <loic.vassaux-artur@outlook.fr>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:45 +02:00
6bc7565552
Bug 36945: Fix several missed instance of breadcrumb WRAPPER use
This patch corrects some templates which never got the breadcrumb
WRAPPER update. Some breadcrumbs and page titles have been updated to be
more consistent with page headings.

To test, apply the patch and enable the "CatalogConcerns" system
preference if necessary. Check the following pages to confirm that the
breadcrumbs menu looks correct and that breadcrumbs are consistent with
page titles and page headings.

- Circulation -> Upload offline circulation file (.koc)
  - Upload file -> Add to offline circulation queue
  - View pending offline circulation actions
- Cataloging -> Cataloging concerns
- Reports -> Cash register stats

Sponsored-By: Athens County Public Libraries
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:45 +02:00
a48c3cafd2
Bug 37081: Reword button on addorderiso2709.tt
To test:
1. Go to Acquisition and create or find a vendor.
2. Create a new basket.
3. Add to basket -> from a new file
4. Upload a .mrc file and stage fro import.
5. Add the files to your basket.
6. For each item in the basket notice the button set which includes MARC, Card, and Add order.
7. APPLY patch and reload the page.
8. Add order should now be New order.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:44 +02:00
0d69fc6090
Bug 37493: [DONT PUSH] Test only - Force test fail
Apply this patch only, run:
1) cypress run --spec "t/cypress/integration/flatpickr_spec.ts"
2) run `git status`.
  Notice t/cypress/screenshots/ and t/cypress/videos/ show
3) Apply 2nd patch. Repeat 2). Notice its empty

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:44 +02:00
Laura_Escamilla
d9b857ecc0
Bug 34185: Capitalized OPAC in OpacItemLocation syspref
To test:
1. In K-T-D git grep for “OpacItemLocation”
    1. Notice that related XSLT / XSL scripts are not coming up. Only .pm, .pl and .sql scripts.
2. Git grep for “OPACItemLocation”. Note that XSLT/XSL files show up but not the .pm, .pl and .sql scripts.
3. Apply the patch. Updatedatabase. Restart_all
4. Git grep for “OPACItemLocation”
    1. Notice that both the XSLT/XSL files in addition to the .sql, .pm and .pl scripts are now showing up.
5. Sign off and have a spectacular day :D

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:43 +02:00
084ed6e322
Bug 37004: Add branchcode as HTML class to each grouped result in search results
To test:
1. Apply patch and restart_all
2. Do a catalog search that returns results.
3. Using the browsers dev tools inscpet the page and look for the 'available_items_loop_items' class in the 'Location column'.
4. Each child <li> element should have a class that is the branchcode.
5. Make sure that branchcode is correct.
6. Change the StaffSearchResultsDisplayBranch system preference. Make sure that each branchcode is still correct.
7. Change the system preference 'noItemTypeImages' to 'Dont show'.
8. Make sure the branchcode is still correct.
9. Checkout an item that would show up in these search results.
10. Do steps 3-8 again excpet this time look for the HTML element 'onloan_items_loop_items'.
11. Put some items in transfer that would show up in these search resultss.
12. Do steps 3-8 again excpet this time look for the HTML element 'other_items_loop_items'.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:42 +02:00
ca51e5d642
Bug 35239: (follow-up) Correct more missing label inconsistencies
This patch corrects a couple more labels and modifies the process of
cloning a patron attribute field so that each new cloned row has
matching label and input.

To test, apply the patch and, if necessary, create some patron attribute
types:

- Go to Administration -> Patron attribute types
- Create at least two new patron attribute types.
- Go to Tools -> Batch patron modification.
- Submit a batch of patrons for batch modification
- In the list of fields to modify, test that clicking each label gives
  focus to the corresponding field (except date fields, we need to fix
  that globally).
- Click "New" next to the patron attribute field.
  - A copy of the field should be created. Test that the new field also
    has matching label and <select>

Sponsored-by: Athens County Public Libraries
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:42 +02:00
Catalyst Bug Squasher
d5388670c3
Bug 35239: Missing form field ids in batch patron modification template
Test Plan
1. Tools > Batch patron modification
2. List valid card number in text box
3. [Continue]
4. Edit patrons form, click on input box label
5. Matching input box gets focus

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-09-02 12:13:41 +02:00
278df1790d
Bug 36085: (QA follow-up) Tidy members/memberentry.pl
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:34 +02:00
PerplexedTheta
9d48763c77
Bug 36085: Only superlibrarians can protect patrons
A drive-by patch which hopes to resolve bug 36085 by only allowing superlibrarians
to protect or unprotect patrons.

Test plan:
a)  prepare two koha staff users:
        1)  a superlibrarian
        2)  a user that only has permission to edit patrons
b)  when logged in as the user prepared in step a2 (non-superlibrarian),
    then go to edit any patron
        *)  note how you can set the protected yes/no radios
c)  apply the patch
d)  repeat steps a-b as this same user
        *)  note how you can now no longer see the protected yes/no radios
e)  log in as the user prepared in step a1 (superlibrarian), then repeat
    steps a-b
f)  note how the protected yes/no radios are back

Signed-off-by: Jan Kissig <jkissig@th-wildau.de>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:34 +02:00
be6e795b43
Bug 34440: (QA follow-up) Tidy changes to t/db_dependent/Koha/Item.t
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:33 +02:00
33d5ab614c
Bug 34440: Unit test for change to Koha::Item
This adds a unit test for the new preparation_period handling introduced
into the find_booking method of Koha::Item.

Sponsored-by: Cuyahoga County Public Library <https://cuyahogalibrary.org/>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:33 +02:00
fe71a9f84c
Bug 34440: Enforce lead/trail restrictions
This patch adds rule enforcement into the user interface. When
attempting to make a booking now, instead of just visually displaying
the lead and trail period and highlighting when an overlap appears, we
now block the ability to select a date when such an overlap case is
found.

Sponsored-by: Cuyahoga County Public Library <https://cuyahogalibrary.org/>
Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:32 +02:00
cbf4faf8d4
Bug 34440: Highlight overlaping lead and trail periods
This adds a further distinction between a lead/trail period and whether
it would conflict with an existing booking or not.

Sponsored-by: Cuyahoga County Public Library <https://cuyahogalibrary.org/>
Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:31 +02:00
34dca2378b
Bug 34440: (follow-up) Enable flatpickr only once rules are populated
Sponsored-by: Cuyahoga County Public Library <https://cuyahogalibrary.org/>
Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:31 +02:00
093597902f
Bug 34440: Update for change to /circulation_rules
We updated the preceeding bug that introducing the /circulation_rules
endpoint such that it always returns an array.

Sponsored-by: Cuyahoga County Public Library <https://cuyahogalibrary.org/>
Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:30 +02:00
083330d5c5
Bug 34440: Use circulation_rules for buffer timing
Sponsored-by: Cuyahoga County Public Library <https://cuyahogalibrary.org/>
Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:30 +02:00
46ef8b1594
Bug 34440: Simplify modal code using isSameOr* functions
Sponsored-by: Cuyahoga County Public Library <https://cuyahogalibrary.org/>
Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:29 +02:00
7174d05774
Bug 34440: Add isSameOrBefore dayjs plugin
Sponsored-by: Cuyahoga County Public Library <https://cuyahogalibrary.org/>
Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:28 +02:00
bb00bed180
Bug 34440: Add handling for lead/trail display
This patch adds code to insert classes into the flatpickr for lead and
trail time on bookings and includes some scss additions to highlight
said periods in display.

Sponsored-by: Cuyahoga County Public Library <https://cuyahogalibrary.org/>
Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:28 +02:00
3475ef06d4
Bug 34440: Add itemtype selection to bookings modal
Whilst we still don't need to know the specific item we will need to
know the itemtype to be able to fetch the correct circulation rules for
adjusting the datepicker with lead and trail times.

This patch adds such a picker option. You should be able to select the
item or itemtype in either order.. selecting itemtype first will limit
the items list to options available (and 'Any item').. upon selecting a
specific item the itemtype selector should become disabled and reflect
the itemtype of the item selected.

Sponsored-by: Cuyahoga County Public Library <https://cuyahogalibrary.org/>
Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:27 +02:00
620527f971
Bug 34440: Take preparation period into account at checkout
This patch ensures we catch checkouts that would interfer with the
preparation period set for an existing booking by adding said period to
the bookings search.

We also reduce the proposed due date for the checkout to be confirmed by
the preparation period for the item.

Test plan
1) Set a booking preparation period for an itemtype
2) Add a booking for an item with that itemtype to fall beyond the due
   date that the item would be assigned if you were to check it out now
   to your test user, but within the number of days you've set for your
   preparation period.
3) Attempt to check the item out to your test user.
4) Note that we catch the booking and warn and that the latest return
   date suggested take the preparation period into account.

Sponsored-by: Cuyahoga County Public Library <https://cuyahogalibrary.org/>
Signed-off-by: Kristi Krueger <KKRUEGER@cuyahogalibrary.org>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:27 +02:00
f053ca032b
Bug 34440: Add lead and trail time to circulation rules
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 16:41:26 +02:00
23d98a4a8a
Bug 37177: "item" should be "record" in list page
This patch rewords areas of the lists and cart templates so that the
term "record" is preferred over "item" when referring to a bibliographic
record.

To test, apply the patch and go to Lists in the staff interface.

- If necessary, create a new list.
- From the list contents view, click "Add records" in the toolbar.
  - Submit some valid barcodes and biblionumbers
  - After adding biblionumbers you should see the message "The record
    ( [number] ) has been added to the list"
  - After adding barcodes you should see the message "The record for
    this item ( [barcode] ) has been added to the list"
- Click "Add records" again
  - Submit some of the same barcodes and biblionumbers
    - You should see these messages:
      - "The record for this item ( [barcode] ) has not
         been added to the list. Please verify it is not already in the
         list."
      - "The record ( [number] ) has not been added to the
        list. Please verify it is not already in the list.
- Check the checkbox for one or more titles on your list and click
  "Remove selected"
  - You should see the message, "The record has been removed from the
    list."
- Perform a catalog search and from the results screen, select one or
  more results and add them to the cart.
  - Open the Cart and confirm that the controls at the top of the table
    of titles reads "Selected records: ..."

Sponsored-by: Athens County Public Libraries
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 12:45:46 +02:00
Laura_Escamilla
d5039cc657
Bug 37758: Add descriptive labels for accessibility
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 12:45:46 +02:00
88f65287ef
Bug 37740: Fix saved SQL reports tab switching
The tabs on the saved SQL report page are not really full tabs, they're
just styled that way. There is only one tab "panel," and clicking each
tab triggers a DataTable filter so that the tab only shows the relevant
data.

The problem with this setup is that when Bootstrap tries to "switch"
tabs, it wants to hide the initial tab and then show the new one. There
is no "new" one here.

The attached patch solves this problem by adding a CSS rule to
guided_reports_start.tt with higher specificity than our global CSS
making the relevant tab pane visible at all times.

To test, apply the patch and go to Reports -> Use saved.

- If necessary, create multiple SQL reports and assign them to different
  report groups (Accounts, Acquisitions, Catalog, etc.).
- Test that tab switching works:
  - The tab should be style as "active" after you click it.
  - The table of reports should be filtered to include only reports in
    the relevant report group.

Signed-off-by: Chloe Zermatten <chloe.zermatten@ptfs-europe.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 12:45:45 +02:00
e6a1d65c9a
Bug 37741: Do not send cookie back from error pages
This change stops the cookie from being sent back from error pages,
so that backcalls that cause errors don't overwrite the existing cookie
used by the foreground request page.

Test plan:
0. Apply the patch and koha-plack --reload kohadev
1. Set syspref IntranetFavicon to http://localhost:8081/cgi-bin/koha/bad.jpg
2. Open browser developer tools
3. Go to http://localhost:8081/cgi-bin/koha/mainpage.pl
4. Open the Network tab, disable the cache, and shift refresh
5. Notice that bad.jpg fails to load with a 404
6. Try to login to Koha
7. Confirm login works

*. Extra points if you note that the cookie returned by the first
mainpage.pl request is used for the bad.jpg lookup and the second
mainpage.pl request.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-30 12:45:45 +02:00
7342209b34
Bug 37048: Use template wrapper for self checkout page
This patch updates the OPAC's self checkout page template to use
WRAPPERs for the Bootstrap tabs markup.

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

- Navigate to the self checkout page
  (http://127.0.0.1:8080/cgi-bin/koha/sco/sco-main.pl)
  - Start checking out to a patron
    - You should see three tabs, "Checkouts", "Holds", and "Charges."
      The tabs should look correct and work correctly.

Sponsored-By: Athens County Public Libraries
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-29 18:16:24 +02:00
34ff421c1c
Bug 36919: Remove yet another warning from Koha/Object.t
DBIx::Class::Storage::DBI::insert(): Missing value for primary key column 'currency' on Currency - perhaps you forgot to set its 'is_auto_increment' attribute during add_columns()? Treating 'currency' implicitly as an autoinc, and attempting value retrieval at /kohadevbox/koha/Koha/Object.pm line 172
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-29 18:16:23 +02:00
f14db22d8a
Bug 36919: Remove another warning from Koha/Object.t
C4::Context->userenv not defined! at /kohadevbox/koha/Koha/Patron.pm
line 1890.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-29 18:16:23 +02:00
5c905109db
Bug 36919: Remove a warning from Koha/Object.t
Use of uninitialized value in numeric eq (==) at /kohadevbox/koha/Koha/Patron.pm line 446.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-29 18:16:22 +02:00
bec73ea2a8
Bug 37759: Duplicated "Set library" menu item caused by bad merge
This patch removes an unnecessary block of markup accidentally left
behind during a rebase of Bug 35402, removing a duplicate "Set
library..." menu item from the header menu in the staff interface.

After the batch, users who have permission to change their logged-in
library should see only a single "Set library..." menu item in the user
menu found on the right-hand side of the header menu.

Signed-off-by: Roman Dolny <roman.dolny@jezuici.pl>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-29 18:16:22 +02:00
b1993dcd71
Bug 34486: (QA follow-up) Tidy changes to opac/opac-detail.pl
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
2024-08-29 18:16:21 +02:00