]> git.koha-community.org Git - koha.git/log
koha.git
6 years agoBug 20366: (follow-up) Fix link to subscription
Josef Moravec [Thu, 2 Aug 2018 13:15:16 +0000 (13:15 +0000)]
Bug 20366: (follow-up) Fix link to subscription

Sponsored-by: BULAC - http://www.bulac.fr/
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20366: Add subscription info to the acq tab on the biblio detail page
Jonathan Druart [Tue, 8 May 2018 16:31:55 +0000 (13:31 -0300)]
Bug 20366: Add subscription info to the acq tab on the biblio detail page

On the "Acquisition details" tab of the bibliographic detail page, the
subscription information are missing.
This patch replace the call to GetHistory with Koha::Acquisition::Orders
in order to simplify the code and make use of new Koha::
packages/methods.

TODO: Add column settings (show/hide columns) to this table (?)

Sponsored-by: BULAC - http://www.bulac.fr/
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20366: Add new method Koha::Acquisition::Basket->basket_group
Jonathan Druart [Tue, 8 May 2018 16:32:47 +0000 (13:32 -0300)]
Bug 20366: Add new method Koha::Acquisition::Basket->basket_group

Can be moved to a separate bug report.

Sponsored-by: BULAC - http://www.bulac.fr/
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20366: Add new method Koha::Acquisition::Order->subscription
Jonathan Druart [Tue, 8 May 2018 16:30:44 +0000 (13:30 -0300)]
Bug 20366: Add new method Koha::Acquisition::Order->subscription

Can be moved to a separate bug report.

Sponsored-by: BULAC - http://www.bulac.fr/
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20365: Allow several orders on the same subscriptions
Jonathan Druart [Wed, 28 Mar 2018 15:53:42 +0000 (12:53 -0300)]
Bug 20365: Allow several orders on the same subscriptions

Do we really need this limitation?

Sponsored-by: BULAC - http://www.bulac.fr/
Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20726: (RM follow-up) Add missing filters
Nick Clemens [Thu, 30 Aug 2018 13:46:06 +0000 (13:46 +0000)]
Bug 20726: (RM follow-up) Add missing filters

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20726: Add title to the price column headers
Jonathan Druart [Mon, 4 Jun 2018 20:11:46 +0000 (17:11 -0300)]
Bug 20726: Add title to the price column headers

Sponsored-by: BULAC - http://www.bulac.fr/
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20726: Sort by statuses then ordernumbers
Jonathan Druart [Tue, 29 May 2018 20:10:58 +0000 (17:10 -0300)]
Bug 20726: Sort by statuses then ordernumbers

Not received and most recent at the top.

Sponsored-by: BULAC - http://www.bulac.fr/
Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20726: Add show/hide already received orders links
Jonathan Druart [Tue, 29 May 2018 19:59:05 +0000 (16:59 -0300)]
Bug 20726: Add show/hide already received orders links

Sponsored-by: BULAC - http://www.bulac.fr/
Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20726: Add DataTables
Jonathan Druart [Mon, 7 May 2018 23:07:28 +0000 (20:07 -0300)]
Bug 20726: Add DataTables

Sponsored-by: BULAC - http://www.bulac.fr/
Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20726: Add acquisition history on the subscription detail page
Jonathan Druart [Mon, 7 May 2018 23:00:25 +0000 (20:00 -0300)]
Bug 20726: Add acquisition history on the subscription detail page

Since bug 20365 is going to add the ability to create several pending orders on
the same subscription we should display the history of the acquisitions on the
subscription detail page.

Sponsored-by: BULAC - http://www.bulac.fr/
Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20726: Add new method Acquisition::Order->invoice
Jonathan Druart [Mon, 7 May 2018 22:46:05 +0000 (19:46 -0300)]
Bug 20726: Add new method Acquisition::Order->invoice

Can be moved to a separate bug report.

Sponsored-by: BULAC - http://www.bulac.fr/
Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20726: Add new method Koha::Acquisition::Order->fund
Jonathan Druart [Mon, 7 May 2018 22:29:19 +0000 (19:29 -0300)]
Bug 20726: Add new method Koha::Acquisition::Order->fund

Can be moved to a separate bug report.

Sponsored-by: BULAC - http://www.bulac.fr/
Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21207: Remove unused RM C4::Overdues::GetItems sub
Jonathan Druart [Mon, 6 Aug 2018 22:42:20 +0000 (19:42 -0300)]
Bug 21207: Remove unused RM C4::Overdues::GetItems sub

Test plan:
  git grep GetItems
  | grep -v GetItemsInCollection
  | grep -v GetItemsForInventory
  | grep -v GetItemsInfo
  | grep -v GetItemsLocationInfo
  | grep -v GetItemsAvailable
  | grep -v GetItemsByBiblioitemnumber

should not return any occurrences of code in perl scripts

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21157: Compiled CSS
Nick Clemens [Thu, 30 Aug 2018 13:21:35 +0000 (13:21 +0000)]
Bug 21157: Compiled CSS

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21157: Improve style of OPAC login modal
Owen Leonard [Mon, 13 Aug 2018 14:07:46 +0000 (14:07 +0000)]
Bug 21157: Improve style of OPAC login modal

This patch revises the style of the OPAC's login form modal view. The
goal is simply to make it look nicer.

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

In the OPAC, click the "Log in to your account" link at the top of the
page. It should trigger the login modal. While the modal is displayed,
resize the browser width to confirm that the form handles different
widths well.

Sign off if you think this is an improvement.

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 13618: (follow-up) Add html filters to all the variables
Jonathan Druart [Wed, 29 Aug 2018 17:38:56 +0000 (14:38 -0300)]
Bug 13618: (follow-up) Add html filters to all the variables

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21139: (follow-up) Floating toolbars - Remove unecessary height
Jonathan Druart [Wed, 15 Aug 2018 17:21:47 +0000 (14:21 -0300)]
Bug 21139: (follow-up) Floating toolbars - Remove unecessary height

Found where QAing bug 20935, we actually want the hidden toolbar to be
the exact same height as the visible one.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21183: Fix ->get_column call context
Jonathan Druart [Thu, 16 Aug 2018 15:12:11 +0000 (12:12 -0300)]
Bug 21183: Fix ->get_column call context

I am not sure to understand what's going on here.

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21183: Replace C4::Items::GetItemnumberFromBarcode calls
Jonathan Druart [Mon, 6 Aug 2018 18:53:33 +0000 (15:53 -0300)]
Bug 21183: Replace C4::Items::GetItemnumberFromBarcode calls

C4::Items::GetItemnumberFromBarcode calls can be replaced with
  Koha::Items->find({ barcode => $barcode });

We should make sure the barcode existed in DB and so that ->find
returns an object. Note that most of the time we just wanted to know if
the barcode existed.
The changes are very simple, the only one that need attention is
the one in batchMod.pl. It is basically reusing what we did on
bug 21141.

Test plan:
Use the batch item modification/deletion tools to modify/delete items
from their barcode (using the textarea or a file)

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21183: Remove GetItemnumberFromBarcode
Jonathan Druart [Mon, 6 Aug 2018 18:53:54 +0000 (15:53 -0300)]
Bug 21183: Remove GetItemnumberFromBarcode

Test plan:
  git grep GetItemnumberFromBarcode
should not return anything

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20740: Update two-column templates with Bootstrap grid, Administration part 4
Owen Leonard [Fri, 4 May 2018 15:18:59 +0000 (15:18 +0000)]
Bug 20740: Update two-column templates with Bootstrap grid, Administration part 4

This patch modifies several administration templates to use the
Bootstrap grid instead of YUI.

This patch also removes obsolete "text/javascript" attributes from
<script> tags in the modified templates.

To test, apply the patch and view the following pages, confirming that
they look correct at various browser widths:

 - Administration -> Currencies and exchange rates
   - View and edit currencies
 - Administration -> Did you mean?
 - Administration -> EDI accounts
   - View and edit accounts
 - Administration -> Library EANs
   - View and edit EANs
 - Administration -> Item search fields
   - View and edit item search fields

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20739: Update two-column templates with Bootstrap grid, Administration part 3
Owen Leonard [Tue, 1 May 2018 18:46:33 +0000 (18:46 +0000)]
Bug 20739: Update two-column templates with Bootstrap grid, Administration part 3

This patch modifies several acquisitions templates to use the Bootstrap
grid instead of YUI.

This patch also removes obsolete "text/javascript" attributes from
<script> tags in the modified templates.

To test, apply the patch and view the following pages, confirming that
they look correct at various browser widths:

 - Administration -> Columns settings
 - Administration -> Patron categories
   - View and edit patron categories
 - Administration -> Cities and towns
   - View and edit cities
 - Administration -> Classification sources
   - View and edit classification sources
 - Administration -> MARC bibliographic framework test

I'm not sure if this standalone interface is actually in use, but you
can navigate directly to /cgi-bin/koha/admin/clone-rules.pl to see a
form which is usually submitted from the circulation and fines rules
interface. View the page to confirm it looks correct.

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20738: Update two-column templates with Bootstrap grid, Administration part 2
Owen Leonard [Tue, 1 May 2018 18:31:00 +0000 (18:31 +0000)]
Bug 20738: Update two-column templates with Bootstrap grid, Administration part 2

This patch modifies several acquisitions templates to use the Bootstrap
grid instead of YUI.

This patch also removes obsolete "text/javascript" attributes from
<script> tags in the modified templates.

To test, apply the patch and view the following pages, confirming that
they look correct at various browser widths:

 - Administration -> Authority types
   - View list of and edit authority types
     -> MARC tag structure for an authority type
        - View list of and edit tags
          -> Subfields
             - View list of and edit subfields
 - Administration -> MARC bibliographic framework
   - View list of and edit frameworks
 - Administration -> Libraries
   - View and edit libraries
 - Administration -> Library transfer limits

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20736: Update two-column templates with Bootstrap grid, Administration part 1
Owen Leonard [Tue, 1 May 2018 17:39:51 +0000 (17:39 +0000)]
Bug 20736: Update two-column templates with Bootstrap grid, Administration part 1

This patch modifies several acquisitions templates to use the Bootstrap
grid instead of YUI.

This patch also removes obsolete "text/javascript" attributes from
<script> tags in the modified templates.

To test, apply the patch and view the following pages, confirming that
they look correct at various browser widths:

 - Administration -> Budgets
   - View budgets list, view and edit budgets
   - View budget -> Planning -> Plan by months
 - Administration -> Funds
   - View funds list, view and edit funds
 - Acquisitions -> Vendor -> Contracts
   - View contracts list, view and edit contracts
 - Administration -> Audio alerts
 - Administration -> Authorized values

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 19991: Remove warning from opac-user
Jonathan Druart [Wed, 15 Aug 2018 18:17:57 +0000 (15:17 -0300)]
Bug 19991: Remove warning from opac-user

Use of uninitialized value in split at
/home/vagrant/kohaclone/opac/opac-user.pl line 78.

Use of uninitialized value $search_query in string ne at
/home/vagrant/kohaclone/opac/opac-user.pl line 367.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 19991: use Modern::Perl in OPAC perl scripts
Charlotte Cordwell [Wed, 17 Jan 2018 20:46:59 +0000 (20:46 +0000)]
Bug 19991: use Modern::Perl in OPAC perl scripts

Test Case:
Check the following files have been updated from
use strict;
use warnings;
to
use Modern::Perl;

errors/400.pl
errors/401.pl
errors/402.pl
errors/403.pl
errors/404.pl
errors/500.pl
opac-account-pay-paypal-return.pl
opac-alert-subscribe.pl
opac-authorities-home.pl
opac-authoritiesdetail.pl
opac-browser.pl
opac-ics.pl
opac-image.pl
opac-imageviewer.pl
opac-messaging.pl
opac-modrequest-suspend.pl
opac-modrequest.pl
opac-mymessages.pl
opac-overdrive-search.pl
opac-passwd.pl
opac-patron-image.pl
opac-privacy.pl
opac-ratings-ajax.pl
opac-ratings.pl
opac-readingrecord.pl
opac-renew.pl
opac-sendshelf.pl
opac-serial-issues.pl
opac-showreviews.pl
opac-suggestions.pl
opac-tags_subject.pl
opac-topissues.pl
opac-user.pl
sco/help.pl
sco/printslip.pl
sco/sco-patron-image.pl
svc/overdrive_proxy
svc/suggestion
unapi

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21096: Do not display loggedinusername in template
Jonathan Druart [Wed, 25 Jul 2018 15:25:58 +0000 (12:25 -0300)]
Bug 21096: Do not display loggedinusername in template

This patch is a little fix for a much bigger hidden issues.

The original issue:
1. Set the firstname and surname values of a paontr to utf-8 characters
("wide characters"), for instance 月月
2. Use this patron to login at the staff interface
=> In the header the logged in patron's info (concat of firstname and
surname) are displayed correctly
3. Hit whatever link
=> In the header the info are now displayed incorrectly
("ææ")

What happens?
After that the user loggin, loggedinusername is set with the value from
the DB (borrowers.userid)
On next hits it is picked from the session (which contains the decoded
utf8 value, see first lines of C4::Context->set_userenv)
From C4::Auth::checkauth:
834             $s_userid = $session->param('id') // ''

The quick fix is to use the logged_in_user variable in the template, but
it seems that issues may occurred if external authentication is used
(ldap, shib, cas). Could someone test this?

Test plan:
Make sure the original issue is fixed

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21168: Handle deleted checked-in items on checking in
Jonathan Druart [Fri, 10 Aug 2018 20:02:38 +0000 (17:02 -0300)]
Bug 21168: Handle deleted checked-in items on checking in

circ/returns.pl generates a server error when attempting to checkin an item while
the list of previously-returned items contains an item that has been deleted.
Error text: Can't call method "biblio" on an undefined value at /usr/share/koha/intranet/cgi-bin/circ/returns.pl line 606.

Test plan:
- checkout two items
- checkin item1
- on a separate tab, delete item1
- on the original tab (which still shows item1 in the list of Checked-In Items), attempt to check in item2
=> No error appears

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21231: BlockReturnofLostItems does not prevent lost items being found
Kyle M Hall [Thu, 16 Aug 2018 11:11:17 +0000 (07:11 -0400)]
Bug 21231: BlockReturnofLostItems does not prevent lost items being found

When the syspref BlockReturnOfLostItems is set to Block, the item is blocked from being returned, but is still considered found -- it's set to lost=0 and a refund is applied to the patron (if circ rules allow). The item can then be checked in a second time and returned as it is no longer lost.

Test Plan:
1) Set an item to lost
2) Set BlockReturnOfLostItems to Block
3) Check the lost item in
4) Checkin  message should say item is lost and cannot be returned
5) Check lost status of item, it should remain unchanged

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21231: Add Unit Test
Kyle M Hall [Thu, 16 Aug 2018 11:10:43 +0000 (07:10 -0400)]
Bug 21231: Add Unit Test

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21068: DBRev 18.06.00.021
Nick Clemens [Thu, 30 Aug 2018 10:59:58 +0000 (10:59 +0000)]
Bug 21068: DBRev 18.06.00.021

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21068: Remove table borrower_sync if needed
Jonathan Druart [Fri, 24 Aug 2018 20:00:31 +0000 (17:00 -0300)]
Bug 21068: Remove table borrower_sync if needed

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21068: DB changes
Jonathan Druart [Wed, 15 Aug 2018 15:49:02 +0000 (12:49 -0300)]
Bug 21068: DB changes

The update DB entry will not remove the prefs if NorwegianPatronDBEnable
is set.
This patch could be reverted locally by people using it.

Signed-off-by: Benjamin Rokseth <benjamin.rokseth@deichman.no>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21068: Remove NorwegianPatronDB related code
Jonathan Druart [Mon, 13 Aug 2018 16:49:56 +0000 (13:49 -0300)]
Bug 21068: Remove NorwegianPatronDB related code

Bug 11401 introduced code to support Norwegian national library card.
This code is too specific to be part of Koha as it, it should be a
plugin instead.
Moreover nobody uses it, but a modified version (see comment 3).

Test plan:
Add/edit/delete patron and make sure there are no regressions introduced
by these patches

Signed-off-by: Benjamin Rokseth <benjamin.rokseth@deichman.no>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21199: (QA follow-up) Add show_attributes to perldoc
Martin Renvoize [Mon, 13 Aug 2018 08:54:44 +0000 (09:54 +0100)]
Bug 21199: (QA follow-up) Add show_attributes to perldoc

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21199: Hide patron's attributes from ILSDI if required
Jonathan Druart [Thu, 9 Aug 2018 22:34:58 +0000 (19:34 -0300)]
Bug 21199: Hide patron's attributes from ILSDI if required

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 13618: (follow-up) Manually replace missing .raw
Jonathan Druart [Fri, 24 Aug 2018 22:15:18 +0000 (19:15 -0300)]
Bug 13618: (follow-up) Manually replace missing .raw

Must be |$raw, not |raw

Error:
Template process failed: undef error - raw: filter not found at
/home/vagrant/kohaclone/C4/Templates.pm line 122

To recreate:
Add a new restriction and visit circulation.pl?borrowernumber=42

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 15524: (RM follow-up) Update schema files
Nick Clemens [Sat, 25 Aug 2018 15:16:47 +0000 (15:16 +0000)]
Bug 15524: (RM follow-up) Update schema files

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 15524: DBRev 18.06.00.020
Nick Clemens [Fri, 24 Aug 2018 16:03:50 +0000 (16:03 +0000)]
Bug 15524: DBRev 18.06.00.020

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 15524: (RM follow-up) Fix calls and add filter
Nick Clemens [Fri, 24 Aug 2018 15:10:45 +0000 (15:10 +0000)]
Bug 15524: (RM follow-up) Fix calls and add filter

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 15524: (QA follow-up) Change Can[Book|Item]BeReserved to return hashref, pass...
Kyle M Hall [Fri, 10 Aug 2018 14:36:36 +0000 (10:36 -0400)]
Bug 15524: (QA follow-up) Change Can[Book|Item]BeReserved to return hashref, pass limit to template

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 15524: (QA follow-up) Respect ReservesControlBranch
Kyle M Hall [Fri, 10 Aug 2018 14:36:53 +0000 (10:36 -0400)]
Bug 15524: (QA follow-up) Respect ReservesControlBranch

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 15524: (QA follow-up) Pass max_holds at the right position in update
Marcel de Rooy [Fri, 16 Feb 2018 11:12:12 +0000 (12:12 +0100)]
Bug 15524: (QA follow-up) Pass max_holds at the right position in update

When updating max_holds should be before the categorycode in the update
query.
Things that can be found by testing :)

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 15524: (QA follow-up) Fix meaningless test
Marcel de Rooy [Fri, 16 Feb 2018 08:02:39 +0000 (09:02 +0100)]
Bug 15524: (QA follow-up) Fix meaningless test

The last test claims to allow a hold when branch=5 and patron=5, but look
at the preceding statements:
    $rule_branch->max_holds(5);
    $rule_branch->update();
    $rule_branch->max_holds(5);
    $rule_branch->insert();
The last insert will not be done, since the record is already present.
A create should have triggered an error on the primary key.
Obviously, we should use $rule_all.

Test plan:
Run the test again.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 15524: (QA follow-up) - Change language used
Kyle M Hall [Tue, 9 Jan 2018 19:56:46 +0000 (14:56 -0500)]
Bug 15524: (QA follow-up) - Change language used

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 15524: Set limit on maximum possible holds per patron by category
Kyle M Hall [Wed, 28 Jun 2017 12:54:03 +0000 (08:54 -0400)]
Bug 15524: Set limit on maximum possible holds per patron by category

It's possible to set a limit on the maximum number of holds for a particular branch/category/itemtype, but not on the total number of holds for a given patron (by branch/category).
This new rule works in conjunction with the existing branch/borrower/item rules in that Koha will use the lower of the two limits. This new rule counts all holds of all types, which prevents bib-level holds from not being counted for the purpose of these limits. This makes the most sense and was also requested by the sponsor.

Test Plan:
1) Apply this patch
2) Run updatedatabase.pl
3) Go to the circ rules editor, note the new max holds rules
   by patron category in the "Checkout limit by patron category".
   ( Should we rename this section? )
4) Create find a patron that is allowed to place a hold, count the
   number of holds that patron has. Lets make that number 'X'.
5) Set the new max holds rule to X for "All libraries"
6) Note the patron can no longer place another hold
7) Set the new max holds rule to X + 1 for the patron's home library
8) Note the patron can again place another hold
9) Set the new max holds rule to X for the patron's home library
10) Note the patron can no longer place another hold

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 19039: (RM follow-up) Add filters to variables
Nick Clemens [Fri, 24 Aug 2018 12:00:54 +0000 (12:00 +0000)]
Bug 19039: (RM follow-up) Add filters to variables

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 19039: (follow-up) Results of virtual shelves (lists) not sortable by date
Maryse Simard [Fri, 20 Jul 2018 21:20:23 +0000 (17:20 -0400)]
Bug 19039: (follow-up) Results of virtual shelves (lists) not sortable by date

    In the staff client, when viewing the content of a list, it can be sorted by 'title', 'author' or 'call number' but not by 'date added'.

    This patch adds 'date added' as an option for default sorting of lists. It also makes it available as a sorting option while viewing lists.

    Test plan:
    In the staff client and the opac:
    1) View a list containing several items
      => Notice that you can't sort by 'date added'
    2) Try to edit the list or create a new one
      => Notice you can't choose date added as the default sort order
    3) Apply the patch
    4) When viewing the list you should now be able to sort by date added
      => Make sure it orders correctly
    5) Edit or create a list and choose date added as default sorting order
      => Make sure it uses date added as default
      => On the staff client: test that the filter for 'sort by' works for date added
      => On the opac: test that, while viewing the contents, choosing 'default sorting' in the dropdown menu sorts correctly

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 19039: Results of virtual shelves (lists) not sortable by date
Maryse Simard [Tue, 12 Jun 2018 17:42:23 +0000 (13:42 -0400)]
Bug 19039: Results of virtual shelves (lists) not sortable by date

In the staff client, when viewing the content of a list, it can be sorted by 'title', 'author' or 'call number' but not by 'date added'.

Test plan:
1) In the staff client, view a list containing several items
2) Notice that you can't sort by 'date added'
3) Apply the patch
4) Repeat step 1
5) The list can now be sorted by 'date added'

Signed-off-by: Dilan Johnpullé <dilan@calyx.net.au>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21209: (bug 20828 follow-up) Step 4 of moremember is used for Housebound and...
Jonathan Druart [Mon, 13 Aug 2018 18:07:05 +0000 (15:07 -0300)]
Bug 21209: (bug 20828 follow-up) Step 4 of moremember is used for Housebound and additional attributes

Test plan:

1) Make sure the HouseboundModule is enabled in system preferences
2) Go to a patron file
3) Next to Housebound roles, click on "Add"
4) Check "Yes" next to one of the two roles (or both)
5) Click "Save"
6) The "Add" button is now "Edit", click on it

The page is the one to edit housebound roles.

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21239: (RM follow-up) regenerate staff css
Nick Clemens [Fri, 24 Aug 2018 11:47:29 +0000 (11:47 +0000)]
Bug 21239: (RM follow-up) regenerate staff css

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21239: CSS regressions caused by SCSS move
Owen Leonard [Fri, 17 Aug 2018 12:47:52 +0000 (12:47 +0000)]
Bug 21239: CSS regressions caused by SCSS move

This patch corrects some mistakes in staff-global.scss made during the
conversion from CSS.

To test, apply the patch and regenerate your CSS
(https://wiki.koha-community.org/wiki/Working_with_SCSS_in_the_OPAC_and_staff_client).
Clear your browser cache if necessary.

View various forms in the staff client which have hints and required
fields, including:

- Notices & slips -> Modify notice
- Administration -> Budgets -> Modify budget

Verify that date format hints are positioned correctly. Try to submit
the form with empty required fields and verify that the "This field is
required" message is positioned correctly.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21237: Clean up staff client SCSS
Owen Leonard [Thu, 16 Aug 2018 14:25:39 +0000 (14:25 +0000)]
Bug 21237: Clean up staff client SCSS

This patch removes a redundant linter configuration, .sass-lint.yml,
which was added by mistake.

Some linter rules have been modified to better conform to the defacto
standard set by our existing CSS.

staff-global.scss has been corrected to comply with linter rules
(https://github.com/brigade/scss-lint/blob/master/lib/scss_lint/linter/README.md):

- Comment, style: silent
- TrailingSemicolon, true
- Shorthand
- ColorKeyword, enabled: true
- PropertySortOrder

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20984: Add 300$f to display
Joy Nelson [Fri, 22 Jun 2018 20:48:25 +0000 (13:48 -0700)]
Bug 20984: Add 300$f to display

Adding Type of Unit (300$f) to the Opac details and staff side searches results and details display

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 17625: adding subfields f and g to XSLT display
Joy Nelson [Fri, 22 Jun 2018 18:56:11 +0000 (11:56 -0700)]
Bug 17625: adding subfields f and g to XSLT display

Adding 245$f and 245$g to the Results and Detail pages on OPAC and staff side

Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
Signed-off-by: Cab Vinton <bibliwho@gmail.com>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21182: Remove acqui/check_duplicate_barcode_ajax.pl
Jonathan Druart [Mon, 6 Aug 2018 18:38:58 +0000 (15:38 -0300)]
Bug 21182: Remove acqui/check_duplicate_barcode_ajax.pl

It has been added by
  commit 327be442bd6e63e5ff8c0a5e2461ae836e8deffb
  Bug 6963: Corrects a problem when a new order is created with a duplicate barcode.

But its last call removed since:
  commit eefc774e274ce8167f1063be5f9204a0d5cf5650
  Bug 7178: Acquisition item creation improvement

Test plan:
  git grep check_duplicate_barcode
should not return anything

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20248: (QA follow-up) Remove unnecessary stuff
Julian Maurice [Wed, 8 Aug 2018 12:33:11 +0000 (14:33 +0200)]
Bug 20248: (QA follow-up) Remove unnecessary stuff

- Remove useless 'action' attribute in forms
- $op should never be equal to 'reset', so remove the test
- Move 'op' parameter inside <button>s to avoid having different HTML
  tags for elements that have the same kind of behaviour

Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20248: Improve Elasticsearch mappings UI and rebuild_elastic_search.pl.
Ere Maijala [Mon, 19 Feb 2018 14:54:39 +0000 (16:54 +0200)]
Bug 20248: Improve Elasticsearch mappings UI and rebuild_elastic_search.pl.

Improvements:
1) Mappings UI now has button that allows one to reset the mappings.
2) Mappings UI displays the items in alphabetical order.
3) Indexing script drops and recreates the index right away, which
helps prevent ES from autocreating a bad index if someone does something
while the first batch of records is being processed.
4) Indexing script has nicer output.

To test:
1) Change mappings.yaml file
2) Reset mappings in UI in mappings.pl
3) Verify the mappings have been changed in UI
4) The field order is alphabetical
5) Rebuild script has clean output
6) Run test t/db_dependent/Koha_Elasticsearch_Indexer.t

Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 19719: DBRev 18.06.00.019
Nick Clemens [Wed, 22 Aug 2018 13:57:02 +0000 (13:57 +0000)]
Bug 19719: DBRev 18.06.00.019

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 19719: (follow-up) Add database update to keep collection column hidden
Katrin Fischer [Tue, 19 Jun 2018 22:16:38 +0000 (00:16 +0200)]
Bug 19719: (follow-up) Add database update to keep collection column hidden

For existing installations we want to keep the current behaviour.
This patch adds the column configuration to hide the collection
column from the details and checkouts tabs until toggled.

Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 19719: (follow-up) Show description instead of code
Katrin Fischer [Sat, 31 Mar 2018 08:13:57 +0000 (10:13 +0200)]
Bug 19719: (follow-up) Show description instead of code

This follow-up changes the display from collection code
to description, following the existing pattern for
location.

To test:
- Repeat test plan from first patch
- Verfiy now the collection descrption shows
- Change column setting in administration
- Verify they work as expected

Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 19719: Add new column for collection in the patron checkouts data tables
Jesse Maseto [Fri, 2 Mar 2018 13:11:44 +0000 (13:11 +0000)]
Bug 19719: Add new column for collection in the patron checkouts data tables

This makes the collection visible in the checkouts table
on the details and issues tab in the patron account in staff.

TEST:

1. Check out a few items to patron.
2. View check outs on patron account in staff client.
3. Collection code is not present.

4. Apply patch

5. Notice that not Collection code is visible while viewing check outs.

Signed-off-by: Severine QUEUNE <severine.queune@bulac.fr>
Signed-off by: Maksim Sen <maksim.sen@inlibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 15408: Fix tests to fail without patch
Nick Clemens [Tue, 7 Aug 2018 13:37:30 +0000 (13:37 +0000)]
Bug 15408: Fix tests to fail without patch

We set all the timestamps to a specified date and ensure the new budgets
don't have this date

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 15408: Remove fund's timestamp when cloning a budget
Baptiste Wojtkowski [Fri, 3 Feb 2017 15:22:36 +0000 (15:22 +0000)]
Bug 15408: Remove fund's timestamp when cloning a budget

To duplicate the budget, the function CloneBudgetHierarchy create a new budget
from the old without the parameter timestamp, so that the database generates a
new one.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Added unit tests to patch

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Modified to run properly the QA tests

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21150: add the biblionumber to the output
Jonathan Druart [Tue, 7 Aug 2018 14:14:54 +0000 (11:14 -0300)]
Bug 21150: add the biblionumber to the output

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21150: Search for item types inconsistencies
Jonathan Druart [Fri, 3 Aug 2018 17:59:33 +0000 (14:59 -0300)]
Bug 21150: Search for item types inconsistencies

search_for_data_inconsistencies.pl will now display errors if:
1.item-level_itypes is set to "specific item" and items.itype is not set
or not set to an item type defined in the system (itemtypes.itemtype)
2.item-level_itypes is set to "biblio record" and biblioitems.itemtype is not set
or not set to an item type defined in the system (itemtypes.itemtype)

Test plan:
Use the script and the different possible combinations to display the
errors

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20509: Add to script documentation
Katrin Fischer [Tue, 31 Jul 2018 16:23:43 +0000 (16:23 +0000)]
Bug 20509: Add to script documentation

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20509: Search for not defined authority codes
Jonathan Druart [Wed, 27 Jun 2018 18:35:57 +0000 (15:35 -0300)]
Bug 20509: Search for not defined authority codes

This patch adds a new check in
misc/maintenance/search_for_data_inconsistencies.pl to search for not
defined authority codes.

Test plan:
Set some auth_header.authtypecode to not defined authority codes in Koha
(UPDATE auth_header SET authtypecode="XXX" WHERE authid=42;)
Then run `misc/maintenance/search_for_data_inconsistencies.pl`

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21011: (follow-up) Fix pod, fix missing homebranch condition, change mode to...
Josef Moravec [Wed, 27 Jun 2018 20:27:09 +0000 (20:27 +0000)]
Bug 21011: (follow-up) Fix pod, fix missing homebranch condition, change mode to executable

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21011: Search for items with not defined homebranch and/or holdingbranch
Jonathan Druart [Wed, 27 Jun 2018 18:32:56 +0000 (15:32 -0300)]
Bug 21011: Search for items with not defined homebranch and/or holdingbranch

From bug 5789: scripts can fail if items.homebranch and/or
items.holdingbranch is not defined

This script will help people catching these migration issues.

Test plan:
Update your items table to set some homebranch or holdingbranch to NULL
Run this script
It will display the different items with not defined values in these
fields.

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20631: Remove unused RemoveLostItem from C4::Accounts
Katrin Fischer [Wed, 8 Aug 2018 20:34:32 +0000 (20:34 +0000)]
Bug 20631: Remove unused RemoveLostItem from C4::Accounts

RemoveLostItem was 'used' in C4::Accounts, but is not
actually used there.

Call has been removed by
  commit ed9cf81c3aa8fd82f9347556364e9d2e6cef8a82
  Bug 15896 - Use Koha::Account::pay internally for makepayment

To test:
- Verify that the routine was actually not used!

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20487: DBRev 18.06.00.018
Nick Clemens [Wed, 22 Aug 2018 12:34:45 +0000 (12:34 +0000)]
Bug 20487: DBRev 18.06.00.018

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20487: (QA follow-up) Requested db revision
Marcel de Rooy [Thu, 31 May 2018 07:02:12 +0000 (09:02 +0200)]
Bug 20487: (QA follow-up) Requested db revision

As requested in comment12, we can update these cases in a dbrev too.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Checked out item, deleted issue record, ran dbrev.

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20487: AddReturn should clear items.onloan for unissued items
Marcel de Rooy [Wed, 28 Mar 2018 14:25:07 +0000 (16:25 +0200)]
Bug 20487: AddReturn should clear items.onloan for unissued items

If an item is no longer issued but somehow still has a date in the onloan
column, checking it in should clear that date.
Adding a ModItem call in the NotIssued section.

Test plan:
[1] Run t/db_dependent/Circulation.t
[2] Bonus: Checkout item, delete issue from table, checkin. Verify that
    items.onloan has been cleared.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Charles Farmer <charles.farmer@inLibro.com>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20504: Fix lang attribute in html tag on systempreferences page
Katrin Fischer [Thu, 9 Aug 2018 17:46:09 +0000 (17:46 +0000)]
Bug 20504: Fix lang attribute in html tag on systempreferences page

On the system preferences page the lang attribute of the
html tag is always empty.

To test:
- Go to systempreferences
- Check the html source and look at the html tag,
  it should read: <html lang="">
- Apply patch
- Check the html source again: <html lang="en">
  Verify the language code shown matches the currently
  selected language in the staff interface
- Verify the language system preferences work correctly

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
The problem was actually that
  $lang = $template->param( 'lang' );
should certainly be $lang = $input->param( 'lang' );
and, as it, it overrides the value of 'lang' passed from C4::Auth

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21234: (RM follow-up) regenerate staff css
Nick Clemens [Wed, 22 Aug 2018 12:06:32 +0000 (12:06 +0000)]
Bug 21234: (RM follow-up) regenerate staff css

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21234: Remove our .clearfix class in favor of Bootstrap's
Owen Leonard [Thu, 16 Aug 2018 13:02:34 +0000 (13:02 +0000)]
Bug 21234: Remove our .clearfix class in favor of Bootstrap's

This patch removes the ".clearfix" declaration from staff-global.scss so
that Bootstrap's built-in clearfix class will be used.

To reproduce this issue, see Administration -> Currencies and exchange
rates. The table of currencies does not appear below the table buttons.

Apply the patch and regenerate CSS
(https://wiki.koha-community.org/wiki/Working_with_SCSS_in_the_OPAC_and_staff_client).

Clear the browser cache if necessary and reload the Currencies and
exchange rates page. The table should appear in the correct position.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 7996: (QA follow-up) Remove unnecessary permission check view logs template
Katrin Fischer [Mon, 20 Aug 2018 07:04:37 +0000 (07:04 +0000)]
Bug 7996: (QA follow-up) Remove unnecessary permission check view logs template

Permission is checked in the perl file, no need to check again
in the template.

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 7996: Correct wrong permissions for modification log
Nick Clemens [Fri, 17 Aug 2018 11:07:41 +0000 (11:07 +0000)]
Bug 7996: Correct wrong permissions for modification log

To test:
 1 - Create a staff patron with catalogue,borrowers,and view_system_logs
     permissions
 2 - Log in using that patron
 3 - Go to tools
 4 - Click 'Log viewer'
 5 - You get a blank page
 6 - View borrower circ screen, note you do not see 'Modification log'
 7 - Edit a borrower, note you do not see 'Modification log'
 8 - Apply patch
 9 - 'Log Viewer' should now load correctly
10 - You should see 'Modification log' tab during circ
11 - You should see 'Modification log' tab when editing patron

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21243: (follow-up) Remove extra '</div>' tag
Nick Clemens [Tue, 21 Aug 2018 13:38:42 +0000 (13:38 +0000)]
Bug 21243: (follow-up) Remove extra '</div>' tag

To test:
1 - Go to Admin->Z39/SRU servers
2 - Pick a server or add one
3 - Click 'Modify' button for mappings
4 - Copy the HTML of the popup into w3c validator
https://validator.w3.org/#validate_by_input
5 - Note extra closing div
6 - Apply patch
7 - Repeat
8 - Success

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21243: Regression: SRU mapping popup for bibliographic records is unstyled
Owen Leonard [Fri, 17 Aug 2018 14:19:20 +0000 (14:19 +0000)]
Bug 21243: Regression: SRU mapping popup for bibliographic records is unstyled

This patch corrects a regression caused by Bug 21151: The include file
which adds CSS to the page was removed from the template.

To test, apply the patch and go to Administration -> Z39.50/SRU servers
-> New SRU server.

- Click the "Modify" button next to "SRU Search fields mapping"
- Verify that the pop-up window is correctly styled.

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20994: Fix capitaization "Save to Lists"
Katrin Fischer [Wed, 8 Aug 2018 20:28:29 +0000 (20:28 +0000)]
Bug 20994: Fix capitaization "Save to Lists"

On the OPAC result list, below each result, there is a link:
"Save to Lists".

Patch changes this to "Save to lists" following our
capitalization rules.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 19511: Local cover images not centered in table column in staff client search...
Owen Leonard [Thu, 26 Jul 2018 15:36:24 +0000 (15:36 +0000)]
Bug 19511: Local cover images not centered in table column in staff client search results

This patch modifies the JavaScript which embeds local cover images in
staff client catalog search results. It now adds the "thumbail" class to
the image, matching Amazon cover images.

To test you should have one or more titles with local cover images
attached. Apply the patch and clear your browser cache if necessary.

Enable both the AmazonCoverImages and LocalCoverImages system
preferences and perform a search which will return titles with local
cover images. Confirm that local covers are styled like Amazon covers.

Tested and confirmed local cover images are appearing quite nicely now.
Signed-off-by: Dilan Johnpullé <dilan@calyx.net.au>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 19500: Add missing span for 'other'
Jonathan Druart [Fri, 17 Aug 2018 16:20:04 +0000 (13:20 -0300)]
Bug 19500: Add missing span for 'other'

To stay consistent in the DOM structure it would make sense to have it
there as well

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 19500: (QA follow-up) Add spans to ease translation
Katrin Fischer [Sun, 12 Aug 2018 19:42:30 +0000 (19:42 +0000)]
Bug 19500: (QA follow-up) Add spans to ease translation

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 19500: Make module names on letters overview page translatable
Katrin Fischer [Fri, 10 Aug 2018 22:54:11 +0000 (22:54 +0000)]
Bug 19500: Make module names on letters overview page translatable

While the module pull down on adding and editing a letter is
written out and fully translatable, the overview page showed
the internal 'module code'.

Patch also renames the "Members" module into the "Patrons" module
to match Koha's terminology.

To test:
- Before applying the patch:
  - Add or edit a notice, look at the pull down for module
  - Go back to the overview page
  - Verify the module names don't match
- Apply the patch:
  - Check again, pull downs should now match
  - Verify that Members is now Patrons everywhere

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21229: (RM follow-up) regenerate staff css
Nick Clemens [Tue, 21 Aug 2018 11:59:17 +0000 (11:59 +0000)]
Bug 21229: (RM follow-up) regenerate staff css

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21229: Correct nesting and specificity for some button styles
Owen Leonard [Wed, 15 Aug 2018 13:14:02 +0000 (13:14 +0000)]
Bug 21229: Correct nesting and specificity for some button styles

This patch corrects some Bootstrap button-related CSS which was causing
some buttons to have the wrong color:

 - Circulation -> Check out: "Add a new message" link is black
 - Catalog -> Details page: "Print" button is blue

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

Clear your browser cache if necessary and view the above pages to
confirm the problem is fixed.

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21144: DBRev 18.06.00.017
Nick Clemens [Tue, 21 Aug 2018 11:49:55 +0000 (11:49 +0000)]
Bug 21144: DBRev 18.06.00.017

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21144: Add ROADTYPE to default authorised values categories
Katrin Fischer [Thu, 2 Aug 2018 00:19:42 +0000 (02:19 +0200)]
Bug 21144: Add ROADTYPE to default authorised values categories

The ROADTYPE category was missing from the default list of
authorised value categories available.

To test:
- Verify ROADTYPE is not listed as authorised value category
- Apply patch and run database update
- Verify ROADTYPE is now listed
- Add an entry, for example: AV = Avenue
- Add or edit a patron, verify a pull down with your entry
  shows on the form.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21142: Open uploaded files in utf-8 - batch mod/del
Jonathan Druart [Fri, 17 Aug 2018 15:07:55 +0000 (12:07 -0300)]
Bug 21142: Open uploaded files in utf-8 - batch mod/del

Batch item/record modification/deletion tools does not open uploaded
files in utf-8

Test plan:
Edit and delete records and items using a file which will contain:
valid and invalid barcodes with and without utf-8 chars (💕)

You should see the warning message:
 "The *** 39999000💕001679 does not exist in the database."

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20014: Preselect item budget based on id not code
Nick Clemens [Wed, 17 Jan 2018 19:50:31 +0000 (19:50 +0000)]
Bug 20014: Preselect item budget based on id not code

To test:
1 - Have the same fund code in two budgets
2 - Have budget code defined in MarcItemFieldsToOrder
3 - Stage a file with some order items as defined above
4 - Inspect the fuinds drop down in the item, notice two lines are
marked selected
5 - Apply patch
6 - Repeat
7 - Only one field should be selected, with a preference for active
budget

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20773: DBRev 18.06.00.016
Nick Clemens [Tue, 21 Aug 2018 11:25:53 +0000 (11:25 +0000)]
Bug 20773: DBRev 18.06.00.016

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 20773: (bug 20724 follow-up) Add a simple db revision
Marcel de Rooy [Wed, 16 May 2018 13:39:04 +0000 (15:39 +0200)]
Bug 20773: (bug 20724 follow-up) Add a simple db revision

We should correct bad data too.
This is a trivial, pragmatic approach. Instead of doing a complex
calculation with holidays etc. (as was done on 12063), we just add
MaxPickupDelay or 7 days to today probably resulting in a little bonus
time. Only for waiting holds. When the ReservesNeedReturns pref was not
Automatic, there should be no changes.

== Test plan ==
1. git checkout c585f1149770ec401f188e061211501897cec0bf~1
     This the commit before bug 20724's patches.
     We need that to be able to generate "corrupted data"
2. Set ReservesNeedReturns to "Automatically"
3. Place a hold on a specific item
4. The hold should have an *empty* expiration date
     record page → Hold → "Expiration" column
5. Apply this patch
6. Run updatedatabase.pl
7. Refresh the page
8. The hold should have an expiration date (not empty)
9. Celebrate! 🎉🎊🥳

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Victor Grousset <victor.grousset@biblibre.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Bug 20773: (followup) Remove MySQLism

Signed-off-by: Victor Grousset <victor.grousset@biblibre.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21238: Prevent TemplateToolkit.t to fail on slow servers
Jonathan Druart [Thu, 16 Aug 2018 15:29:43 +0000 (12:29 -0300)]
Bug 21238: Prevent TemplateToolkit.t to fail on slow servers

It failed 3x in the last 6 runs (on node 1), we should mock
DateTime->now to prevent it to fail again.

The error is:
koha_1       |         #   Failed test at
t/db_dependent/Letters/TemplateToolkit.t line 724.

When comparing <<today>> replacement:
koha_1       |         # 08/16/2018 14:25<br />
[...]
koha_1       |         # 08/16/2018 14:24<br />

Let's mock DateTime->now to prevent it to fail again.

Test plan:
0. Do not apply this patch
1. Add "sleep(60);" at line ~715, before "# Add a second checkout"
2. Run the tests
=> Fail!
3. Apply this patch
4. Run the tests again
=> Pass!

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21223: (RM follow-up) Generate css
Nick Clemens [Mon, 20 Aug 2018 14:49:53 +0000 (14:49 +0000)]
Bug 21223: (RM follow-up) Generate css

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21223: Fix some floating values
Jonathan Druart [Tue, 14 Aug 2018 20:26:26 +0000 (17:26 -0300)]
Bug 21223: Fix some floating values

See description of the bug for screenshots

I do not really know why we have these issues, but maybe we should
regenerate the .scss in order to catch the other problems?

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 18947: LDAP - do not assume anonymous bind if no user or password
Nick Clemens [Wed, 13 Dec 2017 13:27:36 +0000 (13:27 +0000)]
Bug 18947: LDAP - do not assume anonymous bind if no user or password

To test:
Ideally tested on a working ldap server with bind by auth and no
anonymous bind
1  - Define an LDAP config with bind by auth
2  - Don't define user/pass
3  - Define anonymous_bind = 0
4  - Attempt bind by auth
5  - Error is something like:
LDAP search failed to return object : XXXXXXXXX: LdapErr: XXXX-XXXXXX,
     comment: In order to perform this operation a successful bind must
     be completed on the connection., data 0, v2580 at
     /usr/share/koha/lib/C4/Auth_with_ldap.pm line 102.
6  - Define user/pass
7  - Now bind by auth should work
8  - remove user/pass
9  - Apply patch
10 - Attempt again
11 - Bind by auth shoudl succeed

prove -v t/db_dependent/Auth_with_ldap.t

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
6 years agoBug 21203: ILS-DI - Make GetRecords handle non-existent records
Jonathan Druart [Fri, 10 Aug 2018 15:17:45 +0000 (12:17 -0300)]
Bug 21203: ILS-DI - Make GetRecords handle non-existent records

Caused by
  commit cb336e633bf7e0cb25051a8ed8157af8486a58d7
  Bug 18255: Koha::Biblio - Replace GetBiblioItemByBiblioNumber with Koha::Biblio->biblioitem

Can't call method "biblioitem" on an undefined value at /home/vagrant/kohaclone/C4/ILSDI/Services.pm line 212

Test plan:
- Enable ilsdi
- hit /cgi-bin/koha/ilsdi.pl?service=GetRecords&id=X
With X an existing biblionumber and a non existing one

Both requests must succeed

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>