Commit graph

1638 commits

Author SHA1 Message Date
0f3a7074cb
Bug 31731: Offer user a dropdown of authorized values instead of a text field in preferences
This patch updates the system preferences interface so that preferences
which ask for a single authorized value can offer a dropdown menu of
choices instead of a text field.

The patch also updates a few existing preferences to use the new
feature: BundleLostValue, BundleNotLoanValue, and
ClaimReturnedLostValue.

To test, apply the patch and restart services.

- Go to Administration -> System preferences and search for "authorized
  value."
- The search results should include the entries for BundleLostValue,
  BundleNotLoanValue, and ClaimReturnedLostValue.
- Confirm that the dropdowns show the correct authorized value category
  (LOST or NOT_LOAN)
- Confirm that setting or unsetting each of the preferences works
  correctly.

Signed-off-by: Sam Lau <samalau@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-10-10 10:54:00 -03:00
db5642410b
Bug 34393: Fix inconsistencies in MARC bibliographic framework page titles, breadcrumbs, and header
This patch fixes some inconsistencies in the MARC bibliographic
framework administration page, making sure the page title, breadcrumb
navigation, and page headers are consistent with each other.

The file admin/marc_subfields_structure.pl is modified so that it
provides the framework name to the template.

Test each page to confirm that page title, heading, and breadcrumbs are
consistent:

- MARC bibliographic frameworks
  - New framework
  - Edit framework
  - Delete a framework which is not used
  - Delete a framework which is in use
  - Framework MARC structure
    - New tag
    - Edit tag
    - Delete tag
    - View subfields
    - Edit subfields

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>
2023-10-09 11:41:30 -03:00
f3ebd78dee
Bug 34300: Add holds column to order table
Adds the ability to easily place a hold on an ordered item from a basket

To test:
    1) Apply patch
    2) Go to acquisitions
    3) Go to an existing basket, or create a new one
    4) Add an order to the basket
    4) Notice there is a "Place hold" column in the Orders table
    5) Click the link for an item which allows you to place a hold easily on the biblio
    6) On the columns settings, toggle the "Place hold" column to hide it, and make sure it gets hidden

    Sponsored-by: Pymble Ladies’ College

Signed-off-by: Lisette Scheer <lisette.scheer@bywatersolutions.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-10-04 16:40:14 -04:00
151298709a
Bug 9525: (QA follow-up) Tidy
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-10-04 16:40:12 -04:00
Emmi Takkinen
7c22b12240
Bug 9525: Add option to define float groups and rules for float
Bug 22284 introduced ability to create hold groups.
We should have ability to create float groups in
same manner. This patch adds checkbox "Is local
float group" to group creation feature and new return
policy "Item floats by librarygroup".

To test:
1. Add new float group and some libraries to it.
2. From circulation and fine rules, set default
return policy as "Item floats by library group".
3. Check out an item for a patron.
4. Set library as one that belongs in the same
float group.
5. Check in the item.
=> Observe that notice for transfer doesn't pop up.
6. Check out again.
7. This time set library as one that doen's
belong in the same float group.
8. Check in.
=> Observe that notice for transfer pops up.

Experiment this feature by changing return policy
per library, item type etc.

Also prove t/db_dependent/Koha/Libraries.t

Sponsored-by: Koha-Suomi Oy

Signed-off-by: Lisette Scheer <lisettePalouse+Koha@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-10-04 16:40:10 -04:00
c6ef2aba6b
Bug 34369: Require CSRF token for updating system preferences
This patch adds the requirements that updating a system preference
requires a CSRF token. (Also, adding and deleting local system preferences.)

0. Apply patch
1. koha-plack --reload kohadev
2. Add local system preference
3. Update local system preference
4. Delete local system preference
5. Update normal system preference
6. Note no errors

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-09-25 18:18:40 -03:00
06c2b4898b
Bug 28449: Add column with invoice number to basket summary page
At the moment it's quite a lot of clicks to get from the basket
summary to the invoice something was received in. This adds a nice
shortcut by creating a new column for the invoicenumber in the basket
summary table.

To test:
* Make sure you have a basket with some received and unreceived
  order lines
* Verify that the (received) shows for your received lines
* Verify no invoice number or link to it in sight
* Apply patch
* Verify that there is now a column for the Invoice containing
  the invoice number as a link to the invoice
* Test with a staff patron, that doesn't have edit_invoices permission
* Verify that now instead of a link you see the invoice number as text

Be happy, sign off ;)

Note: this doesn't change the CSV export. The way the CSV is built is
quite different to the summary table, so it would be better handled
in a separate bug/patch. The columns are already quite different!

Sponsored-by: The Research University in the Helmholtz Association (KIT)

Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Michaela Sieber <michaela.sieber@kit.edu>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Émily-Rose Francoeur <emily-rose.francoeur@inLibro.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-09-25 10:53:50 -03:00
8922fb1863
Bug 34618: Add sort 1 and 2 fields to basket in acquisitions
This patch adds the option to display sort1 and sort2 columns in the
view of the contents of a basket in acquisitions. The columns are
labeled "Statistic 1" and "Statistic 2" to match the labels in the
order creation/edit form.

The fields are hidden by default in the updated table configuration.

To test, apply the patch and restart services.

- Go to acquisitions and create a basket if necessary:
  - Search for a vendor and click New -> Basket from the vendor
    toolbar on the vendor search results screen.
  - Create a basket, then click "Add to basket" from the basket details
    page.
  - Add an order to the basket.
- With at least one order in the basket, check the table of orders in
  the basket.
- The columns should be unchanged.
- The table configuration button should show the two statistics fields
  as hidden. Test that they can be displayed.

- Go to Administration -> Table settings.
  - Under Acquisitions -> basket, try changing the settings for the
    Statistic 1 and Statistic 2 fields, and check that your changes are
    reflected in the basket view.

- Test with a vendor which has an EDI account:
  - Enable the EDIFACT system preference.
  - Go to Administration -> EDI accounts and create an account for your
    vendor.
  - Confirm that the table of orders in your basket still displays
    correctly now that the "Supplier report" column is present.

Signed-off-by: Michaela Sieber <michaela.sieber@kit.edu>
Signed-off-by: Ray Delahunty <r.delahunty@arts.ac.uk>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-09-25 10:53:49 -03:00
Katrin Fischer
f9f9c3a7fa
Bug 34748: Fix column name in columns configuration for basket table
The first column was named basket_number, but it's actually the
order_line.

To test:
* Edit column configuration for acquisition > basket
* Make sure to set at least one checkbox for 'basket_number'
* Apply patch, run database update
* Verify that the first column is now 'order_line', but your
  settings have been preserved

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>
2023-09-25 10:53:45 -03:00
461cd34698
Bug 27634: Add the ability to exclude fields from "modal" sysprefs
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>
2023-09-19 16:34:18 -03:00
5f6e1a1cf7
Bug 34740: Update sort options in ES config to by Yes/No
At some point the option for 'undef' was removed from te sort options
and was collapsed to yes/no

The dropdowns when adding a new field were missed, this patch corrects that.

While undef in a mappings file wil stil load, when saving we should not privde undef any longer

To test:
1 - Browse to bottom to add a new field on the 'Bibliographic records' tab in
    Administration > Search engine configuration (Elasticsearch)
2 - Set sortable column to undef, set other columns and provide a valid field
3 - Click '+Add'
4 - Click 'Save'
5 - At top of page you receive an error:
 An error occurred when updating mappings: DBIx::Class::Storage::DBI::_dbh_execute(): DBI Exception: DBD::mysql::st execute failed: Column 'sort' cannot be null at /kohadevbox/koha/Koha/SearchField.pm line 37 .
6 - Apply patch, restart all
7 - Add a new mapping, your only choices are Yes/No
8 - Save mapping
9 - Confirm it saves correctly

Signed-off-by: Salah Ghedda <salah.ghedda@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-09-18 15:31:52 -03:00
21ff3d1675
Bug 27378: (QA follow-up) Tidy admin/preferences.pl
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-09-12 09:45:07 -03:00
49bfb9ff39
Bug 27378: Introduce cookie consent to OPAC and staff client
To avoid confusion around commit messages and the content of this enhancement, this first commit is a squashed commit of all the original code submited to this bug. Following a few years of inactivity, it has been rebased and re-submitted with some fixes and concept changes contained in the more recent commits.

Signed-ff-by: Barry Cannon <bc@interleaf.ie>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>

Bug 27378: (follow-up) Add missing filters

(cherry picked from commit 6b8565b949b62269f6d850e6d412458d0dbcfb37)
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>

Bug 27378: Fix accessibility issues

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>

Bug 27378: Update to new atomicupdate structure

This patch consolidates the previous 4 database update files into one atomicupdate file in line with the new structure

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>

Bug 27378: Change ConsentJS to CookieConsentedJS

This patch updates the name of the ConsentJS syspref to CookieConsentedJS and amends the description to be more clear what the syspref is for

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>

Bug 27378: Stop the codemirror editor and delete confirmation from duplicating

Previously, if the "Add new code button" was clicked in the CookieConsentedJS editor, the original entry would have duplicated CodeMirror editors.
This was exponential, i.e adding two new lines would result in three codemirror editors appearing on the first entry, two on the second and so on.
The click event was not being applied properly and was being applied to every element with the .expand-textarea class, rather than specifically the new elements being created. The addExpandHandler function now loops through each element individually and decides whether to apply the click event handler.

Similarly, the delete confirmation was dupliacting for the same reason. This has also been resolved.

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>

Bug 27378: Remove two sysprefs and replace with html customisations

Currently there are two sysprefs - CookieConsentBar and CookieConsentPopup. These allow the user to select what text they would like to see in the consent bar and modal. These have been removed and replaced with HTML customisations to allow more flexible customisations and different languages.

Sponsored by: PTFS-Europe

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>

Bug 27378: (QA follow-up) Small fixes and tidy-ups

This patch does the following:
- Realphabetizes the lines in sysprefs.sql
- Fixes a formatting error in patrons.pref
- Adjusts the position of the cookie consent bar if the language selector is visible
- Fixes translatability on the syspref modal

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>

Bug 27378: (QA follow-up) Allow staff to view their cookie consents

This patch allows staff to view their cookie consents through a link in the dropdown menu in the navbar. Previously staff had no way of accessing their cookie consents

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>

Bug 27378: (QA follow-up) Add cancel button to cookie modal

This patch adds a cancel button to the modal for reviewing cookie consents. Previously there was no way to exit without selecting one of the cookie options

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>

Bug 27378: (QA follow-up) Add filtering for OPAC only and staff only cookies

This patch fixes an issue where cookies selected as OPAC only would still show in the staff client and vise versa. The cookies are now filtered and only the correct cookies will be used in the OPAC and staff client

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>

Bug 27378: (QA follow-up) Fix tests and character encoding

This patch fixes an encoding issue when using diacritics. It also fixes a failing test, corrects the format of the "Cancel" links in the modal and perltidy has been used on all relevant files

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-09-12 09:45:07 -03:00
f0383e5f6a
Bug 34616: Fix showing default server info on edit SMTP server page
Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-09-01 11:07:30 -03:00
daedce4f6e
Bug 32271: (QA follow-up) Convert all positive numbers to monetary float and convert all 0 equivilents to blank value
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-07-19 13:00:37 -03:00
0992769f6e
Bug 34261: Add missing argument to show_account
This patch fixes a missing $crypt in the show_account function when deleting an edifact ordering account.

Test plan:
1) In system preferences search for EDIFACT and change EDIFACT to Enable
2) Navigate to Administration > EDI accounts
3) Create a dummy account
4) Try deleting the account using the delete button in the actions column on the far right
5) An error should be thrown - "Can't call method "decrypt_hex" on an undefined value"
6) Apply patch
7) Try deleting the account again
8) This time it should work and show the confirmation dialog box
9) Sign off

Signed-off-by: Sam Lau <samalau@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-07-14 15:23:16 -03:00
836dc32d62
Bug 34137: Requested cancellation date column missing from holds awaiting pickup table config
This patch adds an entry for the requested cancellation date column to
columns_settings.yml so that the column can be configured correctly in
table settings and on the fly.

To test you will need at least one hold with a cancellation request:

- Go to Administration -> Circulation and fine rules -> Default waiting
  hold cancellation policy
  - Add at least one rule allowing cancellation on waiting items.
- Place a hold for a patron which would fall under the rule you defined.
- Satisfy the hold by checking the item in at the hold's destination
  location.
- Cancel the hold, either by logging in to the OPAC as the patron with
  the hold, or in the staff client via the holds tab on the patron's
  record.

- Apply the patch and restart all services.
- Go to Circulation -> Holds awaiting pickup
- In the "Holds with cancellation requests" tab, confirm that there is a
  "Date cancellation requested" column and that it is one of the choices
  under the "Columns" button.
- Confirm that the correct columns are shown and hidden when making
  selections in the columns menu.
- Go to Administration -> Table settings -> Circulation -> Holds
  awaiting pickup.
   - Test setting "Is hidden by default" and "Cannot be toggled" for
     various columns in the table, including the "Date cancellation
     requested" column.

Signed-off-by: Quinn <quinn.morris@citruslibraries.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-07-10 15:43:16 -03:00
b5de15c4b8
Bug 33578: Fix controller when editing a restriction type
Do not display a warning when we are editing a restriction type and no
other types with this description exists.

Signed-off-by: Michaela Sieber <michaela.sieber@kit.edu>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-06-23 10:01:06 -03:00
af505c9117
Bug 33594: Only sort on title main heading
This patch simply remvoes sort from all elements that are not strictly
the main title

Note:
If multiple fields are set as sort, they are collapsed into a single entry in
the {field}__sort field in the ES index. The order will be determined by the order in
the marc record

To test:
1 - Apply patch
2 - perl misc/search_tools/rebuild_elasticsearch -r -v
3 - Search the catalog
4 - Sort by title
5 - Confirm records are correct
6 - Add a 240 (before the 245) with subfield a 'AAAAA'
7 - Confirm sorting is not affected
8 - View record details, click 'Elasticsearch record: Show'
9 - Find 'title__sort' and confirm it looks correct (does not include AAAAA)

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>
2023-05-18 11:03:28 -03:00
7f1f0bc5b7
Bug 33594: Update mappings and comment
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-05-18 11:03:28 -03:00
355d7de9a5
Bug 32450: Noissuescharge debit type exclusions
Currently the debit types to be excluded from the noissuescharge syspref are
hardcoded in non_issues_charges which gives no flexibility for selecting which
debit types should be included. This patch amends the subroutine to use a
database flag to identify which debit types should be included. It also adds a
column to the table in the Debit Types area of System Preferences which shows
which debit types are included. The ability to edit all debit types has been
added rather than just the non-system ones and the flag to include/exclude the
debit type from noissuescharge can be changed by clicking that edit button.

Test plan:
1) Choose a patron and add some fines to this patron that have different debit_types
2) Navigate to system preferences and observe that currently you can only amend
   the noissuescharge included debit types using three preferences:
   ManInvInNoissuesCharge, RentalsInNoissuesCharge, HoldsInNoissuesCharge
3) Apply both commits attached to this bug
4) Navigate as above and observe that these three system preferences are now gone
5) Navigate to Debit Types in System Preferences, the table should have a column
   called No issues charge that shows whether a debit_type is Included or Not
   included
6) Click the edit button and there should be a checkbox for Included in
   noissuescharge
7) Change some of the debit_types using this option and observe that the patron
   you added fines to will either be blocked from checkouts or able to checkout
   depending on which debit_types you include and the value of these fines.

Mentored-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Michaela Sieber <michaela.sieber@kit.edu>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-05-17 10:25:06 -03:00
Julian Maurice
b997250026 Bug 11844: Use additional fields for order lines
This patch allows to create additional fields for order lines.
Once created, these fields can be filled during order line creation or
modification.

If additional field is linked to a MARC field, there are two possible
scenario:
- MARC field mode = get: The field cannot be modified and its value is
  retrieved from the bibliographic record (current behaviour)
- MARC field mode = set: The field can be modified and its value is
  saved to the bibliographic record (new behaviour)

If additional field is linked to an authorised value category, then
authorised values are used. If not directly linked to an authorised
value category, but linked to a MARC field, a search for an AV category
is made on MARC default framework.

This patch doesn't display additional fields value anywhere (except in
order line creation/modification). Future patches will do that.

Test plan:
1/ Go to Acquisitions home
2/ In the left menu, click on "Add order line fields"
3/ Click on "New field" button
4/ Give the field a name (unique), no AV category and no MARC field.
5/ Save.
6/ Create 5 other fields:
   a/ no AV category, a MARC field not linked to AV category, MARC field
      mode = get
   b/ no AV category, a MARC field not linked to AV category, MARC field
      mode = set
   c/ no AV category, a MARC field linked to AV category, MARC field
      mode = get
   d/ no AV category, a MARC field linked to AV category, MARC field
      mode = set
   e/ an AV category, no MARC field
7/ Create everything you need to be able to create order lines
   (supplier, basket, ...)
8/ Create an order line. At bottom of the page, you should see your
   additional fields, with authorised values dropdrown list for fields
   (c), (d) and (e). Fields (a) and (c) should be disabled.
9/ Fill these fields with some data and save order line
10/ check that data was correctly saved into biblio for fields (b) and
    (d), but not for (a) and (c)
11/ modify the same order line, check that values you've filled are
    correctly retrieved and that values for (a) and (c) were correctly
    retrieved from the bibliographic record
12/ modify all values, save, and check biblio once again

Signed-off-by: Harold Dramer <harold.dramer@nyls.edu>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Michaela Sieber <michaela.sieber@kit.edu>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2023-05-16 12:58:38 +02:00
40b1b61cbf
Bug 30649: Vendor EDI account passwords should be encrypted in the database
We are storing edi vendor acccount passwords in clear text in the
database. Now that Koha has the Koha::Encryption module, we should
use that to encrypt passwords for all existing and new EDI accounts.

Test Plan:
1) Apply this patch
2) Create one or more EDI vendor accounts
3) Run a report to view the account passwords, note they are in clear
   text
4) Run updatedatabase.pl
5) Re-run the report, account passwords should be encrypted now
6) Edit a vendor EDI account, note you can still view and update the
   password for an account

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>
2023-05-15 18:23:49 -03:00
020bc275b0
Bug 33335: (QA follow-up) Polishing and comments
Just send the codes and descriptions only to client.
Adding a few comments to the reduce construction.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-05-12 17:50:09 -03:00
706cd01ba2
Bug 33335: Use To.json to serialize
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-05-12 17:50:08 -03:00
Katrin Fischer
2ef95d9142
Bug 33586: Fix sequence of fields for memberresultst in table configuration
The sequence of options actually matters, not the name.
Library and category were switched, this patch fixes it and
now it should all hide/show as expected:

* Go to administration > table configuration
* Hide library in memberresultst
* Go to patron search and search
* Verify that category was hidden instead
* Apply patch
* Verify now label and columns for library and category
  match with configuration.

Signed-off-by: Lisette Scheer <lisette.scheer@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-05-09 10:58:02 -03:00
33084fb40c
Bug 22440: New ILL requests table
Use kohaTable requesting the REST api instead of the old KohaTable

Co-authored-by: Tomás Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-05-05 09:13:41 -03:00
106adb320c
Bug 31695: Type standard number is missing field ci_raw in field_config.yaml
In Elasticsearch fields config field_config.yaml, default type as a field 'ci_raw'. This is used for exact search.
This field is missing for type  standard number 'stdno'.

Test plan :
1) In the staff interface, go to Administration, and search for SearchEngine
2) Make sure that the SearchEngine preference is set to Elasticsearch and save
3) Return to Administration and select "Search engine configuration"
4) Change the type of "Heading-Main" to "Std. Number" and save
5) Rebuild the index (e.g. "koha-elasticsearch --rebuild -d kohadev")
6) Go to the main staff page and select Authorities
7) Search for a heading (e.g. "A Dual-language book")
=> Result is found with or without patch
8) Click on the sliders and select "is exactly" for the operator and search
=> Result is found only with patch
9) Apply the patch
10) Rebuild the index (e.g. "koha-elasticsearch --rebuild -d kohadev")
11) Click on the sliders and select "is exactly" for the operator and search
=> Result is found only with patch

Signed-off-by: Kevin Carnes <kevin.carnes@ub.lu.se>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-04-14 11:35:35 -03:00
Katrin Fischer
6cbbfa27cb
Bug 32447: Clean up table configuraton settings for holdings table
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-03-31 19:19:26 +02:00
b0767f5eb6
Bug 33159: Simplify ES handling and fix zebra handling
Before this patch we used two indexes for the thesaurus values, we can
simply index both needed fields into a single index and just form the
search correctly.

This patch also ensures we pass the 'thesaurus' vlaue for the heading
directly to the query builder - for zebra it goes through, and for ES
we convert it to the expected code.

This patch also moves the necessary mappings out of the user definable
mappings and hardcodes them. There is precedent for this with
'match-heading', it ensures matching works as expected

To test:
1 - Follow previous test plan in Zebra and ES

Signed-off-by: Phil Ringnalda <phil@chetcolibrary.org>
Signed-off-by: Frank Hansen <frank.hansen@ub.lu.se>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-03-31 11:56:53 +02:00
10d12f999f
Bug 33341: Address some perlcritic errors in 5.36
Some old-style code is making our tests fail when run in Debian Testing.

This patch addresses this.

To test:
1. Launch bookworm KTD:
   $ KOHA_IMAGE=master-bookworm ktd up -d
2. Run:
   $ ktd --shell
  k$ prove t/00-testcritic.t
=> FAIL: It fails!
3. Apply the patch
4. Repeat 2
=> SUCCESS: Tests now pass!
5. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-03-28 14:50:33 +02:00
2792007245
Bug 33137: Make column names match
Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-03-27 11:30:00 +02:00
e657c3d5a9
Bug 33137: Add call number to pay-fines-table and table settings
To test:
1. Apply patch and restart_all
2. From a patron's Accounting tab add some invoices that are related to an item.
3. From the 'Make a payemnt' notice the new Call number column.
4. Using Table settings, make sure you can properly hide the column.

Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-03-27 11:29:59 +02:00
eae0a7e065
Bug 33137: Add Home library to pay-fines-table and table settings
To test:
1. Apply patch and restart_All
2. From a patron's Accounting tab add some invoices that are related to an item.
3. From the 'Make a payemnt' notice the new Home library column. Make sure it displays correctly and is the same as what you see on the 'Transactions' tab.
4. Using Table settings, make sure you can properly hide the column.

Signed-off-by: Sally <sally.healey@cheshiresharedservices.gov.uk>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-03-27 11:29:58 +02:00
375fbd1704 Bug 32421: Add collection column to holds to pull
To test:

1. Place some holds
2. Go to Circulation > Holds to pull
3. Notice there is not column to indicate collection ( CCODE )
4. Apply patch and restart services
5. Step 2 again, this time you should see a column for holds to pull
6. Using both the Columns button and via 'Table setting' attempt to hide the column and other columns. Ensure everything is being heiiden correctly.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Bug 32421: (follow-up) Correct table settings

Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-03-14 09:06:14 -03:00
87ae8b21b4
Bug 32977: Add callnumber column to boraccount.tt
To test:
1. Apply patch, restart_all
2. Create a manual invoice for an item that has an item.itemcallnumber
3. Go to the transaction tab and see that the particualar accountline contains a callnumber in the new callnumber column.
4. Make sure you can hide the column, and other columns, correctly via Table settings or via the Column  icon.

Signed off by: Michael Perry (Siskiyou County Library)

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-03-10 11:15:24 -03:00
dcf7688b94 Bug 31028: Add catalog concern management page to staff
This patch adds a catalog concern management page to the staff client
accessible via the cataloging home page and a new 'Pending catalog
concerns' link on the front page.

This includes added the requisit ticket_updates api endpoints and notice
triggers and templates for notifying patrons of changes to their
reported concerns.

Test plan
1) Enable the `OpacCatalogConcerns` system preference
2) Catalog concern management is tied to your users ability to edit the
   catalog, `editcatalogue`.
3) Confirm that you can see 'Catalog concerns' listed on the cataloging
   home page if you have the `editcatalogue` permission and not if you
   do not.
4) Add a new concern as an opac user.
5) Confirm that once a concern is present in the system you see a count
   of 'catalog concerns pending' on the intranet main page if you have
   the `editcatalogue` permission.
6) Click through either the cataloging home page or pending concerns
   link on the main page to view the new concerns management page.
7) Confirm the table displays as one would expect.
8) Confirm clicking on details or the concern title exposes a 'details'
   modal with the option to add an update or resolve the concern.
9) Verify that if selecting 'notify' when updateing or resolving a
   concern triggers a notice to be sent to the opac user who first
   reported the issue.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Helen Oliver <HOliver@tavi-port.ac.uk>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-03-06 11:23:17 -03:00
Katrin Fischer
0f042b02c7
Bug 32460: Add missing columns to table configuration for patron categories
The table settings were missing the recently added columns, resulting
in strange behaviour using the column visibility settings:

* patron expiration
* can be guarantee
* exclude from local holds priority

To test:
* Go to administration > patron categories
* Verify some columns are missing from the Columns selection
* Apply patch
* Verify the missing columns are now present and all columns
  can be hidden/unhidden as expected
* Change settings for the table in administration > table settings
* Verify the settings have the desired effect

Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-02-21 10:24:03 -03:00
Magnus Enger
6a0cd4cc5e
Bug 32922: Remove space in shebang
Some of our scripts have a space in the "shebang" (first) line:

  #! /usr/bin/perl

This is not illegal, and it does work, but it is good to be
consistent, so this patch removes the space.

To test:
- Run: grep -rn --include=*.pl '#! /usr/' *
- See the list of files that have a space in the shebang
- Apply the patch
- Run the command again, there should be no output, meaning there
  are no more files with space in the shebang
- Have a look at the patch and check that it only changes the
  shebangs
- Sign off

Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-02-20 09:44:06 -03:00
c5abf57f5a
Bug 22693: ILL "Price paid" column does not appear in column configuration
Test Plan:
 - Navigate to ILL requests page from the main menu after setting up your ILL backend.
 - Observe that Price Paid column does not exist either here nor in the column configuration.
 - Apply patch
 - Observe that Price Paid column now appears in ILL requests table and in the column configuration page.

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>
2023-02-15 09:23:05 -03:00
09010a248b
Bug 32603: Suggester category in Suggestions management
In Suggestions management, in the table displaying all suggestions, add
a column to display suggester category. This way, it is possible for
example for the librarian managing suggestions rather to prioritize
suggestions coming from teachers than those coming from students.

TEST :

1. Apply the patch.
2. Acquisition > Suggestions.
3. There is a new column 'Suggester category'. It can be
   displayed/hidden.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-02-07 15:30:33 -03:00
6f606e00c5
Bug 32797: Check if fields have a value, not if true
When saving OAI set mappgins we are checking for truth, this prevents
saving subfield 0. We should check for content

To test:
1 - Go to Admin->OAI sets
2 - Create a set
3 - Define mappings for the set
4 - Attempt to save a rule on field 952 subfield 0 (withdrawn)
5 - It does not save
6 - Apply patch
7 - Try again
8 - Success!

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>
2023-02-03 10:30:07 -03:00
be3d1ac857
Bug 20256: Update groups editor
Signed-off-by: Bob Bennhoff - CLiC <bbennhoff@clicweb.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-02-02 11:53:23 -03:00
29c263241d
Bug 27424: (QA follow-up) Make Koha::SMTP::Server->store deal with defaults
This patch makes the ->store method take care of setting the server as
the only default one.

To test:
1. Apply this patch
2. Run:
   $ kshell
  k$ prove t/db_dependent/Koha/SMTP/Server.t
=> SUCCESS: Tests pass!
3. The UI keeps working as it should.
4. Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-01-31 10:52:49 -03:00
26d1e6540d
Bug 27424: Add ability to specify an SMTP server in the database as the default server
Bug 22343 adds the ability to defined SMTP servers via the UI; But to then utilise them you have to go to each individual library via the libraries admin area and select the SMTP server.

We should have a way to override the fallback/default SMTP server right from the SMTP servers administration page.. setting one of our defined SMTP Servers as the system default rather than using the hard coded fallback options.

Test Plan:
1) Apply this patch set
2) Restart all the things!
3) Browser to the SMTP servers editor,
   verify only one server can be set as the default server
4) Set a default server, verify that server was used to send email from
   a cronjob, AND/OR prove t/db_dependent/Koha/SMTP/Server.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-01-31 10:52:48 -03:00
Slava Shishkin
9157a7e6db
Bug 32504: Fix typo columnname in columns_settings.yml
Trivial fix.

To reproduce:
1. Go to /cgi-bin/koha/admin/columns_settings.pl
2. Observe in the section Acquisition > Basket > Orders an empty field in the Column name, the row between fund and supplier_report rows: it was expected estimated_delivery_date value.
3. Apply the patch.
4. Restart Memcached (console: service memcached restart)
5. Reload cgi-bin/koha/admin/columns_settings.pl: that empty row now will have estimated_delivery_date value.

Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-01-31 09:39:57 -03:00
5e863f93c0
Bug 18247: Remove SQL queries from branch_transfer_limit.pl
1. Visit Administration > Patrons and circulation > Limit transfer limits

2. Observe collection codes are displayed as tabs on the Limit transfer
limits page when the BranchTransferLimitsType syspref = 'Collection
code'

3. Switch the BranchTransferLimitsType syspref = 'item type'. Refresh
the Limit transfer limits page and observe the tabs have changed to item
type codes

4. Apply patchset and restart services

5. Reload the Limit transfer limits page and confirm it displays
correctly with the  BranchTransferLimitsType = 'collection code' and
'item type'

6. Confirm you can successfully save transfer policies

Sponsored-by: Catalyst IT

Signed-off-by: Jacob Omara <jacob.omara@ptfs-europe.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2023-01-27 16:10:22 -03:00
2286524692
Bug 32348: Add library public in columns settings
Bug 27360 added public info on libraries table.
This should be added to columns settings.
Currently the column "STMP server" can not be managed in settings.

Test plan :
Play with columns settings of table Administration > Libraries

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-12-23 14:02:30 -03:00
Emmi Takkinen
91fc31c32b
Bug 30694: Set decreaseloanholds undef when deleting circulation rule
When one tries to delete rule with field "Decreased loan period
for high holds" filled, delete fails without errors. This happens
because rule isn't set in code section handling the delete in
smart-rules.pl.

To test:
1. Create a new circulation rule and fill all fields.
2. Try to delete the rule.
=> Rule isn't deleted, all fields except "Decreased loan period
for high holds" are now empty or have value "Unlimited".
3. Modify the rule and set field "Decreased loan period for high
holds" empty.
4. Delete the rule.
=> Rule is deleted successfully.
5. Create a new rule, fill all fields expect field "Decreased loan
period for high holds".
6. Delete the rule.
=> Rule is deleted successfully.
7. Apply this patch.
8. Again create a new rule with field "Decreased loan period for high holds" filled.
9. Try to delete the rule.
=> Rule is deleted successfully.

Sponsored-by: Koha-Suomi Oy

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
2022-12-23 14:01:43 -03:00
6ebd9b99bf
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>
2022-11-22 09:08:16 -03:00