]> git.koha-community.org Git - koha.git/log
koha.git
5 years agoBug 22242: Javascript error in value builder cased by Select2
Fridolin Somers [Thu, 31 Jan 2019 08:12:13 +0000 (09:12 +0100)]
Bug 22242: Javascript error in value builder cased by Select2

Same as Bug 17780 but in value builders.

Select2 (Bug 13501) introduced divs and inputs that broke some
assumptions about the expected HTML structure. This patch checks if
input has name attribute, because some inputs in Select2 have not.

It brakes value builders marc21_linking_section.tt and
unimarc_field_4XX.tt.

Test plan :
1)  On a MARC21 database
2)  Define 774$0 as a regular subfield
3)  Define 774$4 with an authorised value category
4)  Define 774$t with value builder marc21_linking_section
5)  Create a new record
6)  Use value builder in 774$t
7)  Search for a record and click choose
8)  Without patch : a popup window does not close and show a blank
    screen
9)  With patch : popup windows get close and you see in field 774 $0 and
    $t field with values
10) Same tests with a UNIMARC database on field 461 with value builder
    unimarc_field_4XX.tt

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Tested successfully with MARC21

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 19816: Implement dateonly for rfc3339 format
Tomas Cohen Arazi [Thu, 24 Jan 2019 17:29:09 +0000 (14:29 -0300)]
Bug 19816: Implement dateonly for rfc3339 format

This patch implements the dateonly option for the rfc3339. This is
described in the OpenAPI 2.0 specification [1]. The required output
format is described on RFC 3339 [2], as 'full-date'.

[1] https://github.com/OAI/OpenAPI-Specification/blob/master/versions/2.0.md#dataTypeFormat
[2] https://tools.ietf.org/html/rfc3339#section-5.6

To test:
- Apply the regression tests patch
- Run:
 k$ prove t/DateUtils.t
=> FAIL: Tests fail because dateonly is not implemented
- Apply this patch
- Run:
 k$ prove t/DateUtils.t
=> SUCCESS: Tests pass!
- Sign off :-D

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 19816: Regression tests
Tomas Cohen Arazi [Thu, 24 Jan 2019 17:27:28 +0000 (14:27 -0300)]
Bug 19816: Regression tests

This patch adds tests for the rfc3339 behaviour when dateonly => 1.

To test:
- Run:
  $ kshell
 k$ prove t/DateUtils.t
=> SUCCESS: Tests pass
- Apply this patch
- Run:
 k$ prove t/DateUtils.t
=> FAIL: dateonly is not implemented

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22253: Check we actually need to update the password
Tomas Cohen Arazi [Thu, 31 Jan 2019 19:30:25 +0000 (16:30 -0300)]
Bug 22253: Check we actually need to update the password

This patch makes memberentry.pl check if password needs to be updated
before attempting to call set_password. Above this there's a check that
won't raise any errors if no password is passed, or the default string (****) is received.

So we could reach that line of code with no password, but the code
wouldn't check that.

To test:
- In master, edit any patron without changing the password
=> FAIL: It raises an exception
- Apply this patch
- Edit the patron withtout changing the password
=> SUCCESS: Edit successful
- Edit the patron, changing the password
- Try to login with the new password
=> SUCCESS: The password got changed correctly
- Sigh off :-D

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21610: Improve default values for dates
Jonathan Druart [Fri, 19 Oct 2018 11:22:20 +0000 (08:22 -0300)]
Bug 21610: Improve default values for dates

This patch fixes failures on t/db_dependent/Koha/Patrons/Import.t
and keep t/Auth_with_shibboleth.t and t/db_dependent/Koha/Object.t green

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21610: (follow-up) Default value for dates
Marcel de Rooy [Fri, 19 Oct 2018 10:14:20 +0000 (12:14 +0200)]
Bug 21610: (follow-up) Default value for dates

We have some dates with DEFAULT CURRENT_TIMESTAMP and some dates with
default and UPDATE clause.

Test plan:
Run Object.t again.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21610: (QA follow-up) Better use columns_info from DBIx
Marcel de Rooy [Fri, 19 Oct 2018 09:05:50 +0000 (11:05 +0200)]
Bug 21610: (QA follow-up) Better use columns_info from DBIx

We should better use the published method than a private hash key.
And shorter to go via _result than adding a new schema call.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21610: Fix integers and dates values at Koha::Object->store level
Jonathan Druart [Thu, 18 Oct 2018 21:55:44 +0000 (18:55 -0300)]
Bug 21610: Fix integers and dates values at Koha::Object->store level

With strict SQL modes, we are facing several issues when objects are stored.

The following errors can be raised by DBIx::Class when an object does not have
a valid (as defined at DB level) value:
- Incorrect integer value: '' for column COLUMN
- Incorrect decimal value: '' for column COLUMN
- Column 'COLUMN' cannot be null
- Field 'COLUMN' doesn't have a default value
- Incorrect date value: '' for column 'COLUMN'

We already handled some of them for Koha::Patron. As we do not want to provide such
changes for all Koha::* modules we are going to fix this at Koha::Object->store level
in order to provide a global fix.

This is related to bug 21599 (for item types) and bug 21596 (for patrons)

Test plan:
- Apply first patch, run the tests
=> Patch fail because of the previous error in Koha::ItemType->store, to make them pass
you can replace
  $self->notforloan(0) unless $self->notforloan;
with
  $self->notforloan(undef) unless $self->notforloan;
- Apply second patch, run the tests
=> They fail because of dates and/or integers values
- Apply third patch, run the tests
=> They now pass

Deep code review wanted!

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21610: Remove specific changes we made previously
Jonathan Druart [Thu, 18 Oct 2018 21:46:30 +0000 (18:46 -0300)]
Bug 21610: Remove specific changes we made previously

We handled integers and dates for Koha::Patron and Koha::ItemType, we
want now Koha::Object to deal with.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21610: Add tests
Jonathan Druart [Thu, 18 Oct 2018 21:38:18 +0000 (18:38 -0300)]
Bug 21610: Add tests

Adding few tests to Koha/Object.t in order to highlight what we are
trying to fix.

Note that Koha::ItemType->store was wrong for notforloan, the default
value should be null
    `notforloan` smallint(6) DEFAULT NULL,
but the previous fix (bug 21599) made it default to '0'

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22132: DBRev 18.12.00.012
Nick Clemens [Thu, 31 Jan 2019 13:36:04 +0000 (13:36 +0000)]
Bug 22132: DBRev 18.12.00.012

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22132: (QA follow-up) set_password now expects a hashref
Tomas Cohen Arazi [Wed, 30 Jan 2019 18:46:04 +0000 (15:46 -0300)]
Bug 22132: (QA follow-up) set_password now expects a hashref

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22132: (QA follow-up) Tests - use Mojo builtin for auth
Martin Renvoize [Thu, 24 Jan 2019 15:54:08 +0000 (15:54 +0000)]
Bug 22132: (QA follow-up) Tests - use Mojo builtin for auth

Mojolicious has built in handling for encoding/decoding of of basic auth
paramenters. We should use it to simplify our test here.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22132: Add Basic authentication to the API
Tomas Cohen Arazi [Tue, 15 Jan 2019 16:23:23 +0000 (13:23 -0300)]
Bug 22132: Add Basic authentication to the API

This patch implements Basic authentication for the API to aid testers
and developers with tools like Postman.

To test:
- Apply this patches
- Run:
  $ kshell
 k$ prove t/db_dependent/api/v1/auth_basic.t
=> SUCCESS: Tests pass!
- Open Postman or your favourite tool
- In Authorization, choose Basic auth.
- Enter the username and password of a known privileged user.
- Hit an endpoint with Postman, for example:
  ] GET http://kohadev-intra.myDNSname.org:8081/api/v1/patrons
=> SUCCESS: Basic authentication is great!
- Sign off :-D

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22132: Unit tests
Tomas Cohen Arazi [Tue, 15 Jan 2019 16:23:09 +0000 (13:23 -0300)]
Bug 22132: Unit tests

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22132: Add RESTBasicAuth syspref
Tomas Cohen Arazi [Tue, 15 Jan 2019 16:22:53 +0000 (13:22 -0300)]
Bug 22132: Add RESTBasicAuth syspref

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 17854: Compiled CSS
Nick Clemens [Wed, 30 Jan 2019 12:49:00 +0000 (12:49 +0000)]
Bug 17854: Compiled CSS

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 17854: Adds print/close icon in checkout
Christopher Brannon [Mon, 24 Sep 2018 19:51:36 +0000 (19:51 +0000)]
Bug 17854: Adds print/close icon in checkout

To Test:
1) Apply Patch.
2) Go to a patron checkout screen (circulation.pl).
3) Note there are no clear screen buttons in the upper right corner of
the checkout window.
4) Turn on the DisplayClearScreenButton preference.
5) Go back to patron checkout.  Note the clear screen button and the new
printer icon next to it.
6) Click the printer icon.  This will trigger a print slip function, and
close the patron screen.
7) Try to arrow back to the previous screen.  Should go to main menu and
not the patron screen, just like the orginal close button (X).

Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21871: (QA follow-up) C4::Biblio qw(GetMarcUrls)
Katrin Fischer [Sun, 27 Jan 2019 05:14:34 +0000 (05:14 +0000)]
Bug 21871: (QA follow-up) C4::Biblio qw(GetMarcUrls)

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
https://bugs.koha-community.org/show_bug.cgi?id=21817

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21871: (QA follow-up) Use Koha.Preference in template
Katrin Fischer [Sun, 27 Jan 2019 05:13:06 +0000 (05:13 +0000)]
Bug 21871: (QA follow-up) Use Koha.Preference in template

Use TT plugin to get value for OPACURLOpenInNewWindow.

Works without, but might be a little nicer.

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
https://bugs.koha-community.org/show_bug.cgi?id=21817

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21871: (follow-up) Remove link tracking
Owen Leonard [Tue, 15 Jan 2019 19:18:47 +0000 (19:18 +0000)]
Bug 21871: (follow-up) Remove link tracking

Links to tracklinks.pl were erroneously copied from detail.tt. This
patch removes them.

Signed-off-by: Charles Farmer <charles.farmer@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
https://bugs.koha-community.org/show_bug.cgi?id=21817

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21871: Show authority 856 links in the OPAC
Owen Leonard [Wed, 21 Nov 2018 13:54:45 +0000 (13:54 +0000)]
Bug 21871: Show authority 856 links in the OPAC

This patch modifies the authority detail view in the OPAC so that any
links found in 856 tags are displayed and active.

To test, apply the patch and locate or create an authority record which
contains one or more URLs in 856 tags.
 - View this record in the OPAC and confirm that the links appear.
 - Test records with and without link text.
 - Test records with and without public notes.

Signed-off-by: Devinim <kohadevinim@devinim.com.tr>
Signed-off-by: Charles Farmer <charles.farmer@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
https://bugs.koha-community.org/show_bug.cgi?id=21817

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22191: Add column configuration to libraries administration
Owen Leonard [Wed, 23 Jan 2019 15:23:15 +0000 (15:23 +0000)]
Bug 22191: Add column configuration to libraries administration

This patch adds column configuration to the table of libraries
in administration. No new defaults for the table are defined.

To test, apply the patch and clear your browser cache if necessary.

 - Go to Administration -> Libraries
   - Test that the "Column visibility" button works to show and hide
     columns. The "actions" column should be excluded.
   - Test that export options (Excel, CSV, etc) exclude the "actions"
     column.
 - Go to Administration -> Columns settings and edit the default
   configuration of the libraries table. Confirm that these
   changes are reflected in libraries administration.

Signed-off-by: Jose-Mario Monteiro-Santos <jose-mario.monteiro-santos@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22190: Add column configuration to patron category administration
Owen Leonard [Wed, 23 Jan 2019 14:48:31 +0000 (14:48 +0000)]
Bug 22190: Add column configuration to patron category administration

This patch adds column configuration to the table of patron categories
in administration. No new defaults for the table are defined.

To test, apply the patch and clear your browser cache if necessary.

 - Go to Administration -> Patron categoires.
   - Test that the "Column visibility" button works to show and hide
     columns. The "actions" column should be excluded.
   - Test that export options (Excel, CSV, etc) exclude the "actions"
     column.
 - Go to Administration -> Columns settings and edit the default
   configuration of the patron categories table. Confirm that these
   changes are reflected in patron category administration.

Signed-off-by: Jose-Mario Monteiro-Santos <jose-mario.monteiro-santos@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21449: Update two-column templates with Bootstrap grid: Circulation part 2
Owen Leonard [Thu, 24 Jan 2019 19:40:03 +0000 (19:40 +0000)]
Bug 21449: Update two-column templates with Bootstrap grid: Circulation part 2

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

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

To test, apply the patch and view the following pages, confirming that
they look correct at various browser widths. For each page, test with
the CircSidebar preference both on and off.

 - Catalog -> Search -> Details -> Items -> View item's checkout history
 - Circulation -> Overdues with fines
 - Circulation -> Transfer
 - Circulation -> Patron -> Batch checkout
 - Circulation -> Built-in offline circulation interface
   - Synchronize
   - Pending offline circulation actions
   - Check out
   - Check in

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22148: Changed where user is redirected by cancelling payment
helene hickey [Wed, 16 Jan 2019 22:36:20 +0000 (22:36 +0000)]
Bug 22148: Changed where user is redirected by cancelling payment

To test:
1) Create a manual invoice and save
2) Go to Make a payment tab
3) Click 'Pay amount', then cancel
4) Notice you are redirected to the Transactions tab, rather than back to
Make a payment
5) Also try this with Pay selected and write off selected result when
cancelling should be the same
6) Apply patch and try steps 2-6 again
7) Verify that you are now redirected to the 'make a payment tab'

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Jose-Mario Monteiro-Santos <jose-mario.monteiro-santos@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 12283: Disable autocomplete for patron search inputs
Olli-Antti Kivilahti [Wed, 17 Oct 2018 19:03:00 +0000 (19:03 +0000)]
Bug 12283: Disable autocomplete for patron search inputs

In a production system, you don't usually search for the same
patron over and over, so there's no sense for the browser
to save a list of searched patrons in the patron quick
search. Therefore, should set autocomplete=off for that
input field.

Signed-off-by: Jose-Mario Monteiro-Santos <jose-mario.monteiro-santos@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22144: (QA follow-up) Prepare the ground for other formats
Tomas Cohen Arazi [Wed, 23 Jan 2019 16:25:33 +0000 (13:25 -0300)]
Bug 22144: (QA follow-up) Prepare the ground for other formats

This patch refactors the original implementation so it is ready for
supporting other formats. It also adds some error handling.

To test:
- Apply this patch
- Run:
  $ kshell
 k$ prove t/db_dependent/Koha/Biblio/Metadata.t
=> SUCCESS: Tests pass!
- Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22144: Add method metadata() to Koha::Biblio
Kyle M Hall [Wed, 16 Jan 2019 19:25:07 +0000 (14:25 -0500)]
Bug 22144: Add method metadata() to Koha::Biblio

It would be very convenient to be able to retrieve a bib's attached metadata objects directly from the biblio object. This would be very useful for Template Toolkit syntax in slips and notices where a library would like to use arbitrary metadata fields that aren't stored in the database.

Test Plan:
1) Apply this patch
2) prove t/db_dependent/Koha/Biblio.t

Signed-off-by: Te Rahui Tunua <terahuitunua@catalyst.net.nz>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22194: Add Koha::Exceptions::Metadata
Tomas Cohen Arazi [Wed, 23 Jan 2019 16:10:14 +0000 (13:10 -0300)]
Bug 22194: Add Koha::Exceptions::Metadata

This trivial patch adds a basic Koha::Exceptions::Metadata exception and
Koha::Exceptions::Metadata::Invalid for using when the data cannot be
decoded (maybe because of incompatibility between format, schema, or
just bad data).

To test:
- Apply this patch
- Run:
  $ kshell
 k$ prove t/Koha/Exceptions.t
=> SUCCESS: Tests pass!
- Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21918: Update buttons on fines to match newer buttons
Owen Leonard [Thu, 29 Nov 2018 19:56:43 +0000 (19:56 +0000)]
Bug 21918: Update buttons on fines to match newer buttons

This patch makes a number of changes to the "Pay fines" template, the
goal of which is to make the interface look better in general. Changes
include:

 - Styling the "Pay" and "Write off" buttons as Bootstrap buttons.
 - Adding DataTables sorting, searching, and filtering.
 - Adding a column showing the fine date.
 - Hide the "Add note" input, add a link to show it.
 - Add some missing "preventDefault" methods from events.
 - Add "Writeoff selected" to the buttons which are disabled when there
   is no checkbox selection.
 - The <tfoot> tag is now expected by the HTML validator to be after
   <tbody>, so this section has been moved to suppress validator errors.

To test, apply the patch and locate a patron who has multiple
outstanding fines.

 - Go to Fines -> Pay fines
 - Confirm that the table of fines is shown as a DataTable, with sorting
   on columns which have data.
 - Test columns settings in Administration -> Columns settings.
 - Confirm that fine dates are shown, and that sorting by this column
   works correctly.
 - Click an "Add note" link to show a note input field. Focus should be
   in the newly-displayed input.
   - Confirm that notes are still saved correctly when paying or writing
     off single or multiple fines.
   - Confirm that when the "add note" input is hidden, its contents are
     erased.
 - Uncheck all checkboxes by clicking the "Clear all" link at the top.
   The "Pay selected" and "Write off selected" buttons should become
   disabled.
   - Checking any checkbox should re-enable those buttons.
 - Test that the relocated "Apply" button (for outstanding credits)
   still works as expected.

Signed-off-by: Jose-Mario Monteiro-Santos <jose-mario.monteiro-santos@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22155: Schema updates
Nick Clemens [Wed, 30 Jan 2019 11:36:11 +0000 (11:36 +0000)]
Bug 22155: Schema updates

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22155: DBRev 18.12.00.011
Nick Clemens [Wed, 30 Jan 2019 11:35:59 +0000 (11:35 +0000)]
Bug 22155: DBRev 18.12.00.011

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22155: Adapt uses of biblio_metadata.marcflavour to schema
Tomas Cohen Arazi [Fri, 18 Jan 2019 02:25:38 +0000 (23:25 -0300)]
Bug 22155: Adapt uses of biblio_metadata.marcflavour to schema

This patch makes the code using Koha::Biblio::Metadata->marcflavour use
->schema instead for all interactions.

To test:
- Update the DB structure:
  $ updatedatabase
- Update the schema files:
  $ dbic
- Notice all the places in which biblio_metadata is used
  $ cd kohaclone
  $ git grep biblio_metadata
=> SUCCESS: They all use `schema` instead of marcflavour
- Notice all the places that use Koha::Biblio::Metadata:
  $ git grep Koha::Biblio::Metadata
=> SUCCESS: They all use the schema attribute when they used to use
marcflavour
- Run all the modified tests and scripts
=> SUCCESS: We are all good
- Sign off :-D

Note: while this seems like a minor change, the places in which plain
SQL is used really require understanding the queries and how they are
used, because some query results might be passed to some other method
that in turn uses the marcflavour attribute. I of course took that into
account but errare humanum est :-D

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22155: DB update
Tomas Cohen Arazi [Fri, 18 Jan 2019 01:55:11 +0000 (22:55 -0300)]
Bug 22155: DB update

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20634: Changing the identical label "Library:" to "Location" in Inventory Home.
Olivia Lu [Tue, 15 Jan 2019 21:24:25 +0000 (21:24 +0000)]
Bug 20634: Changing the identical label "Library:" to "Location" in Inventory Home.

To find fix:

1. Go to tools
2. Go to Inventory
3. Verify that under Item location filters the label should be "Location"

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21971: TestBuilder::build_sample_item
Jonathan Druart [Thu, 6 Dec 2018 22:51:39 +0000 (19:51 -0300)]
Bug 21971: TestBuilder::build_sample_item

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21798: (RM follow-up) Fix a few added tests
Nick Clemens [Mon, 28 Jan 2019 20:14:27 +0000 (20:14 +0000)]
Bug 21798: (RM follow-up) Fix a few added tests

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21798: (QA follow-up) Fix Biblios.t
Marcel de Rooy [Thu, 13 Dec 2018 12:51:20 +0000 (13:51 +0100)]
Bug 21798: (QA follow-up) Fix Biblios.t

Global symbol "$bibnum" requires explicit package name

Test plan:
Run test

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21798: replace gimme_a_biblio with build_sample_biblio
Jonathan Druart [Wed, 12 Dec 2018 16:17:02 +0000 (13:17 -0300)]
Bug 21798: replace gimme_a_biblio with build_sample_biblio

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21798: Replace 2 more occurrences
Jonathan Druart [Thu, 6 Dec 2018 21:00:09 +0000 (18:00 -0300)]
Bug 21798: Replace 2 more occurrences

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21798: Fix another test
Jonathan Druart [Tue, 13 Nov 2018 14:24:14 +0000 (11:24 -0300)]
Bug 21798: Fix another test

We should correctly generate the data we need, here we expect 2 records
with title starting with "Silence in the".

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21798: Fix a wrong test
Jonathan Druart [Tue, 13 Nov 2018 14:22:15 +0000 (11:22 -0300)]
Bug 21798: Fix a wrong test

Now biblioitem.itemtype has a value, GetItem should fill itype with this
value if item-level_itypes it not set

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21798: Unify the creation of bibliographic record in tests
Jonathan Druart [Tue, 13 Nov 2018 14:20:45 +0000 (11:20 -0300)]
Bug 21798: Unify the creation of bibliographic record in tests

Using the newly created subroutine

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21798: We need t::lib::TestBuilder::gimme_a_biblio
Tomas Cohen Arazi [Thu, 8 Nov 2018 20:06:54 +0000 (17:06 -0300)]
Bug 21798: We need t::lib::TestBuilder::gimme_a_biblio

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21495: Regression in hold override functionality
Kyle M Hall [Thu, 15 Nov 2018 13:35:33 +0000 (08:35 -0500)]
Bug 21495: Regression in hold override functionality

The changes caused by the patches for bug 11512 have broken existing
workflows for many libraries and are widely considered to be a bad move.
We should revert this behavior.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Rhonda Kuiper <kuiper@roundrocktexas.gov>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21478: (QA follow-up) Make sure tests don't fail randomly
Tomas Cohen Arazi [Mon, 28 Jan 2019 15:23:35 +0000 (12:23 -0300)]
Bug 21478: (QA follow-up) Make sure tests don't fail randomly

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22168: Improve styling of new chart settings for reports
Owen Leonard [Fri, 18 Jan 2019 17:10:40 +0000 (17:10 +0000)]
Bug 22168: Improve styling of new chart settings for reports

This patch updates a number of aspects of the reports chart creation
interface: Chart creation form is now shown in a modal window, and a
separate link has been added to show or hide the chart itself.

Also changed: Minor markup and JavaScript cleanup.

To test, apply the patch and go to Reports -> Saved reports.

- Run a report which returns more than one column.
- On the report results page, click the "Create chart" button. The chart
  settings form should appear in a modal window.
- Confirm that the form controls work correctly: Each label should give
  focus to the correct input. Changing the chart type should show or
  hide the appropriate form fields.
- Click the "Draw" button. The modal should disappear and the chart
  should be shown.
- Above the chart should be a "Hide chart" link which works to hide (and
  then show) the chart.

Signed-off-by: Pierre-Marc Thibault <pierre-marc.thibault@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22061: DBRev 18.12.00.010
Nick Clemens [Mon, 28 Jan 2019 16:04:32 +0000 (16:04 +0000)]
Bug 22061: DBRev 18.12.00.010

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22061: (follow-up) set_password expects a hashref
Tomas Cohen Arazi [Mon, 28 Jan 2019 15:45:03 +0000 (12:45 -0300)]
Bug 22061: (follow-up) set_password expects a hashref

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22061: (QA follow-up) Rename password_2 => password_repeated
Tomas Cohen Arazi [Fri, 18 Jan 2019 16:34:55 +0000 (13:34 -0300)]
Bug 22061: (QA follow-up) Rename password_2 => password_repeated

As voted when the RFC was discussed, the attribute gets renamed. The
tests are adjusted accordingly.

To test:
- Run:
  $ kshell
 k$ prove t/db_dependent/api/v1/patrons_password.t
=> SUCCESS: Tests pass!

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22061: Public route to change password
Tomas Cohen Arazi [Mon, 7 Jan 2019 11:25:08 +0000 (08:25 -0300)]
Bug 22061: Public route to change password

This patch implements a route to change patron's password for
unprivileged users. It's intended for using in the OPAC (or however
consumers find it useful).

It is a starting point for the public API, and the bug also implements
the on/off switch some community members asked for.

To test:
- Apply this patches
- Run:
  $ kshell
 k$ prove t/db_dependent/api/v1/patrons_password.t \
          t/db_dependent/api/v1/auth.t
=> SUCCESS: Tests pass! i.e.
        - RESTPublicAPI is honoured
        - The /public/patrons/:patron_id/password endpoint works as
        expected
- Use your favourite API testing tool to try the endpoint.
- Sign off :-D

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22061: OpenAPI spec
Tomas Cohen Arazi [Mon, 7 Jan 2019 11:24:45 +0000 (08:24 -0300)]
Bug 22061: OpenAPI spec

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22061: Unit tests
Tomas Cohen Arazi [Mon, 7 Jan 2019 11:24:28 +0000 (08:24 -0300)]
Bug 22061: Unit tests

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22061: Add a /public namespace that can be switched on/off
Tomas Cohen Arazi [Wed, 2 Jan 2019 18:05:47 +0000 (15:05 -0300)]
Bug 22061: Add a /public namespace that can be switched on/off

This patch adds a check in Koha::REST::V1::Auth::under to catch all
routes that begin with 'public' (inside /api/v1). If they match, and the
RESTPublicAPI syspref is off, then an exception is thrown, rendering a
403 error to the consumer.

Otherwise the routes are processed as usual. This is THE on/off switch
for the public REST API. The target use case: people not wanting an OPAC
or public interaction with the API besides privileged users.

In order to test, the rest of the patches are needed because the only
way to test a route is having it in the spec.

To test:
- Apply the patches
- Run:
  $ kshell
 k$ prove t/db_dependent/api/v1/auth.t
=> SUCCESS: tests pass!
- Sign off :-D

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22061: Add RESTPublicAPI syspref
Tomas Cohen Arazi [Wed, 2 Jan 2019 18:05:10 +0000 (15:05 -0300)]
Bug 22061: Add RESTPublicAPI syspref

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 17006: (follow-up) set_password expects a hashref
Tomas Cohen Arazi [Mon, 28 Jan 2019 15:37:54 +0000 (12:37 -0300)]
Bug 17006: (follow-up) set_password expects a hashref

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 17006: Add /patrons/{patron_id}/password
Tomas Cohen Arazi [Thu, 16 Aug 2018 10:02:17 +0000 (07:02 -0300)]
Bug 17006: Add /patrons/{patron_id}/password

This patch introduces an endpoint for changing a patron's password. It
targets privileged user with the right permissions, changing some
patron's password.

To test:

- Apply this patchset
- Run:
  $ kshell
 k$ prove t/db_dependent/api/v1/patrons_password.t
=> SUCCESS: tests pass!
- Play with the different use cases highlighted by the tests, on your
favourite REST testing tool (Postman, RESTer on FF, etc).

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 17006: OpenAPI spec
Tomas Cohen Arazi [Thu, 16 Aug 2018 10:01:21 +0000 (07:01 -0300)]
Bug 17006: OpenAPI spec

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 17006: Unit tests
Tomas Cohen Arazi [Thu, 16 Aug 2018 10:00:38 +0000 (07:00 -0300)]
Bug 17006: Unit tests

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 19770: Add cardnumber and CSS classed to patron info on waiting holds
Katrin Fischer [Mon, 14 Jan 2019 06:21:39 +0000 (06:21 +0000)]
Bug 19770: Add cardnumber and CSS classed to patron info on waiting holds

Patch makes use fo patron-string.inc for displaying the patron information
on the waiting holds report.

It also adds spans with classes for phone and email.

To Test:
1 - View the holds awaiting pickup report
2 - Note there is no cardnumber for the patron
3 - Apply patch
4 - Cardnumber shows now
5 - Verify the same works for 'Holds over' tab

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>
5 years agoBug 18661: Made "Replace only included patron attributes" default on patron import
Te Rauhina Jackson [Tue, 16 Jan 2018 20:49:20 +0000 (20:49 +0000)]
Bug 18661: Made "Replace only included patron attributes" default on patron import

Test Plan:
1) Go to the import patrons page and notice that "Replace all patron attributes" is selected by default in the Patron Attributes section.
2) Apply this patch
3) Go back to the import patrons page and notice that "Replace only included patron attributes" is delected by default.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 19994: Used Modern::Perl in Authorities perl scripts
Jasmine Amohia [Thu, 17 Jan 2019 00:51:11 +0000 (00:51 +0000)]
Bug 19994: Used Modern::Perl in Authorities perl scripts

Test plan:
1. Review code of the following files and confirm that 'use Modern::Perl;' is used in place of
'use strict; use warnings;'

auth_finder.pl
authorities-home.pl
authorities.pl
blinddetail-biblio-search.pl
detail-biblio-search.pl
detail.pl
export.pl
merge.pl
merge_ajax.pl

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 10562: Improve Leader06 Type Labels in MARC21slim2OPACResults.xsl
Owen Leonard [Fri, 29 Jun 2018 16:27:28 +0000 (16:27 +0000)]
Bug 10562: Improve Leader06 Type Labels in MARC21slim2OPACResults.xsl

This patch takes the suggestions in Bug 10562 and implements those
changes in MARC21slim2OPACResults.xsl. This patch also makes the
following changes:

 - De-duplicate famfamfam icons: Remove the /silk subdirectory and move
   non-duplicates to famfamfam/; Correct paths to these images in
   templates and CSS
 - Improve the granularity of some material type icon choices: Show
   "Film," "Picture," or "Object" instead of "Visual material."
 - Remove unnecessary title attributes from material type images
 - Implement the kind of changes made in Bug 18235, "Add classes to
   material type icons on result lists and detail pages"

Signed-off-by: Charles Farmer <charles.farmer@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 15110: Improve decreaseHighHolds system preference description
helene hickey [Thu, 17 Jan 2019 02:28:57 +0000 (02:28 +0000)]
Bug 15110: Improve decreaseHighHolds system preference description

To test:
1) Apply patch
2) Go to Koha admin
3) Search in system prefernces for 'high demand'
4) Verify that the system prefernce 'decreaseLoanHighHolds' is in the
results of the search

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22124: Update cataloguing plugin system to not generate type parameter in script tag
Josef Moravec [Mon, 14 Jan 2019 09:16:53 +0000 (09:16 +0000)]
Bug 22124: Update cataloguing plugin system to not generate type parameter in script tag

Test plan:
1) Apply the patch
2) Have defined some cataloguing plugin which generates javascript - for
example dateaccessioned.pl
3) Go to cataloguing/adding item and show source
-> there should be no type parameter in script tag in code added by
cataloguing pulgin
4) prove t/db_dependent/FrameworkPlugin.t

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>
5 years agoBug 22136: Added 'ExtendedPatronAttributes' notes to 'Import Patrons' notes.
Ethan Amohia [Wed, 16 Jan 2019 04:01:44 +0000 (04:01 +0000)]
Bug 22136: Added 'ExtendedPatronAttributes' notes to 'Import Patrons' notes.

Fixed ExtendedPatronAttributes typo.

Signed-off-by: Pierre-Marc Thibault <pierre-marc.thibault@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22134: (follow-up) Simplify check for expired patron
Owen Leonard [Fri, 18 Jan 2019 13:05:55 +0000 (13:05 +0000)]
Bug 22134: (follow-up) Simplify check for expired patron

This patch move the check for "is_expired" to the template and removes
unnecessary code from the script.

The page now correctly handles messages for patrons who are about to
expire, as defined in the NotifyBorrowerDeparture preference.

To test, apply the patch and locate a patron record which is expired.

 - On the patron detail page (members/moremember.pl) you should see a
   message at the top of the page.
 - In the body of the page, next to the expiration date information, you
   should see similar message and links.

Select a patron who will expire within the period defined in
NotifyBorrowerDeparture.

 - On the patron detail page you should see a message at the top of the page.
 - In the body of the page, next to the expiration date information, you
   should see similar message and links.

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22134: Add account expiration information to patron details
Owen Leonard [Tue, 15 Jan 2019 14:53:07 +0000 (14:53 +0000)]
Bug 22134: Add account expiration information to patron details

This patch modifies the patron detail template in the staff client so
that when a patron's registration is expired a message shows at the top
of the page along with the same "Renew" and "Edit" links which appear on
the checkout page. Links are also shown next the the expiration date in
the body of the page.

This patch also corrects the capitalization of the "Edit Details" link
on circulation.tt.

To test, apply the patch and locate a patron record which is expired.

 - On the patron detail page (members/moremember.pl) you should see a
   message at the top of the page.
 - In the body of the page, next to the expiration date information, you
   should see similar message and links.
 - On the patron's checkout page the "Edit details" link in the
   expiration message should have correct capitalization.

Signed-off-by: Devinim <kohadevinim@devinim.com.tr>
Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 19818: Add id into tag html from moremember.tt
helene hickey [Thu, 17 Jan 2019 01:09:04 +0000 (01:09 +0000)]
Bug 19818: Add id into tag html from moremember.tt

1) Go to the patron details for a patron
2) On the right of the screen, right click one of the labels below
   'Library use' etc, and Inspect Element
3) View <li> tags which should now each have a unique <id> tag for each

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>
5 years agoBug 22102: Markup fixes for OPAC article request page
Owen Leonard [Fri, 11 Jan 2019 14:52:28 +0000 (14:52 +0000)]
Bug 22102: Markup fixes for OPAC article request page

This patch makes a few improvements to the OPAC article request page:

- Improve the breadcrumbs menu by adding a link to the title
- Add a header with the record's title
- Wrap the "no article requests" message in the correct dialog div
- Remove obsolete CDATA marker

To test, apply the patch and log in to the OPAC

 - Peform a search which will return multiple results
 - Click "Request article" on a title for which article requests can be
   submitted.
   - Confirm that the breadcrumbs menu looks and works correctly.
 - Click "Request article" on a title for which article requsts are not
   allowed.
   - Confirm that the message is correctly styled.

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21945: Clean up stock rotation template
Owen Leonard [Tue, 4 Dec 2018 16:52:44 +0000 (16:52 +0000)]
Bug 21945: Clean up stock rotation template

This patch makes some minor markup upgrades to the stock rotation
template: Replace some YUI markup with Bootstrap; Add some missing <tr>
tags; Remove invalid "type" attribute from <script> tag.

To test, apply the patch and go to Tools -> Stock rotation. Confirm that
the page looks correct and adjusts well at various browser widths. Test
with various views: New rota, edit rota, manage stages, manage items.

Signed-off-by: Jose-Mario Monteiro-Santos <jose-mario.monteiro-santos@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22104: Clean up patron API keys template
Owen Leonard [Fri, 11 Jan 2019 17:06:45 +0000 (17:06 +0000)]
Bug 22104: Clean up patron API keys template

This patch makes two corrections to the patron API key template: Convert
to Bootstrap grid and correct class on "new key" button.

To test, apply the patch and enable the RESTOAuth2ClientCredentials
preference.

 - Open a patron record in the staff client and choose More -> Manage
   API keys.
 - On the API keys page, confirm that the page adjusts well at various
   page widths.
 - Confirm that the size of the "Generate new client id/key pair" button
   matches the buttons in the toolbar.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22026: Removed 'use Modern::Perl;' from Koha::REST::classes
Jasmine Amohia [Thu, 17 Jan 2019 02:55:46 +0000 (02:55 +0000)]
Bug 22026: Removed 'use Modern::Perl;' from Koha::REST::classes

Test plan:
1) Check all Koha/REST files and confirm that 'use Modern::Perl;' has
been removed.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21926: Enhance OAI-PMH:archiveID system preference description
Josef Moravec [Fri, 30 Nov 2018 10:26:54 +0000 (10:26 +0000)]
Bug 21926: Enhance OAI-PMH:archiveID system preference description

Test plan:
1) Apply the patch
2) Go to Administration -> System preferences -> Web services, section
OAI-PMH
3) See description on OAI-PMH:archiveID and confirm it does make sense
and have the link to implementation guidelines

Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21290: Updating documentation for ModItem
helene hickey [Wed, 16 Jan 2019 23:20:38 +0000 (23:20 +0000)]
Bug 21290: Updating documentation for ModItem

To test:
Review the patch and check it is now updated correctly

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21964: Update two-column templates with Bootstrap grid: Patrons part 2
Owen Leonard [Wed, 2 May 2018 17:56:43 +0000 (17:56 +0000)]
Bug 21964: Update two-column templates with Bootstrap grid: Patrons part 2

This patch modifies several patron 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:

 - Patrons home page
   - New patron
 - Patron -> Fines -> Create manual invoice
 - Patron -> Set permissions
 - Patron -> Change password
 - Patron -> Edit

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>
5 years agoBug 20679: Removed 'rows per page' from report print layout
Jasmine Amohia [Wed, 16 Jan 2019 20:53:40 +0000 (20:53 +0000)]
Bug 20679: Removed 'rows per page' from report print layout

Test plan:
1. Create a report or view an existing report
2. Notice that 'Rows per page:' is visible
3. Print report (Ctrl+P)
4. Confirm that on printed report, 'Rows per page:' is no longer visible

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>
5 years agoBug 22149: Fixed grammar in the manage_circ_rules_from_any_libraries description
Jasmine Amohia [Wed, 16 Jan 2019 23:10:35 +0000 (23:10 +0000)]
Bug 22149: Fixed grammar in the manage_circ_rules_from_any_libraries description

Test plan:
1. Review patch and confirm that the sentence makes sense

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21930: Reworded message on permissions.inc
Jack Kelliher [Tue, 15 Jan 2019 03:24:17 +0000 (03:24 +0000)]
Bug 21930: Reworded message on permissions.inc

1. Go to patrons account, more, Set Permissions.
2. Dropdown the Parameters section.
3. Text should display "If not set the logged in user could only edit
circulation rules for its the own library (please note that
        manage_circ_rules is still required)"
4. Apply patch and reload page
5. Text should now display "Edit circulation rules from any library. If
not set the logged in user could only edit circulation rules for their
own library (please note that manage_circ_rules is still required)"

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22029: Google plus has been removed from the social links.
helene hickey [Tue, 15 Jan 2019 21:08:47 +0000 (21:08 +0000)]
Bug 22029: Google plus has been removed from the social links.

For testing:
1) Make sure SocailNetworks is enabled
2) Find a book and verify that in the social links, there is a Google
Plus option
3) apply patch and verify that the Google Plus option is no longer there

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20569: Improved description of CheckPrevCheckout system preference
Jasmine Amohia [Tue, 15 Jan 2019 21:34:32 +0000 (21:34 +0000)]
Bug 20569: Improved description of CheckPrevCheckout system preference

The CheckPrevCheckout preference can be overriden by a setting in the
patron categories, I've edited the options to reflect this.

Test plan:
1. Check the CheckPrevCheckout system preferences and confirm that the
options are clear

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22138: updated tab names on members/paycollect.pl
Jasmine Amohia [Wed, 16 Jan 2019 00:54:52 +0000 (00:54 +0000)]
Bug 22138: updated tab names on members/paycollect.pl

Test plan:
1. Give patron outstanding fees
2. Search patron and select 'Make payment'
3. Select either 'Pay' or 'Write off'
4. Confirm that first tab title remains as 'Transactions'
5. Confirm that current tab title remains as 'Make a payment'

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21573: Compiled CSS
Nick Clemens [Mon, 28 Jan 2019 12:51:02 +0000 (12:51 +0000)]
Bug 21573: Compiled CSS

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21573: Move lists barcode and biblionumber entry form to modal
Owen Leonard [Mon, 15 Oct 2018 15:10:28 +0000 (15:10 +0000)]
Bug 21573: Move lists barcode and biblionumber entry form to modal

This patch modifies the staff client lists page so that the
barcode/biblionumber entry form from the left hand sidebar into a modal
window, triggered by a button in the toolbar.

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

 - View the contents of a list in the staff client, logged in as a user
   who has permission to add items.
 - Click the "Add items" button. A modal window should appear with the
   barcode/biblionumber entry form.
 - Submit barcodes and/or biblionumbers and confirm that the correct
   titles are added to the list.
 - Log in again as a user who does not have permission to add to the
   list. Confirm that the button isn't present.

Signed-off-by: Mackey Johnstone <mackeyfj@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 17353: (follow-up) Adjust config variable for moremember.tt too
Nick Clemens [Thu, 10 Jan 2019 20:40:02 +0000 (20:40 +0000)]
Bug 17353: (follow-up) Adjust config variable for moremember.tt too

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 17353: Add phone number column to checkout search
Nick Clemens [Mon, 26 Sep 2016 17:43:20 +0000 (17:43 +0000)]
Bug 17353: Add phone number column to checkout search

This patch adds borrowers.phone as 'Primary phone' in the checkout
search results. It also ads the table to columns configuration

To test:
1 - Perform a checkout search
2 - Note phone is not displayed
3 - Apply patch
4 - Note phone does not display
5 - Visit columns configuration
6 - Unhide the 'phone' column
7 - Note phone displays
8 - Ensure page functions as before patch

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>
5 years agoBug 20729: Compiled CSS
Nick Clemens [Mon, 28 Jan 2019 12:36:22 +0000 (12:36 +0000)]
Bug 20729: Compiled CSS

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20729: Update style of datepickers
Owen Leonard [Wed, 10 Oct 2018 18:16:10 +0000 (18:16 +0000)]
Bug 20729: Update style of datepickers

This patch updates the styling of form fields which are configured to
use the jQueryUI datepicker widget. Some CSS has been added, and the
default datepicker configuration has been changed.

To test, apply the patch, rebuild the staff client CSS file, and clear
your cache if necessary. Test pages which include a datepicker to
confirm that they look correct and work correctly. Some examples:

 - Circulation -> Check out -> Specify due date
 - Patrons -> Add patron -> Date of birth, registration date, expiry
   date fields
 - Serials -> Search subscriptions -> Search results page sidebar
 - Tools -> News -> Add news item

And confirm that this change hasn't adversely affected the calendar
tool:

 - Tools -> Calendar

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Pierre-Marc Thibault <pierre-marc.thibault@inLibro.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21399: Sort patron fines in OPAC by date descending as a default
Owen Leonard [Tue, 27 Nov 2018 19:25:09 +0000 (19:25 +0000)]
Bug 21399: Sort patron fines in OPAC by date descending as a default

This patch modifies the DataTables configuration of the logged-in user's
"Fines and charges" table in the OPAC so that the table is sorted by
date, descending.

To test, apply the patch and log in to the OPAC as a user with multiple
fines. Go to the "your fines" page and confirm that the table is sorted
by default on the first column with the newest entries first.

Signed-off-by: Nazlı Çetin <nazli@devinim.com.tr>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21913: Clean up payment details page
Owen Leonard [Wed, 24 Oct 2018 16:09:12 +0000 (16:09 +0000)]
Bug 21913: Clean up payment details page

This patch makes various corrections and improvements to the payment
details page:

 - Grid converted to Bootstrap
 - Correct title tag
 - Add patron toolbar
 - Adding missing patron-related JavaScript
 - Improve some language

To test, apply the patch and locate a patron who has one or more
payments on their account.

 - Open Fines -> Account -> Details of a transaction
 - Confirm that the page looks correct and adjusts well at various
   browser widths.
 - Confirm that patron toolbar items work correctly

Signed-off-by: Jose-Mario <jose-mario.monteiro-santos@inLibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 22083: Typo in circulation_batch_checkouts.tt
Caroline Cyr La Rose [Tue, 8 Jan 2019 14:28:35 +0000 (09:28 -0500)]
Bug 22083: Typo in circulation_batch_checkouts.tt

There is a typo in circulation_batch_checkouts.tt that makes Koha skip
a warning if the user cannot borrow due to circulation rules.

This patch corrects this typo.

To test:

1. In Administration > Global system preferences, 'Allow'
   BatchCheckouts and enter patron categories in
   BatchCheckoutsValidCategories
2. Go to Administration > Circulation and fines rules
3. Enter a rule where a certain category of patrons (that is in
   BatchCheckoutsValidCategories) cannot take out a particular item type
4. Search the catalog for an item of that item type
5. Copy the barcode
6. Go into patrons and find a patron of that category
7. Click on the Batch checkout tab
8. Paste the barcode in the box and click Check out
9. It should say 'Too many checked out'
10. Apply the patch
11. Try the check out again, it should show both warnings ('Too many
    checked out' and 'This patron can't check out this item per library
    circulation policy')

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>
5 years agoBug 20640: (follow-up) Always send a backend on migrate
Martin Renvoize [Fri, 11 Jan 2019 16:12:24 +0000 (16:12 +0000)]
Bug 20640: (follow-up) Always send a backend on migrate

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20640: (follow-up) Make error message translatable
Martin Renvoize [Fri, 11 Jan 2019 14:50:47 +0000 (14:50 +0000)]
Bug 20640: (follow-up) Make error message translatable

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20640: (follow-up) Redirect to new request at completion
Martin Renvoize [Fri, 11 Jan 2019 12:41:29 +0000 (12:41 +0000)]
Bug 20640: (follow-up) Redirect to new request at completion

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20640: (follow-up) Degrade gracefully on error
Martin Renvoize [Thu, 1 Nov 2018 15:29:08 +0000 (15:29 +0000)]
Bug 20640: (follow-up) Degrade gracefully on error

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20640: Add backend migration support to ILL
Martin Renvoize [Fri, 27 Apr 2018 07:48:53 +0000 (08:48 +0100)]
Bug 20640: Add backend migration support to ILL

- Add core methods required to support the migration of ILL requests
between backends.

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 19945: Use CanItemBeReserved in ILSDI HoldItem instead of CanBookBeReserved.
Alex Arnaud [Tue, 18 Sep 2018 13:05:26 +0000 (13:05 +0000)]
Bug 19945: Use CanItemBeReserved in ILSDI HoldItem instead of CanBookBeReserved.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 19945: Add a test proving that using CanBookBeReserved in ILSDI::HoldItem is...
Alex Arnaud [Tue, 18 Sep 2018 12:59:26 +0000 (12:59 +0000)]
Bug 19945: Add a test proving that using CanBookBeReserved in ILSDI::HoldItem is wrong.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 19945: (follow-up) optimization and test correction
Mark Tompsett [Tue, 27 Mar 2018 19:31:36 +0000 (19:31 +0000)]
Bug 19945: (follow-up) optimization and test correction

The double call to CanItemBeReserved was pointless in
the C4/Reserves.pm HoldItem, as CanBookBeReserved calls
CanItemBeReserved and even returns that code.

Additionally, the tests failed, because there were 5
tests not 4.

TEST PLAN
----------
prove t/db_dependent/ILSDI_Services.t
run koha qa test tools

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>