Bug 12234 - changelog updates from 3.14 series
Bug 10729: Add phrases configuration for ICU

Add a separate phrases-icu.xml for phrase indexes
The file is based on that distributed with zebra
with a couple of additions to reflect Koha usage

This patch adds a separate tokenizer variable
for phrase indexes so that default.idx is
correctly rewritten for sites using icu
indexing

Signed-off-by: Paola Rossi <paola.rossi@cineca.it>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
- Applied patch
- perl Makefile.PL --prev-install-log ../koha-dev/misc/koha-install-log
- make upgrade
- Restarted Zebra server
- Did a full reindex of bibliographic and authorities
- Checked various searches
- Links records to authorities
- Checked created links work correctly

I couldn't find a regression with this patch.
Passes all tests and QA script.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit 735381b371b128fed13b8b34c97746af21a17282)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 7372: Move road types from the roadtype table to the ROADTYPE AV

Currently road types are stored in a specific table in DB. Moreover, an
admin page is present in order to manage them.
This patch proposes to remove this table and this page in favour of a
new authorised value category 'ROADTYPE'.

This patch:
- adds a new AV category 'ROADTYPE' (created from the roadtype table
  content).
- remove the roadtype table.
- remove the .pl and .tt file admin/roadtype
- remove the 2 routines C4::Members::GetRoadTypes and
  C4::Members::GetRoadTypeDetails

Test plan:
1/ Execute the updatedatabase entry and verify existing roadtypes are
now stored in the AV 'ROADTYPE'.
2/ Verify you can add/update a streettype for patrons.
3/ Verify on following pages the streettype is displayed in patron
information (top left):
  circ/circulation.pl
  members/memberentry.pl
  members/moremember.pl
  members/routing-lists.pl

Signed-off-by: Sophie Meynieux <sophie.meynieux@biblibre.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit a691ebc3f1b9a4b9075fc3f1b798a145fbd01244)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>

Conflicts:
	installer/data/mysql/updatedatabase.pl
Bug 7372: DBRev 3.14.07.001

Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 7372: (follow-up) remove last traces of roadtype table and admin pages

This patch removes the DBIC schema class for the 'roadtype' table
and staff interface templates that are no longer reachable with
the removal of the road type administration page.  It also removes
the creation of the table during installation.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit 2be50eba0fe16a7243722f3edac56447c2b6fa75)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 11760: In notices, output road type description rather than code

Test plan :
  - Define a notice containing <<borrowers.streettype>>
  - Trigger an event that generate this notice

Without patch <<borrowers.streettype>> is replaced by ROADTYPE
authorised value code. With the patch it is resplaced by its
description

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
This works as described, passes tests and QA script.

Note: it seems it's not possible currently to use B_streettype from
the interface, but it might be worth adding it as a follow up for later
use.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit b5d85741a7d297c70783a649ac00f26c82351a6f)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 11821: disable catalog edit menu items and provide explanations when actions cannot be done

Biblio edit menu items which are disabled should trigger a tooltip
on hover and an alert on click with explanations. This patch implements
this for the relevent menu items.

To test, apply the patch for Bug 11829 if necessary. Find a record which
has no items attached. Test the following views:

- Normal
- MARC
- Labeled MARC
- ISBD
- Items

Test these Edit menu items:

- Edit items in a batch
- Delete items in a batch
- Delete all items

Hovering over these menu items should trigger an explanatory tooltip.
Clicking the menu items should trigger a similar alert.

Next, locate a title with items attached. On the same pages above, test
the Edit -> Delete record menu item. Hovering should trigger an
explanatory tooltip. Clicking it should trigger a similar alert.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script, works nicely.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit 5c1691a8013bd38d6bae8b00a8950e1417695176)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 11094 - Bootstrap theme: fix typo "loaction"

This patch fixes a typo on opac-user.tt

To test you must have existing holds on your account. Log into the OPAC
and view the holds tab on the "your summary" page (opac-user.pl).

Resize the browser window until the table switches from a regular table
layout to a vertical column. Only when the view is narrow enough does
the affected label appear:

Pick up location: [library name]

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit dcdd0888a49d679d44fe7f90d83416f746d79c91)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 11692: fix display of additional bib information in OPAC "most popular" pag

The template for the OPAC's "most popular" page includes several
variables which are not passed by the script, including
biblioitems.size. This patch adds the right columns to the query and
standardizes the output somewhat based on non-XSLT opac-detail.

To test, apply the patch and view the "most popular" page in both prog
and bootstrap. You should see correct publisher, copyright, pages, and
size information.

Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Tested in all three themes and works lovely

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Improves the bibliographic display on the 'Most popular' page
in the OPAC. Passes all tests and QA script.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit 5aabe570f4a8ffd117fa7270c9bb7321dfaff513)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 11310: update the XSLT for the Bootstrap theme

When the Bootstrap theme was started, the XSLT directory
was copied over from the prog theme.  However, it was not
kept up to date with respect to changes to prog's XSLT.

This patch rectifies the problem by copying over the
current state of prog/en/xslt to bootstrap/en/xslt.  As
a consequence, the following bugs or enhancements should
now be reflected in the Bootstrap theme:

* 6886
* 10905
* 10465
* 10564
* 10793
* 10218
* 6594
* 9820
* 10745
* 6553
* 10218
* 10284

To test:

[1] Apply the patch and ensure that OPACXSLTDetailsDisplay
    and OPACXSLTResultsDisplay are set to 'default' and that
    OPAC theme is set to 'bootstrap'.
[2] Ensure that OPAC results and bib details look OK.
[3] To be really thorough, run through the test plans for the
    other bugs referenced by this patch.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit cd02934c6baf9d237b17f8348c83bf7e248d5551)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 11772: Show warning on About page:System information if no active currency is defined

This patch displays a warning on the About page when no active currency
is defined.

Test plan:
1)
Make sure that no currency is defined as active
(Home › Administration › Currencies & Exchange rates › Currencies)
2)
Go to Home › About Koha > System information
Result: No warning issued.
3)
Apply patch and reload About page
Result: Warning issued.

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit 9e01b7c1d6c32dfd9ae0af4e708ca598303fbcf1)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 11772: (follow-up) make warning about no active currency a link to currency setup page

This patch standardizes the name of the currency and exchange rates
administration page (although I note that the breadcrumbs on that
page are inconsistent) and makes it a link.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit 4b4839e752d88c1ccba5f8c9a1296302747c0c6b)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 11753 - Replace jQuery qTip plugin with Bootstrap tooltip on patron search form

The qTip plugin is out of date and incompatible with recent versions of
jQuery. This patch replaces use of qTip on the patron search form with a
Bootstrap tooltip implementation.

To test, apply the patch and view /cgi-bin/koha/members/members-home.pl

- Expand the patron search form by clicking the [+]
- Change 'search fields' from 'Standard' to 'Date of birth'
- A tooltip should appear giving details about the date format required
- Change the 'search fields' to something else. The tooltip should not
  appear.

Revision: Removed inclusion of qTip plugin from global header include.
The other instance of qTip usage occurs on a page which loads the plugin
separately.

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit 432fce68eab71059ce797cbd6ee26a340009a208)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 11618: ensure jQuery timepicker is picked up by the i18n toolchain

We handle internationalization of the jQuery datepicker by adding
language configuration strings to calendar.inc which can be processed by
the translation script. This patch adds a similar configuration file for
the timepicker.

This patch also upgrades the timepicker plugin to the latest version,
minified, and places it outside the prog template directory for global
use. The path in templates has been updated accordingly.

CSS has been added to more completely hide the controls for seconds,
milliseconds, and microseconds.

To test, apply the patch and clear your cache so that the browser
loads the new version of the jQuery plugin. Confirm that date and time
selection still function correctly on the circulation page, the patron
detail page, and the offline circulation page (circ/offline.pl).

Test at least one datepicker instance which does not use the
timepicker.

Run translate update on a po file and confirm that the timepicker
strings are now present.

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Works as expected, no regression found.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit 76daec8bff3edeea65b6e5e59602e7c3aa2521f3)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 11709: revisions to Bootstrap OPAC lists interface

This patch makes some revisions to the lists template:

- Removed the old prog theme breadcrumbs from the List edit screen.
- Added New/Edit/Delete controls to the list view in cases where the
  list is empty.
- Corrected some breadcrumb logic.

To test, apply the patch and edit an existing list. You should see a
heading "Editing [list name]".

If necessary create a list with zero items on it. View the list. You
should see New/Edit/Delete links above the message about the list being
empty.

Patch behaves as expected.
Signed-off-by: Marc Véron <veron@veron.ch>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>

(cherry picked from commit 2d0347c787108657e047c00873e227c8bb043bfc)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 9677 - Style button on notices and slips page with Bootstrap

The toolbar button on the Notices & Slips page isn't styled with
Bootstrap as other toolbar buttons are. This patch corrects this.

The patch also removes some obsolete CSS.

To test go to Tools -> Notices and Slips. The toolbar button should look
correct and work correctly.

Patch works as expected.
Signed-off-by: Marc Véron <veron@veron.ch>

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
"yui-menu-button" is not contained in tt files.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit 36eac129f7fdab89ffd77ba5f3bd3add688deedc)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 11746 - Add edit item links to record details page

In order to edit a specific item right now, one must select the edit
pulldown, then choose edit items, the click the edit link for the
particular item the librarian wishes to edit. It would be much more
convenient to have an edit link for each specific item in the items
table on the record details page.

Test Plan:
1) Apply this patch
2) View the record details for a record with items
3) Click the edit link for a particular item
4) Note that you are taken immediately to the item editor
   for this particular item

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Havilah Lyon <havilah@aflibrary.org>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit d8b7e635e01175bcb4c90777ee3e080d4301db79)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 11746 [QA Followup] display edit item link only if user has permission to edit items

Signed-off-by: Havilah Lyon <havilah@aflibrary.org>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit c8ad1e6928ed424ae127bfac870d00fae7ea180a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 9532: add regression test

To test:

[1] Run prove -v t/db_dependent/Holds.t.  The last test
    should fail.
[2] Apply the main patch.
[3] Run step 1 again.  This time the tests should all pass.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit 2afadcc3583c466759f2c4da6970a3cc96a1ba36)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Bug 9532: fix reservability check when bib-level item types are in use

When itemtype is defined on biblio (item-level_itypes syspref), the
method C4::Reserves::CanItemBeReserved uses item->{itemtype}. But
ithe item comes from C4::Items::GetItem and it does not have an
'itemtype' key; in this method the item type value is always in
'itype' key.

This patch corrects it.

Test plan:

You should have itemtype on biblio and 'item-level_itypes' syspref
set to biblio.

This test plan is with ReservesControlBranch on ItemHomeLibrary.
- Choose a branch, a borrower category and an item type, for example
  'NYC', 'CHILD' and 'DVD'
- Set an issuing rule for 'NYC', CHILD' and 'DVD' with 'Holds allowed'
  set to 10
- Set an issuing rule for 'NYC', CHILD' and all item types with
  'Holds allowed' set to 0
- Choose an item of a biblio with itemtype 'DVD', that can be reserved,
  with 'NYC' as homebranch
- Choose a borrower with category 'CHILD'
- Try to request the item for the borrower
=> without the patch, you can
=> with the patch, you can't
You may check reserve is allowed with 'Holds allowed' > 0 on issuing
rule for 'DVD'.

Signed-off-by: Liz Rea <liz@catalyst.net.nz>
Great test plan - thanks!

Confirmed the bug, and the fix. Looks good to me.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit 7acd7f43a703c3aa853ea6e58153584c24ca6d09)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>