]> git.koha-community.org Git - koha.git/log
koha.git
22 months agoBug 32194: Capitalize "No" values for the patron categories "Can be guarantee" column
David Nind [Mon, 14 Nov 2022 21:14:40 +0000 (21:14 +0000)]
Bug 32194: Capitalize "No" values for the patron categories "Can be guarantee" column

This fixes the display of the patron categories "Can be guarantee"
column so that "No" values have a capital "N".

Test plan:
1. Go to Administration > Patrons and circulation > Patron categories.
2. Note that for the "Can be guarantee" column, it shows "Yes" values
   with a capital "Y" and "no" values with a lowercase "n".
3. Apply the patch.
4. Refresh the page.
5. Note that any "No" values now have a capital "N".
6. Sign off D:

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit ecbcc2884c5c7b01aa90ac305da7b7c413ec9500)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 32320: Remove text-shadow from header menu links
Owen Leonard [Tue, 22 Nov 2022 12:10:20 +0000 (12:10 +0000)]
Bug 32320: Remove text-shadow from header menu links

This patch unsets the text-shadow style on links in the header menu.
This makes the links look a little crisper. The style is inherited from
Bootstrap's defaults and is incorrect for our design.

To test, apply the patch and rebuild the staff interface CSS.

View any page in the staff interface to confirm that header menu links
look correct.

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 84f9e308102d432b0154aba89aec5407c2228e83)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 32302: (follow-up) Hide ISBN label when list sent from the staff interface
David Nind [Wed, 30 Nov 2022 23:48:25 +0000 (23:48 +0000)]
Bug 32302: (follow-up) Hide ISBN label when list sent from the staff interface

This makes the same change to the staff interface. Lists sent
from the staff interface hide the ISBN label in the email message
when there are no ISBNs for a record.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 69ddb83f41cfc5c9eb6b4e483bca9316bac98db8)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 32302: Hide "ISBN" label when no ISBN data when sending list
David Cook [Wed, 30 Nov 2022 22:52:55 +0000 (09:52 +1100)]
Bug 32302: Hide "ISBN" label when no ISBN data when sending list

There is a logic mistake in the opac-sendshelf.tt template where
we test if the "ISBN" key exists in the "BIBLIO_RESULT" hash when
we should really be testing if the arrayref returned by "ISBN" is
empty or not, since that "ISBN" key always exists and contains at least
an empty arrayref.

Test plan:
1. Apply patch and restart your Koha Starman
2. Create a public list containing records with 020 MARC fields and
records without 020 MARC fields
3. View the list in the OPAC
4. Click "Send list" and email it to yourself
5. Note that only records with 020 MARC fields with show "ISBN:"
in the email output

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 44366c09858364ac56fd37b5434bc77e7e48fe94)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 32417: Allow NULL in biblionumber in $order->store
Marcel de Rooy [Wed, 7 Dec 2022 13:27:02 +0000 (13:27 +0000)]
Bug 32417: Allow NULL in biblionumber in $order->store

If we are cancelling an order and call DelBiblio, we should
clear the biblionumber but not be crashing on it in ->store.

The absence of the clear prevented the crash. One bug sometimes
solves another one.

Test plan:
Create basket, order line.
Delete order with biblio record.
Verify result and logfile.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit d9186728919a1a41d56c4c8686e0197c746f7fa1)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 32417: Add unit test
Marcel de Rooy [Wed, 7 Dec 2022 13:51:14 +0000 (13:51 +0000)]
Bug 32417: Add unit test

Test plan:
Run t/db_dependent/Koha/Acquisition/Order.t
This test should fail without the follow-up and pass with it.
* not ok 53 - No croak on missing biblionumber when cancelling an order

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit d7c1d52051a3cb5f6ae3be9abb0e9e7aa1f9ece5)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 31160: Required fields in patron api
Matt Blenkinsop [Thu, 24 Nov 2022 15:37:51 +0000 (15:37 +0000)]
Bug 31160: Required fields in patron api

The Patron API PUT request required the fields "surname","address","city",
"library_id","category_id". Meanwhile the CSV import page for patrons only
requires "surname","library_id","category_id". The fields for "address" and
"city" have been removed from the "required" section of the api > v1 > swagger
> definitions > patron.yaml file to match the CSV import page.

Test Plan:
1) Send a PUT request to http://localhost:8081/api/v1/patrons/19 with an empty body
2) Error message should ask for 5 missing fields as listed above
3) Apply patch
4) Restart Apache server using "restart_all" in your ktd shell
5) Resubmit your request
6) Error message should now only request "surname","library_id","category_id"

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 1d522cc2464ac0d953e93d3f8f178da1a9e06d82)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 32355: Add css class url to URL syspref
Didier Gautheron [Mon, 28 Nov 2022 07:29:47 +0000 (08:29 +0100)]
Bug 32355: Add css class url to URL syspref

Add missing css class to URL syspref.

To Test:
1 - open admin/preferences.pl
2 - Search for URL
3 - casServerUrl, UsageStatsLibraryUrl, KohaManualBaseURL,
    PrivacyPolicyURL, LibrisURL input field size are small.
4 - Apply patch
5 - all URL fields have the same bigger size.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit af794a6cfa85d8f3160ddb4c4f626e85063a844c)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 32389: Fix Syndetics link on staff results page
Lucas Gass [Thu, 1 Dec 2022 17:40:30 +0000 (17:40 +0000)]
Bug 32389: Fix Syndetics link on staff results page

To test:
1. Have SyndeticsCoverImages on and Syndetics setup.
2. Do a search that will return some results with Syndetics images
3. Click on the image link and you will get a 404
4. Apply patch
5. Link works!

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 2fec6d32b8de403b66b0c06b331528c6946025ed)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 32422: Hardcoded paths in _common.scss precent using external node_modules
Tomas Cohen Arazi [Wed, 7 Dec 2022 19:16:58 +0000 (16:16 -0300)]
Bug 32422: Hardcoded paths in _common.scss precent using external node_modules

This patch makes:

- gulpfile.js add the parent dir's node_modules to the sass include path
- removes hardcoded paths from _common.scss

To test:
1. Have the latest KTD image (this is not KTD specific, but easier to
   test)
2. Make sure you don't have any node_modules/ dir in your koha clone
3. Run:
   $ kshell
  k$ yarn build --view opac
=> FAIL: You get:
kohadev-koha@kohadevbox:/kohadevbox/koha$ yarn build --view opac
yarn run v1.22.19
$ gulp build --view opac
[18:27:38] Using gulpfile /kohadevbox/koha/gulpfile.js
[18:27:38] Starting 'build'...
Error in plugin 'sass'
Message:
    koha-tmpl/opac-tmpl/bootstrap/css/src/_common.scss
Error: File to import not found or unreadable: ../../../../../node_modules/bootstrap/scss/functions.
        on line 37 of koha-tmpl/opac-tmpl/bootstrap/css/src/_common.scss
        from line 1 of koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss
>> @import "../../../../../node_modules/bootstrap/scss/functions";

   ^

4. Apply this patch
5. Repeat 3
=> SUCCESS: It builds!
6. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit b00c01093a28dc06df279aa899da94a4c5b65209)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 32257: Fix capitalization - Patron Attribute
Katrin Fischer [Wed, 7 Dec 2022 20:14:36 +0000 (20:14 +0000)]
Bug 32257: Fix capitalization - Patron Attribute

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 574bbe85765223697e7a81da19c9733368423cd2)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 32257: Label for patron attributes misaligned
Matt Blenkinsop [Wed, 23 Nov 2022 17:12:59 +0000 (17:12 +0000)]
Bug 32257: Label for patron attributes misaligned

Label has now been realigned to match the format of the fields above. When
clicking to add a new field, the delete button was also misaligned. This has
 now been reformatted to sit next to the "New" button

Test Plan:
1) Navigate to Tools > Batch patron modification
2) Add either card or borrower numbers to bring up the edit patrons fields
3) "Patron attributes:" is on the far right and above the select box. When
   adding a new field there is a big gap between the Add and  Delete buttons
4) Apply patch and navigate to same area
5) Observe that the Patron attributes option is aligned to match the fields
   above and the gap between the buttons has been removed

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit d2ee603a608d8eadd33c8deeaaa2b04868960ab0)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 28975: (QA follow-up) Fix indentation, simplify if statement
Kyle Hall [Fri, 2 Dec 2022 14:18:08 +0000 (09:18 -0500)]
Bug 28975: (QA follow-up) Fix indentation, simplify if statement

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 72c10b222743247c881b1bb07fdc18d1ae6c715a)
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
22 months agoBug 28975: Holds queue lists can show holds from all libraries even with IndependentB...
The Minh Luong [Tue, 25 Jan 2022 17:20:38 +0000 (12:20 -0500)]
Bug 28975: Holds queue lists can show holds from all libraries even with IndependentBranches

When using IndependentBranches, usually all branches are removed from the drop-down menus. But in the Holds Queue page, there is the possibility to choose "All branches". From there, you can see holds from all libraries.

To recreate :
1) Activate IndependentBranches, IndependentBranchesPatronModifications and IndependentBranchesTransfers
2) Create a staff user with limited permissions (NOT a superlibrarian), including holds permissions. Here are mine as an example
  - circulate (all)
  - catalogue
  - borrowers
    - delete_borrowers
    - edit_borrowers
  - reserveforothers (all)
  - reports (all)
3) Create (or make sure you already have) a patron in another branch (we'll call them patron X)
4) Place a hold for patron X on an available item from their own library
5) Run misc/cronjobs/holds/build_holds_queue.pl
6) Go to Circulation > Holds queue and make sure you can see the hold
7) Log in as your limited staff patron
8) Go to Circulation > Holds queue
9) In the drop-down menu, choose "All" and click Submit
-- Notice you see the hold of the patron from another branch under Patron
column: "A patron from library <library name>"
11) Apply the patch.
12) Notice that the "All" option is no longer available for the limited patron. Limited patrons can't see holds from other libraries anymore.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit fe2e2f9400714341877958853e8165db517fe1fa)
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
22 months agoBug 32291: (bug 16735 follow-up) Remove ref to library category in branches.tt
Jonathan Druart [Wed, 23 Nov 2022 09:08:26 +0000 (10:08 +0100)]
Bug 32291: (bug 16735 follow-up) Remove ref to library category in branches.tt

On bug 16735 we rewrite the library groups system. Those references in
branches.tt were part of the previous code, and they can be removed.

Test plan:
Confirm the above and that those code errors are never sent to the
template.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 4f8b742cbe0c41a389290a821c0ca478bb108e26)
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
22 months agoBug 31984: TaxRate preference - add note about vendor updates
David Nind [Mon, 28 Nov 2022 12:28:34 +0000 (12:28 +0000)]
Bug 31984: TaxRate preference - add note about vendor updates

If a value for the TaxRates system preference is changed or
removed, vendors retain the original value recorded in their
tax rate field.

The vendor tax rate is used to calculate prices for orders
added to a basket. Where the tax rate doesn't match with the
system preference, a warning message is displayed on the order
form "Tax rate not defined in system preference TaxRates!".

This patch adds a note to the system preference description
about updating vendor tax rate information where required.

Test plan:
1. Check the values recorded for the TaxRates system preference.
2. For a vendor (Acquisitions > search for a vendor > Edit vendor),
   check the value recorded in the tax rate field.
3. Note that the tax rate field is populated from a dropdown list
   using values from the TaxRates system preference.
4. Change the TaxRates system preferemce to remove a tax
   rate. For example, change 0|0.12|0.1965 to 0|0.12.
5. Refresh the vendor page.
6. Note that the vendor tax rate remains as the original value
   until you edit the vendor.
7. Apply the patch.
8. Review the description for the TaxRates system preference and
   make sure the new note about updating vendor tax rates where
   required makes sense.
9. Sign off!

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
22 months agoBug 31675: Remove packages from debian/control that are no longer used
Kyle M Hall [Tue, 21 Sep 2021 11:08:44 +0000 (07:08 -0400)]
Bug 31675: Remove packages from debian/control that are no longer used

As far as I can tell, we are no longer using CGI::Session::Serialize::YAML or YAML::Syck, but they are still marked dependencies for the Debian package.

Signed-off-by: Danyon Sewell <danyonsewell@catalyst.net.nz>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
22 months agoBug 32354: Accept session_state param given by OAuth IdP
Aleisha Amohia [Sun, 27 Nov 2022 21:24:59 +0000 (21:24 +0000)]
Bug 32354: Accept session_state param given by OAuth IdP

This patch ensures Koha doesn't throw an error if the IdP hands back a
session_state parameter.

To test:

1) Set up an identity provider
2) On the IdP's configuration, make it hand back a session_state
3) Confirm authentication using OIDC works with and without the
session_state

Sponsored-by: Plant & Food Research
Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
22 months agoBug 32074: Edit vendor has two save buttons
Matt Blenkinsop [Fri, 2 Dec 2022 10:10:09 +0000 (10:10 +0000)]
Bug 32074: Edit vendor has two save buttons

When editing a vendor there is a floating toolbar with options to save
and cancel. There is also an additional save and cancel button set at
the bottom of the page and this is superfluous. This has now been
removed to leave the floating toolbar as the only toolbar.

Test plan:
1) Navigate to Acquisitions and select a Vendor.
2) Click edit vendor
3) Scroll down the page and observe that there is a floating
   save/cancel toolbar as well as the buttons to save/cancel at the
   bottom of the page
4) Apply patch
5) Observe that the duplicate buttons at the bottom of the page are now
   gone

Signed-off-by: Owen <oleonard@myacpl.org>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
22 months agoBug 32283: (follow-up) Fix in two other places
David Nind [Wed, 23 Nov 2022 00:05:28 +0000 (00:05 +0000)]
Bug 32283: (follow-up) Fix in two other places

Fix two other occurences where the capitalization of OPAC
is incorrect:
- Identity provider email domains table column heading
- 'New email domain' form label

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
22 months agoBug 32283: Correct capitalisation of opac > OPAC
Andrew Auld [Tue, 22 Nov 2022 14:34:51 +0000 (14:34 +0000)]
Bug 32283: Correct capitalisation of opac > OPAC

Test plan
Step 1: Navigate to admin>Identity Providers
Step 2: Add new domain
Step 3: For 'Allow opac' setting, verify that opac is lower case in both label and description
Step 4: Apply patch
Step 5: Navigate to admin>Identity Providers
Step 6: Add new domain
Step 7: For 'Allow OPAC' setting, verify that OPAC is upper case in both label and description

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
22 months agoBug 32282: Fixed capitalisation of ID in User ID
Andrew Auld [Tue, 22 Nov 2022 14:16:21 +0000 (14:16 +0000)]
Bug 32282: Fixed capitalisation of ID in User ID

Test plan
Step 1: go to admin>identity providers
Step 2: click 'new identity provider'
Step 3: check map point drop-down
Step 4: verify that User id is written 'User id'
Step 5: apply patch
Step 6: repeat 1-3
Step 7: verify that User ID is written 'User ID'

Signed-off-by: Amit Gupta <amit.gupta@informaticsglobal.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
22 months agoBug 28235: Correct CSS governing max width of custom cover images
Owen Leonard [Fri, 18 Nov 2022 14:02:13 +0000 (14:02 +0000)]
Bug 28235: Correct CSS governing max width of custom cover images

Images shown in the OPAC and staff interface when the
OPACCustomCoverImages and  CustomCoverImages preferences are enabled
should be getting a max-width set in the current CSS, but the order of
the declarations is preventing the correct specificity.

This patch moves the CSS to the correct place in each file so that the
max-width is applied.

To test, apply the patch and rebuild both the staff and OPAC CSS. If you
get an error during the build process you may need to run 'yarn
install.'

- Go to Administration -> System preferences, and enable the
  OPACCustomCoverImages and  CustomCoverImages preferences.
- If you're testing with the default test database you can set the
  CustomCoverImagesURL preference to
  https://static.myacpl.org/public/covers/{normalized_isbn}.jpg
- Perform a catalog search in both OPAC and staff client limiting by
  itemtype = 'Book'.
- The search results in both interface should show several covers
  supplied from the external URL.
- In the staff client, these images should be limited to 140px wide even
  if the source image is larger.
- In the OPAC, view the detail page for one of the results with cover
  images. The image shown on the detail page should be constrained to
  140px wide even if the source image is larger.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
22 months agoBug 32261: Add more UI feedback when selecting patron from autocomplete
Jonathan Druart [Fri, 18 Nov 2022 08:55:06 +0000 (09:55 +0100)]
Bug 32261: Add more UI feedback when selecting patron from autocomplete

There is only a tiny change in the color of the selected item, but it's
not obvious.

Test plan:
Regenerate the css files using `yarn build`
Search for patrons and note that the down/up keys let you select a
patron and the background color change.
Note that the background color is not on the container and so is not
similar as the hover rule (when using the mouse). We could change that,
but then the behaviour is weird when you have both the mouse and the
keyboard selecting items in the item list.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
22 months agoBug 32261: Patron autocomplete - do not empty text field
Jonathan Druart [Fri, 18 Nov 2022 08:52:35 +0000 (09:52 +0100)]
Bug 32261: Patron autocomplete - do not empty text field

The jQuery UI autocomplete is supposed to replace the text field with
the 'value' attribute of the selected item. As it does not exist it's
emptied. We should not replace what the user typed in.

Test plan:
Go to the Koha home page
Select "Search patrons" in the header
Type 'edn', it will return 1 result
Use the down key to select the item (it is not obvious but there is a
little change in the color when you select the item)
=> Without this patch the search field is emptied
=> With this patch applied the search field is not modified

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
22 months agoBug 32366: (bug 30460 follow-up) Add tests
Jonathan Druart [Wed, 30 Nov 2022 07:55:13 +0000 (08:55 +0100)]
Bug 32366: (bug 30460 follow-up) Add tests

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 3411a2c0021da2ff9fe91092c1fa202dfaa04f71)
Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
22 months agoBug 32236: Fix alignment of checkbox "Use default values" for item batch modification
Katrin Fischer [Wed, 16 Nov 2022 21:49:17 +0000 (21:49 +0000)]
Bug 32236: Fix alignment of checkbox "Use default values" for item batch modification

This moves the label to the right in front of the checkbox.
It also shortens the label by adding an additional longer hint text.

To test:
* Go to cataloguing > item batch modification
* On the first page of the tool, look at the checkbox at the bottom
* Apply the patch
* Verify changes

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 58580d2bb476233a2407f3e267e5ed20b07b1729)
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
22 months agoBug 29274: Remove z_reset.t
Jonathan Druart [Wed, 30 Nov 2022 09:51:44 +0000 (10:51 +0100)]
Bug 29274: Remove z_reset.t

From the description of commit d25f3e84374ec8d7c85f8ed805102f67c0a73d77

"""
    Bug 22709: (RM follow-up) Clean up plugin tests

    The plugin tests were failing due to failed rollbacks and run order.
    This patch moves them into their own directory and adds a reset test to
    restore the original state of the plugin system after the tests have
    run.
"""

This is wrong, the tests are run in a random order.

We don't need this file.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 7f8156cf5c4236d7f16744baea0775cdaeeec266)
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
22 months agoResync Compiled CSS
Martin Renvoize [Sat, 3 Dec 2022 20:29:13 +0000 (20:29 +0000)]
Resync Compiled CSS

At some point the opac css has gone out of sync and is throwing errors
in the pre-push hook.  After discussion with Jonathan and Tomas we think
it might be something around the bootstrap fixes after our introduction
of the Vue stack.

tl;dr - Rebuild CSS to make hooks happy.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoVue bundle - Add main.js.LICENSE.txt
Jonathan Druart [Thu, 1 Dec 2022 09:29:42 +0000 (10:29 +0100)]
Vue bundle - Add main.js.LICENSE.txt

There is a reference to it in main.js, it makes sense to include it in
our codebase

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 8965615f2df32b4df671c09e25dc9261dd2b1067)
Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
22 months agoBug 32351: Holds.t - remove wrong column reference
Marcel de Rooy [Fri, 25 Nov 2022 10:50:01 +0000 (10:50 +0000)]
Bug 32351: Holds.t - remove wrong column reference

Found by bug 32350.
The test does not need this value at all..

Test plan:
Run test.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit ad3d34bfd1674d78cb5e45d4bdcb4b0507ee6742)
Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
22 months agoBug 32351: Fix t/db_dependent/Koha/Charges/Sales.t
Tomas Cohen Arazi [Wed, 30 Nov 2022 18:49:59 +0000 (15:49 -0300)]
Bug 32351: Fix t/db_dependent/Koha/Charges/Sales.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit a69efaa2a511715ca72cb5170579f17f3e41c67f)
Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
22 months agoBug 32351: Fix t/db_dependent/Circulation/NoIssuesChargeGuarantees.t
Tomas Cohen Arazi [Wed, 30 Nov 2022 18:48:18 +0000 (15:48 -0300)]
Bug 32351: Fix  t/db_dependent/Circulation/NoIssuesChargeGuarantees.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 3200c18e7dd16305be0abcdace476b44fbe2b46f)
Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
22 months agoBug 32351: Fix t/db_dependent/api/v1/patrons.t
Tomas Cohen Arazi [Wed, 30 Nov 2022 18:47:22 +0000 (15:47 -0300)]
Bug 32351: Fix t/db_dependent/api/v1/patrons.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 8455c0b83d268e9ad695fa55265bf3a0719f8ad7)
Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
22 months agoBug 32351: Fix Koha/Patrons.t
Tomas Cohen Arazi [Wed, 30 Nov 2022 18:45:20 +0000 (15:45 -0300)]
Bug 32351: Fix Koha/Patrons.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 11ac81782f20b2a5ad8a9f7b145aad4f766a0f62)
Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
22 months agoBug 32351: Fix TemplateToolkit.t
Tomas Cohen Arazi [Wed, 30 Nov 2022 18:42:26 +0000 (15:42 -0300)]
Bug 32351: Fix TemplateToolkit.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit ca77a59a9b9cb27cd8dee26dda72f6b55781ccc4)
Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
22 months agoBug 32351: Fix CourseItems.t
Tomas Cohen Arazi [Wed, 30 Nov 2022 18:41:59 +0000 (15:41 -0300)]
Bug 32351: Fix CourseItems.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit cd49ab5c281fa62d66ab9dbe0b08e529ea174522)
Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
22 months agoBug 32351: Fix Circulation.t
Jonathan Druart [Fri, 25 Nov 2022 11:55:39 +0000 (12:55 +0100)]
Bug 32351: Fix Circulation.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 5f07e7afffe7b1addbd4dd9bf7ae995f46d8470f)
Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
22 months agoBug 32351: Fix Reserves.t
Jonathan Druart [Fri, 25 Nov 2022 11:48:34 +0000 (12:48 +0100)]
Bug 32351: Fix Reserves.t

itemtypes.notforloan already defaults to 0

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 4824bbf195603dfcde21d28a385e6f501d7764b9)
Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
22 months agoBug 32351: Fix Members.t
Jonathan Druart [Fri, 25 Nov 2022 11:46:27 +0000 (12:46 +0100)]
Bug 32351: Fix Members.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit a471e6d5bc9ed4d38728bc46e84762ddd0a3c660)
Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
22 months agoBug 32351: Fix Illrequests.t
Jonathan Druart [Fri, 25 Nov 2022 11:45:26 +0000 (12:45 +0100)]
Bug 32351: Fix Illrequests.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit ade52182c40473e808b12f4d80c242bcb2b94243)
Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
22 months agoBug 32351: Fix Budgets.t
Jonathan Druart [Fri, 25 Nov 2022 11:42:18 +0000 (12:42 +0100)]
Bug 32351: Fix Budgets.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit d077aa2e7df1124758b5c5fb47d8d814064b1a49)
Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
22 months agoBug 32351: Fix Acquisition.t
Jonathan Druart [Fri, 25 Nov 2022 11:35:42 +0000 (12:35 +0100)]
Bug 32351: Fix Acquisition.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit eecad982eecdb16d3511814d17c61b3ba21932a1)
Signed-off-by: Jacob O'Mara <jacobomara901@gmail.com>
22 months agoBug 31381: Add tests
Jonathan Druart [Wed, 23 Nov 2022 08:30:33 +0000 (09:30 +0100)]
Bug 31381: Add tests

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit f1d2ec4aa86250029fb9189af3bdc52b5fe28ee6)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 31381: Handle null attributes in list
Nick Clemens [Tue, 22 Nov 2022 19:21:22 +0000 (19:21 +0000)]
Bug 31381: Handle null attributes in list

This patch allows null values to be returned in patron attributes
to prevent a crash when searching patrons

To test:
1 - Add a NULL attribute to a borrower, in sample data, Edna Acosta
    sudo koha-mysql kohadev
    INSERT INTO borrower_attributes (borrowernumber,code,attribute) VALUES (5,'SHOW_BCODE',NULL);
2 - Browse to 'Home->Patrons'
    http://localhost:8081/cgi-bin/koha/members/members-home.pl
3 - Click 'Browse by last name: A'
4 - Datatables error:
    Expected string - got null
5 - Apply patch
6 - Restart all
7 - Browse by last name: A
8 - Success!

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit f6905139472bacd31a86249e4b09cdb44eeed269)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 32350: Add subtest for bad columns
Marcel de Rooy [Fri, 25 Nov 2022 10:09:57 +0000 (10:09 +0000)]
Bug 32350: Add subtest for bad columns

Test plan:
Run t/db_dependent/TestBuilder.t
And now run the whole test suite :)

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 46aa87c600871bc8556bfe3ab4840d673211a625)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
22 months agoBug 32350: Use array_minus and ignore nesting
Marcel de Rooy [Fri, 25 Nov 2022 10:02:24 +0000 (10:02 +0000)]
Bug 32350: Use array_minus and ignore nesting

Note: Test will be extended in follow-up. This fixes the
module_bit hash to follow the FK path from user_permissions
to permissions to userflags. One step was missed in the
existing test, although it did not fail. The change here
revealed that now.

Test plan:
Run t/db_dependent/TestBuilder.t

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 9b9b8f19200695df168440d47cecc6b947fcebc5)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
23 months ago22.11.00: Fix translations
Tomas Cohen Arazi [Tue, 29 Nov 2022 15:10:23 +0000 (12:10 -0300)]
22.11.00: Fix translations

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32213: Reindent item search fields templates
Owen Leonard [Thu, 17 Nov 2022 15:26:48 +0000 (15:26 +0000)]
Bug 32213: Reindent item search fields templates

This patch reindents three item search field templates so that they have
consistent indentation.

To test, apply the patch and go to Administration -> Item search fields.

Test all aspects of viewing, adding, and deleting item search fields.
Everything should look correct and work correctly.

Signed-off-by: David <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Edit: changed intendation on a tiny bit
(cherry picked from commit 3381a6463cad9300bae89384fd47749a9887a0c7)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
23 months agoBug 32126: Fix missing div breaking the form for adding more search fields
Katrin Fischer [Tue, 15 Nov 2022 16:06:09 +0000 (16:06 +0000)]
Bug 32126: Fix missing div breaking the form for adding more search fields

The missing div caused a problem with the JS that controls
visibility of the list of search fields, the form and the toolbar.
With the div added, everything should now work as expected.

To test:
* Add a item search field, everything should work.
* Add a second item search field - intead of the form, you'll see an empty page.
* Apply patch.
* Add second and more search fields, all should work.
* Edit search fields.
* Delete search fields.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit dd095aa8c44c2f057c2bddb0ecf0f2048be038d9)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
23 months agoBug 32352: Make xt/check_makefile.t check directories in git index
Jonathan Druart [Fri, 25 Nov 2022 11:24:26 +0000 (12:24 +0100)]
Bug 32352: Make xt/check_makefile.t check directories in git index

It's failing if 'node_modules' exists. We could simply skip it, but it
seems that it would be better to actually list directories that are part
of the git index only.

The question is: do we actually support test execution outside of a git
directory?

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 8c367775470fcecdda54e28270b05d92834cd33f)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
23 months agoKoha 22.11.00 Rosalie is here! v22.11.00
Tomas Cohen Arazi [Fri, 25 Nov 2022 18:16:58 +0000 (15:16 -0300)]
Koha 22.11.00 Rosalie is here!

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months ago22.11.00: Vue bundle
Tomas Cohen Arazi [Fri, 25 Nov 2022 18:13:55 +0000 (15:13 -0300)]
22.11.00: Vue bundle

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoTranslation updates for Koha 22.11.00
Koha translators [Fri, 25 Nov 2022 16:59:04 +0000 (13:59 -0300)]
Translation updates for Koha 22.11.00

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoAdd release notes for Koha 22.11.00
Tomas Cohen Arazi [Fri, 25 Nov 2022 17:22:57 +0000 (14:22 -0300)]
Add release notes for Koha 22.11.00

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months ago22.11.00: Update kohastructure.sql
Tomas Cohen Arazi [Fri, 25 Nov 2022 14:15:50 +0000 (11:15 -0300)]
22.11.00: Update kohastructure.sql

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months ago22.11.00: Update history.txt
Tomas Cohen Arazi [Fri, 25 Nov 2022 13:48:31 +0000 (10:48 -0300)]
22.11.00: Update history.txt

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months ago22.11.00: Update contributors.yaml
Tomas Cohen Arazi [Fri, 25 Nov 2022 13:47:39 +0000 (10:47 -0300)]
22.11.00: Update contributors.yaml

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months ago22.11.00: Update .mailmap
Tomas Cohen Arazi [Fri, 25 Nov 2022 13:46:58 +0000 (10:46 -0300)]
22.11.00: Update .mailmap

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 30808: (follow-up) Minor visual glitch
Tomas Cohen Arazi [Fri, 25 Nov 2022 16:11:00 +0000 (13:11 -0300)]
Bug 30808: (follow-up) Minor visual glitch

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 30808: Add a dedications tab to the about page
Martin Renvoize [Fri, 25 Nov 2022 15:35:36 +0000 (15:35 +0000)]
Bug 30808: Add a dedications tab to the about page

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 30808: Add support for version codenames
Martin Renvoize [Fri, 25 Nov 2022 15:20:58 +0000 (15:20 +0000)]
Bug 30808: Add support for version codenames

This patch adds the 'Rosalie' codename to the 22.11 release and adds
corresponding support to the about page for displaying it.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 30808: Add the 23.05 release team
Martin Renvoize [Fri, 25 Nov 2022 14:30:55 +0000 (14:30 +0000)]
Bug 30808: Add the 23.05 release team

This patch updates the teams.yaml to include the voted in 23.05 release
team and also updates the release date of 22.11 to match the actual
release.

Test plan
1/ Check against https://wiki.koha-community.org/wiki/Release_Teams

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 31969: Use filter_by_last_update
Jonathan Druart [Wed, 23 Nov 2022 08:53:31 +0000 (09:53 +0100)]
Bug 31969: Use filter_by_last_update

This script has a pattern to delete rows depending on a given
date/number of days, we should use the filter_by_last_update
Koha::Objects method.
No need for another method and tests, everything is already tested
there.

This patch also suggests to rename the reference to "background" and
"bg" with "jobs", which seems more appropriate and not an abbreviation

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32304: BackgroundJobs.t: Fix subtest purge
Marcel de Rooy [Mon, 21 Nov 2022 09:53:31 +0000 (09:53 +0000)]
Bug 32304: BackgroundJobs.t: Fix subtest purge

Instead of deleting, I added a count :)
Note that one of the purges eventually deletes my
older jobs..

Test plan:
Run t/db_dependent/Koha/BackgroundJobs.t

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32304: Fix subtest search_limited
Marcel de Rooy [Fri, 25 Nov 2022 08:13:04 +0000 (08:13 +0000)]
Bug 32304: Fix subtest search_limited

Jenkins reported:
    not ok 1 - No jobs found without userenv

We need to check if there are jobs without borrowernumber.

Test plan:
Run test again.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32343: Prevent Koha/Patron.t to fail randomly
Jonathan Druart [Fri, 25 Nov 2022 06:26:42 +0000 (07:26 +0100)]
Bug 32343: Prevent Koha/Patron.t to fail randomly

Highlighted by Bug 32030: fix test builder for boolean

The attribute is named "unique_id", not "unique"

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 15348: (follow-up) Fix modals to pre-set input with stored date
Katrin Fischer [Tue, 15 Nov 2022 13:32:43 +0000 (13:32 +0000)]
Bug 15348: (follow-up) Fix modals to pre-set input with stored date

Makes sure that when an estimated delivery day is edited using
the modals on the basket summary or late order pages, the
date input is pre-set to the stored estimated delivery date.

To test:
* Create some order lines with and without estimated delivery date set
* Make sure that on the basket summary the edit link comes up with an
  empty modal
* Close the basket
* Check that on late orders the dates are pre-filled incorrectly as well
* Apply patch
* Refresh basket summary and late order pages
* All edit links now should bring up the modal with the correct date filled in

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 15348: Store estimated delivery date when adding an order
Katrin Fischer [Tue, 15 Nov 2022 12:22:31 +0000 (12:22 +0000)]
Bug 15348: Store estimated delivery date when adding an order

When the estimated delivery date was entered on adding or modifying
and order, it was not saved to the database.

To test:
* Add new order, fill in estimated delivery date
* Save
* Verify the estimated delivery date is empty
* Modify order line, date will also not be saved
* Apply patch
* The date should now save and update correctly

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 15348: (follow-up) Fix filters on input fields
Katrin Fischer [Tue, 15 Nov 2022 11:32:08 +0000 (11:32 +0000)]
Bug 15348: (follow-up) Fix filters on input fields

With bug 30718 we on longer need the KohaDates TT filter
on the inputs. This patch removes them.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32310: Compiled CSS
Tomas Cohen Arazi [Thu, 24 Nov 2022 18:35:39 +0000 (15:35 -0300)]
Bug 32310: Compiled CSS

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32310: Correct CSS in the staff interface which still uses old color scheme
Owen Leonard [Mon, 21 Nov 2022 18:17:45 +0000 (18:17 +0000)]
Bug 32310: Correct CSS in the staff interface which still uses old color scheme

This patch updates staff interface CSS so that it better conforms to the
color scheme of the updated staff interface.

To test, apply the patch and rebuild the staff interface CSS.

- Go to Tools -> Calendar. Corrected are the borders around the calendar
  and around the "Add new holiday" panel which appears when you click a
  date on the calendar.
- Go to Patrons and perform a search which will return multiple results.
  - Check the checkbox for some patrons. The color of the "Patrons
    selected" box have been updated.
  - Incorrect padding values have also been removed from the adjacent
    patron list and merge buttons.
- Locate a multi-paged DataTable, e.g. Administration -> Authorized
  values. The style of the "Next" and "Previous" buttons have been
  updated.
- View a patron record and choose More -> Set permissions from the
  toolbar. In the table of permissions, when you hover your mouse over
  one of the headings ("Check out and check in items," "Edit
  authorities," etc.) the color should be correct.
- I don't think this is ever visible in the staff interface, but the
  template has markup in it to display a "Log in" link in the header
  menu if the user isn't logged in. I've removed some redundant CSS
  corresponding to this link and corrected some markup just in case
  there is a situation in which is appears.

Signed-off-by: Amit Gupta <amitddng135@gmail.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32260: Patron autocomplete - Do not display an alert if request is rejected
Jonathan Druart [Fri, 18 Nov 2022 07:00:24 +0000 (08:00 +0100)]
Bug 32260: Patron autocomplete - Do not display an alert if request is rejected

Not sure what is going on exactly, neither if this patch is the correct
way to fix this.
The request is "rejected" at some point (by the browser?), when we
search for patrons using the autocomplete and DT "at the same time".

To recreate:
Don't apply this patch
Go to /cgi-bin/koha/reserve/request.pl?biblionumber=1&borrowernumber=5
Search for "edn" then hit enter
You may see an alert, that will disappear
If you don't see the alert, repeat

This patch suggests to ignore the alert if the status of the request is
"rejected".

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32303: Remove DT pagination on system preference search result
Owen Leonard [Tue, 22 Nov 2022 15:19:52 +0000 (15:19 +0000)]
Bug 32303: Remove DT pagination on system preference search result

This patch updates the way we retrieve a DataTable's saved state during
initialization. The change is to prevent cases where making a duplicate
call to DataTables() initializes the table again.

To recreate the bug, search system preferences for the term "last."
Scroll down to the "OPAC preferences" section and observe that there are
two filter forms displayed above it.

Apply the patch and perform the same search again. The extra forms
should be gone.

Confirm that DataTables behavior is still the same:

 - Test pages which use the "saveState" option in DataTables.
   - Type text in the table's search field
   - Reload the page. The search field should still have the string you
     entered, and the "Clear filter" button should be active.
     - Administration -> Libraries
     - Acquisitions -> Vendor -> Receive shipments -> Receive orders
     - Circulation -> Overdues

 - Test pages which don't use the "saveState" option, e.g. the checkout
   screen, patron search results, list of saved reports, etc. The
   behavior of the search form and table operations in general should be
   unchanged.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32046: Compiled CSS
Tomas Cohen Arazi [Wed, 23 Nov 2022 12:35:02 +0000 (09:35 -0300)]
Bug 32046: Compiled CSS

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32046: (follow-up) Accommodate the inclusion of item information
Owen Leonard [Wed, 16 Nov 2022 15:26:29 +0000 (15:26 +0000)]
Bug 32046: (follow-up) Accommodate the inclusion of item information

If you have item information configured in the MarcItemFieldsToOrder
system preference, the "Select to import" tab will display a basic item
information form which needs to use the same style as other item edit
forms.

In order to make the CSS in addbiblio.css more generic, I've changed
some styles to use a class, .item_edit_form, instead of an ID. This lets
us have multiple <div class="item_edit_form"> in this template without
duplicating IDs. Other instances of <div
id="cataloguing_additem_newitem"> have haa the .item_edit_form class
added.

To test you must have a staged MARC file which includes items and you
must configure the MarcItemFieldsToOrder preference to map those items
in the ordering interface.

As you follow the previous patch's test plan you'll find that when you
click a checkbox or title to expand the information about that title
you'll see "Item record X" headings following by a properly-styled form.

To confirm that the changes to addbiblio.css are not too far-reaching,
test the other affected pages:

 - Item add/edit
 - Batch item modification
 - Batch item deletion

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32046: When adding a new records from a staged files, there are style issues
Owen Leonard [Wed, 16 Nov 2022 12:08:56 +0000 (12:08 +0000)]
Bug 32046: When adding a new records from a staged files, there are style issues

This patch modifies the template for adding a record from a staged file
in order to resolve some layout problems introduced by the staff
redesign.

This patch also corrects an problem with addorderiso2709.js: It included
some template markup. The template variables are converted to a JS
variable to prevent a JS error.

Note that the QA tool's js_in_body error is invalid for this template
which requires that the JS stay inside <head>.

To test you must have at least one MARC file staged for import.

- Apply the patch and go to Acquisitions.
- Locate a vendor and create a basket if necessary.
- Add to the basket and choose the option of adding an order from a
  staged file.
- Click "Add orders" next to one of the staged files.
- On the Add orders from MARC file page, test that everything looks
  correct and works correctly:
  - In the first tab, expanding and collapsing order details by checking
    the checkbox or clicking the title.
  - Test the "MARC" and "Card" preview buttons.
  - Under the Item information tab, confirm that the layout looks
    correct and that the form works correctly, including plugin
    operations like auto barcode fill.
  - Test that, under the Default accounting details tab, changing the
    fund automatically sets the fund for each title in the first tab.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32269: Prevent Circulation.t to fail randomly
Jonathan Druart [Fri, 18 Nov 2022 14:31:10 +0000 (15:31 +0100)]
Bug 32269: Prevent Circulation.t to fail randomly

Highlighted by Bug 32030: fix test builder for boolean

    #   Failed test 'Checkouts with auto-renewal can be renewed earliest on due date if no renewalbefore'
    #   at t/db_dependent/Circulation.t line 343.
    #          got: '2022-11-18T14:16:12'
    #     expected: '2022-12-02T00:00:00'

    #   Failed test 'Checkouts with auto-renewal can be renewed earliest on due date if no renewalbefore'
    #   at t/db_dependent/Circulation.t line 349.
    #          got: '2022-11-18T14:16:12'
    #     expected: '2022-12-02T23:59:00'
    # Looks like you failed 2 tests of 5

We were reaching return $now

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32299: Add page-section to Z39.50 results
Andrew Auld [Tue, 22 Nov 2022 13:56:22 +0000 (13:56 +0000)]
Bug 32299: Add page-section to Z39.50 results

Test plan
Step 1: Navigate to Cataloguing module and click 'New from Z39.50/SRU' to start a search
Step 2: Carry out a search
Step 3: Confirm that the white background to the table of results is missing
Step 4: Apply patch
Step 6: Repeat search
Step 7: Confirm that the white background is now showing.

Signed-off-by: Hammat Wele <hammat.wele@inlibro.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 31378: Tests shouldn't remove all patrons
Tomas Cohen Arazi [Tue, 22 Nov 2022 21:23:07 +0000 (18:23 -0300)]
Bug 31378: Tests shouldn't remove all patrons

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32241: Add page-section to list of records in batch record modificaton (tool)
Owen Leonard [Thu, 17 Nov 2022 19:13:33 +0000 (19:13 +0000)]
Bug 32241: Add page-section to list of records in batch record modificaton (tool)

This patch modifies the batch record modification page template so that
the preview of submitted records is contained in a .page-section
container.

To test, apply the patch and go to Cataloging -> Batch record
modification.

Submit a batch of bibliographic record numbers and a batch of authority
record numbers. In both cases the page which previews the list of
submitted records in a table should be correctly styled.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32198: Add page-section to stock rotation stages list (cat)
Owen Leonard [Thu, 17 Nov 2022 18:50:07 +0000 (18:50 +0000)]
Bug 32198: Add page-section to stock rotation stages list (cat)

This patch adds a .page-section container around relevant areas of the
stock rotation management interface.

Also changed: Removed a .dialog.message container which was not correct.

To test, apply the patch and go to Cataloging -> Stock rotation.

- If necessary, add a rota.
- Click Manage -> Stages on your rota.
  - If neccesary, create one or more stages.
  - The display of stages should look correct.
- From the list of rotas click Manage -> Items.
  - Click "Add items" and use a barcode file to add multiple items at
    once.
  - The page confirming your submission, with a list of items, should
    have a page-section.
  - Return to the view of items in the rota. The display of items should
    look correct.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32238: Add page-section to label creator pages
Owen Leonard [Thu, 17 Nov 2022 19:28:48 +0000 (19:28 +0000)]
Bug 32238: Add page-section to label creator pages

This patch modifies two label creator templates so that a .page-section
container is used to wrap main content.

To test, apply the patch and go to Cataloging -> Label creator.

 - Click Manage -> Label batches.
   - The display of existing batches should look correct.
 - Click "Edit" on one of the label batches.
   - If necessary, submit a set of barcodes or item numbers to add to
     the batch.
   - The display of items in the table of items should look correct.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32254: (follow-up) Add missing div around "Older transactions"
Owen Leonard [Fri, 18 Nov 2022 16:29:46 +0000 (16:29 +0000)]
Bug 32254: (follow-up) Add missing div around "Older transactions"

To test:

- Tools -> Cash summary for <library> and Tools -> Transaction history
  for <register>
  - In the "Older transactions" section, submit start and end dates
    which will return results.
  - The table of results should be styled correctly.

Signed-off-by: David <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32254: (follow-up) Add page section to Cashup history
Katrin Fischer [Thu, 17 Nov 2022 18:45:33 +0000 (18:45 +0000)]
Bug 32254: (follow-up) Add page section to Cashup history

Adds one missing page section on the last table of the
POS transactions page.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: David <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32254: Add 'page-section' to various tools pages
Owen Leonard [Thu, 17 Nov 2022 17:24:03 +0000 (17:24 +0000)]
Bug 32254: Add 'page-section' to various tools pages

This patch adds a .page-section div to various pages in the tools
section in order to provide a consistent page structure.

Also changed: Corrected a couple of templates which were missing some
<tr> tags.

This patch includes indentation changes, so please ignore whitespace
when looking at the diff.

To test, apply the patch and view the following pages to confirm that
the primary page content is wrapped in a container with a white
background:

- Tools -> Access files
- Tools -> HTML customizations
  - Additional contents, news or pages-- all use the same template.
  - Check the list of existing entries.
- Tools -> Batch extend due dates
  - Choose a set of criteria that will return results and click
   "Continue".
  - Check the list of checkouts to be updated.
- Tools -> Batch patron modification
  - Submit a batch of patrons for modification.
  - Check the list of patrons to be modified.
- Tools -> Upload patron images
  - Upload one or more patron images
  - Check the view of results
- Tools -> Upload
  - Upload a file and view the results, or perform a search and check
    the view of results.
- Tools -> Patron card creator -> New patron card batch.
  - Submit a set of patrons and check the display of patrons in the
    resulting batch.
- Tools -> Cash summary for <library> and Tools -> Transaction history
  for <register>
  - Confirm that the table of data looks correct

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: David <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 31080: Prevent bundles from being nested
Martin Renvoize [Fri, 1 Jul 2022 14:02:58 +0000 (15:02 +0100)]
Bug 31080: Prevent bundles from being nested

This is a follow-up for bug 28854 to prevent bundle type items from
being nested in to other bundles.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 31080: Unit tests
Martin Renvoize [Mon, 4 Jul 2022 10:20:31 +0000 (11:20 +0100)]
Bug 31080: Unit tests

Unit tests for add_to_bundle functionality that prevents bundle nesting.

Test plan
1) Run t/db_dependent/Koha/Item.t
2) The test should fail
3) Apply the second patch
4) Re-run the test and watch it pass.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32237: Fix using a list as base for batch record deletion
Géraud Frappier [Wed, 16 Nov 2022 21:54:41 +0000 (16:54 -0500)]
Bug 32237: Fix using a list as base for batch record deletion

When a list was used to select records for batch deletion, the
record IDs were no longer found.

To test:

1. Go to Lists in the intranet.
2. Add a list by clicking on "New list". Choose a random name for it and select private or public and save.
3.Add one or more items into it and save.
4.Go back to the main page and select "Cataloging".
5.Go to "Batch record deletion".
6.In "upload a file" select "Select a list of records" and choose a list and keep the Bibliographic on.
7.Select continue and see that the list of records is not shown.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32167: (bug 14860 follow-up) Populate price fields even if no discount on vendor
Nick Clemens [Thu, 10 Nov 2022 19:24:25 +0000 (19:24 +0000)]
Bug 32167: (bug 14860 follow-up) Populate price fields even if no discount on vendor

On bug 14860 an 'else' was removed, assuming the price fields were set before discount,
this was incorrect. This patch renames the variable and always set the price, only discounting
ecost if a discount, but setting the values even if not

To test:
 0 - Have a vendor with a discount of 0% specified (no discount)
 1 - Export a record from your Koha
 2 - Stage the record for import and match on biblionumber
 3 - Add to a basket in acq from the staged file
 4 - Select the title, and set order price to $10 and do not fill the discount field
 5 - Add the order - note $0 order line
 6 - Repeat with another vendor with a 10% discount and confirm that is correct
 7 - Apply patch
 8 - Repeat 2-4
 9 - Add the order and confirm $10 price
10 - Repeat with discounted vendor, confirm prices are set discounted correctly

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 24606: (QA follow-up) Fix Template.t
Marcel de Rooy [Tue, 22 Nov 2022 15:49:02 +0000 (15:49 +0000)]
Bug 24606: (QA follow-up) Fix Template.t

The test cases here still assumed UTF-8 enocding in the middle
of the process. Can be much simpler.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 31891: (bug 27421 follow-up) Remove one additional click
Jonathan Druart [Wed, 16 Nov 2022 06:40:59 +0000 (07:40 +0100)]
Bug 31891: (bug 27421 follow-up) Remove one additional click

From comment 0
"""
Moving marc batch import actions to background jobs has introduced some confusing
clicks to the process. Before this change, after staging a batch one was taken
to a "MARC staging results" page with details of how the staging went and, most
importantly, a link straight to the batch you'd just staged
(at manage-marc-import.pl?import_batch_id).

Now, however, one must click the status bar to get to details of the job
and then click "View batch" from there. Not only is that an extra click
and page load, but neither of those links are particularly large or
obvious.
"""

Test plan:
- Stage a record for import, notice that the "View batch" link appears
when the job is finished
- Add order to basket from a new file, select a file and import
Notice that the "Add staged files to basket" link is displayed when the
job is finished

Note for QA: We should have a js_callback in the background_job include
file instead.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32308: Update Chocolat image viewer CSS to conform to redesign color scheme
Owen Leonard [Mon, 21 Nov 2022 16:30:33 +0000 (16:30 +0000)]
Bug 32308: Update Chocolat image viewer CSS to conform to redesign color scheme

This patch makes minor modifications to the Chocolat CSS so that the
buttons (next, previous, close) are styled with colors that conform to
the new interface color scheme.

Note: You may encounter Bug 32307 when testing.

To test, apply the patch and enable at least two cover image services in
the staff interface: Amazon, Local cover images, and/or Coce.

Locate a bibliographic record which has at least two cover images and
view the detail page. Click on the cover image to trigger the image
viewer overlay.

Confirm that the controls in this view are colored green, matching the
current color scheme.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32045: Use bootstrap tabs to select item tab
Nick Clemens [Tue, 15 Nov 2022 14:13:53 +0000 (14:13 +0000)]
Bug 32045: Use bootstrap tabs to select item tab

When the form to add orders from a staged file is validated, we use
toptabs functionality to switch to the item tab if there are missing fields.

The display now uses bootstrap tabs, so the JS is throwing an error:
Uncaught Error: cannot call methods on tabs prior to initialization; attempted to call method 'option'

This patch simply switches the call to switch tabs

To test:
1 - Stage a file for import
2 - Either use Marc(Item)FieldsToOrder to populate the orders
    or select a budget on the third tab
3 - View the second tab, items info, confirm itemtype is required, but don't populate it
4 - Attempt to save order, nothing happens
5 - Check the JS console (F12)
6 - Note the error:
    Uncaught Error: cannot call methods on tabs prior to initialization; attempted to call method 'option'
7 - Apply patch
8 - Cancel and add from staged file again
9 - Select a budget and save
10 - You now get an error popup: Some required item subfields are not set
11 - Confirm after the error you are shown the items tab
12 - Select itemtype
13 - Save
14 - Confirm orders added successfully

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 30794: Insert blank rule (unlimited) for max_holds
Jonathan Druart [Thu, 17 Nov 2022 08:28:39 +0000 (09:28 +0100)]
Bug 30794: Insert blank rule (unlimited) for max_holds

Related to bug 24669, why didn't we use strip_non_numeric for one occurrence?

Note that there is still a problem, if none of the 3 inputs is filled,
no rule will be created (ie. action ignored)

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32298: Page section added to cataloguing search
Matt Blenkinsop [Mon, 21 Nov 2022 15:20:02 +0000 (15:20 +0000)]
Bug 32298: Page section added to cataloguing search

Added div to "Records found in this catalog".
Added page-section class to "Records found in the reservoir".
Corrected level two heading and removed horizontal line as it is now superfluous.

Test plan:
1) Apply patch from bug 32298
2) Navigate to Cataloging
3) Enter a search into the search field and run the search
4) Verify that the white page section identifier is now visible around both sections

Mentored-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Sponsored-by: PTFS Europe
Signed-off-by: Hammat Wele <hammat.wele@inlibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32270: Add page section to label layouts
Jacob O'Mara [Fri, 18 Nov 2022 16:13:07 +0000 (16:13 +0000)]
Bug 32270: Add page section to label layouts

Test plan:
1) Navigate to `Cataloguing > Label creator > Manage label layouts`
2) Observe the missing page section surrounding the table
3) Apply patch
4) Observe that missing page section has now appeared

Mentored-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Sponsored-by: PTFS Europe
Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32010: 2AF selenium tests - Alert can appear when we are waiting for ajax
Jonathan Druart [Mon, 21 Nov 2022 06:55:52 +0000 (07:55 +0100)]
Bug 32010: 2AF selenium tests - Alert can appear when we are waiting for ajax

If we are waiting for ajax (there is a sleep 1s) and the alert pops up
at the same time, Selenium is raising "unexpected alert open"

We should not wait for the ajax request, but better wait for the
alert actually.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 31378: (QA follow-up) Defer store until JSON fields are populated
Tomas Cohen Arazi [Fri, 18 Nov 2022 15:29:55 +0000 (12:29 -0300)]
Bug 31378: (QA follow-up) Defer store until JSON fields are populated

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
23 months agoBug 32178: (QA follow-up) Correct modules import
Tomas Cohen Arazi [Fri, 18 Nov 2022 15:00:06 +0000 (12:00 -0300)]
Bug 32178: (QA follow-up) Correct modules import

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>