koha.git
5 years agoBug 21576: Add a developer script to fix missing TT filters
Jonathan Druart [Fri, 12 Oct 2018 16:57:49 +0000 (13:57 -0300)]
Bug 21576: Add a developer script to fix missing TT filters

See bug 13618 and bug 21526.

We need a script to add missing filters, or replace wrong ones.

Test plan:
- Add unescaped variables to .tt files
- prove xt/find-missing-filters.t
will warn about them
- perl misc/devel/add_missing_filters.pl
will add the missing/wrong filters
- prove xt/find-missing-filters.t
will now be happy

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21562: Fix sort by checkout date in the circulation table
Jonathan Druart [Mon, 22 Oct 2018 19:51:25 +0000 (16:51 -0300)]
Bug 21562: Fix sort by checkout date in the circulation table

The sort is done in SQL but resort by DataTables when displaying the
results.
iDataSort should be used to mimick date_due sort behavior.

Test plan:
- Check some items out
- Modify the checkout and due dates, like:
    2018-10-22
    2018-01-23
    2018-05-27
- Sort by checkout date, then due date. The sort should be correct for
all values of the DateFormat syspref

Followed test plan, patch works as described and passes QA test tool

Signed-off-by: Alex Buckley <alexbuckley@catalyst.net.nz>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21629: Use cn_sort instead of itemcallnumber when displaying a list
Jonathan Druart [Mon, 22 Oct 2018 20:02:51 +0000 (17:02 -0300)]
Bug 21629: Use cn_sort instead of itemcallnumber when displaying a list

DBMS can sort callnumbers correctly using cn_sort. We should use it
showing a list's content.

Test plan:
- Add items with callnumber to a list
- Display the list
- List the content by callnumbers
=> Confirm that the records are correctly sorted by callnumber

Signed-off-by: Myka Kennedy Stephens <mkstephens@lancasterseminary.edu>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21639: DBRev 18.06.00.045
Nick Clemens [Fri, 26 Oct 2018 17:09:18 +0000 (17:09 +0000)]
Bug 21639: DBRev 18.06.00.045

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21639: (follow-up) Adjust the other languages
Jonathan Druart [Thu, 25 Oct 2018 15:00:35 +0000 (12:00 -0300)]
Bug 21639: (follow-up) Adjust the other languages

uk-UA was wrong.
We should use the same file for all languages

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21639: Adjust the other languages
Nick Clemens [Wed, 24 Oct 2018 19:43:18 +0000 (19:43 +0000)]
Bug 21639: Adjust the other languages

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21639: Add phone transports to new and existing installs
Nick Clemens [Wed, 24 Oct 2018 01:33:42 +0000 (01:33 +0000)]
Bug 21639: Add phone transports to new and existing installs

To test:
1 - Confirm if you do or do not have 'phone' transports defined in the
message_transports table
2 - Apply patch
3 - Run updatedatabase
4 - If you didn't have them you should now
5 - Run updatedatabase again, confirm it doesn't error
6 - sudo koha-mysql kohadev
7 - DELETE from message_transports WHERE message_transport_type =
'phone'
8 - Run updatedatabase again
9 - Confirm the message transports table is restored
10 - Drop your DB (or reset_all in kohadevbox)
11 - Ensure the table is fully populated including phone notices

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21587: don't drop patrons to notify in order creation
Victor Grousset [Thu, 18 Oct 2018 09:54:58 +0000 (11:54 +0200)]
Bug 21587: don't drop patrons to notify in order creation

It only worked on modification.

== Test plan ==
1. have/create a active budget
2. have/create a fund
3. have/create a vendor with minimal info
4. create a basket with minimal info
5. add an order line to the basket
     Add a user in "To notify on receiving"
6. Modify the order
7. The patrons isn't here. This is the bug
8. Add a user in "To notify on receiving"
9. Save
10. Modify the order
11. The patron is here now
12. Apply this patch
13. Retry step 5 to 11 and patron should be saved on order creation
14. Celebrate! :D

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21669: Do not html filter TT assignement statements
Jonathan Druart [Thu, 25 Oct 2018 15:55:43 +0000 (12:55 -0300)]
Bug 21669: Do not html filter TT assignement statements

Why? Because we must filter the variables when we display them.
If we escape them on assignement, they will be double escaped:
  [% XXX = "<span>pouet</span>" | html %]
  [% XXX | html %]
  => &lt;span&gt;pouet&lt;/span&gt;

Also it will bring trouble if we are assigning a structure (see bug
21663 for instance).

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 21663: Incorrect filter prevents predefined notes from being added to patron...
Owen Leonard [Thu, 25 Oct 2018 13:30:34 +0000 (13:30 +0000)]
Bug 21663: Incorrect filter prevents predefined notes from being added to patron acccounts

This patch removes an "html" filter from the template include which
allows one to add predefined nots to a patron's account.

To test, apply the patch and open a patron record for viewing or
checkout. Click the "Add message" button. The "predefined notes"
dropdown should contain the authorised_values you have with the
'BOR_NOTES' category.

Signed-off-by: Andrew Isherwood <andrew.isherwood@ptfs-europe.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21603: Remove incorrect GROUP BY from C4::CourseReserves
Jonathan Druart [Thu, 18 Oct 2018 21:00:15 +0000 (18:00 -0300)]
Bug 21603: Remove incorrect GROUP BY from C4::CourseReserves

'koha_kohadev.c.department' isn't in GROUP BY

Test plan:
Prove that the test fail without this patch and pass with this patch
applied (switch on the SQL modes)

Signed-off-by: Andrew Isherwood <andrew.isherwood@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21612: Remove incorrect GROUP BY's from Koha::VirtualShelves
Jonathan Druart [Thu, 18 Oct 2018 20:37:35 +0000 (17:37 -0300)]
Bug 21612: Remove incorrect GROUP BY's from Koha::VirtualShelves

'koha_kohadev.me.shelfname' isn't in GROUP BY

Same as
  commit 7e220e0d8f107cce63f32bfaa1919c04b4dea6e2
  Bug 20179: [sql_modes] Remove GROUP BY in get_shelves_containing_record

Test plan:
- Add public and privates shelves
- Shares some of them
- List them
=> The correct numbers of shelves must be displayed

Signed-off-by: Andrew Isherwood <andrew.isherwood@ptfs-europe.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21635: [sql_modes] Remove GROUP BY clause in batchMod.pl
Jonathan Druart [Tue, 23 Oct 2018 13:35:24 +0000 (10:35 -0300)]
Bug 21635: [sql_modes] Remove GROUP BY clause in batchMod.pl

batchMod.pl: DBD::mysql::st execute failed: 'koha_kohadev.authorised_values.authorised_val
ue' isn't in GROUP BY [for Statement "SELECT authorised_value, lib FROM authorised_values LEFT JOIN authorised_values_branches ON ( id = av_id )  WHERE category = ? AND ( branchcode = ? OR branchcode IS NULL )
GROUP BY lib ORDER BY lib, lib_opac" with ParamValues: 0='WITHDRAWN', 1="CPL"] at /home/vagrant/kohaclone/tools/batchMod.pl line 396.

We must use Koha::AuthorisedValues->search instead of a raw SQL query.

Test plan:
Edit some items in a batch
Confirm that the dropdown list (AV) are correctly filled

We will lose speed efficiency here, but better to be consistent, then cache AV in Koha::AuthorisedValues

Signed-off-by: Andrew Isherwood <andrew.isherwood@ptfs-europe.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 7143: Update about page for new devs Margaret Hade and Isobel Graham
Nick Clemens [Fri, 26 Oct 2018 16:25:02 +0000 (16:25 +0000)]
Bug 7143: Update about page for new devs Margaret Hade and Isobel Graham

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20758: Fix for BrowseResultSelection typo
Isobel Graham [Sat, 20 Oct 2018 08:12:19 +0000 (09:12 +0100)]
Bug 20758: Fix for BrowseResultSelection typo

To test:
1) The  BrowseResultSelection description should no longer contain
"fromt"

Mentored-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21337: (QA follow-up) Rename exception code
Marcel de Rooy [Thu, 25 Oct 2018 12:25:10 +0000 (14:25 +0200)]
Bug 21337: (QA follow-up) Rename exception code

Patron::Delete becomes Patron::FailedDelete.
Trivial replace.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 13618: Remove html filter for LAST
Jonathan Druart [Thu, 25 Oct 2018 15:56:38 +0000 (12:56 -0300)]
Bug 13618: Remove html filter for LAST

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 13618: remove wrong html filter in 'Item search fields' admin
Jonathan Druart [Tue, 2 Oct 2018 11:46:58 +0000 (08:46 -0300)]
Bug 13618: remove wrong html filter in 'Item search fields' admin

The dropdown list contain the arrayref: ARRAY(0x...)

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21596: (follow-up) Handle updated_on
Jonathan Druart [Thu, 25 Oct 2018 13:24:46 +0000 (10:24 -0300)]
Bug 21596: (follow-up) Handle updated_on

Default value should only used if not exist.
We got a failing test with the previous patch:
 #   Failed test 'borrowers.updated_on should have been kept to what we set on creating'
 #   at t/db_dependent/Patrons.t line 78.
 #          got: '1'
 #     expected: '0'

Test plan:
prove -r t/Auth_with_shibboleth.t t/db_dependent/Patrons.t t/db_dependent/Koha/Patron*

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 15486: Fix failing test in GetHardDueDate.t
Jonathan Druart [Wed, 24 Oct 2018 20:08:05 +0000 (17:08 -0300)]
Bug 15486: Fix failing test in GetHardDueDate.t

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 15766: Update tests
Nick Clemens [Wed, 24 Oct 2018 19:28:44 +0000 (19:28 +0000)]
Bug 15766: Update tests

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21596: Handle updated_on
Jonathan Druart [Wed, 24 Oct 2018 17:35:16 +0000 (14:35 -0300)]
Bug 21596: Handle updated_on

This has been picked from the solution proposed on bug 21610. It may not
be pushed soon and so we need a fix for the failing tests
(t/Auth_with_shibboleth.t)

Test plan:
 prove -r t/Auth_with_shibboleth.t t/db_dependent/Koha/Patrons*
must return green

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 15766: (RM follow-up) Schema updates
Nick Clemens [Wed, 24 Oct 2018 17:35:18 +0000 (17:35 +0000)]
Bug 15766: (RM follow-up) Schema updates

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21511: (RM follow-up) Use orders.count instead of new variable
Nick Clemens [Tue, 23 Oct 2018 13:17:06 +0000 (13:17 +0000)]
Bug 21511: (RM follow-up) Use orders.count instead of new variable

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21511: Don't show acquisition details on subscription detail when there is no...
Owen Leonard [Tue, 9 Oct 2018 17:19:09 +0000 (17:19 +0000)]
Bug 21511: Don't show acquisition details on subscription detail when there is no acq data

This patch modifies the subscription detail page so that acquisitions
details section is not shown when there is no acquisitions data.

The acquisitions details are moved into a new tab similar to how it
appears on the bibliographic details page. A count of orders is now
passed to the template so that the check for existing acquisitions data
will work correctly.

To test, apply the patch and view the detail page for subscriptions.

- When viewing a subscription for which there are orders you should see
  an "Acquisitions details" tab containing the acquisitions data.
- When viewing a subscription with no orders the tab should not appear.

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>
5 years agoBug 15766: DBRev 18.06.00.044
Nick Clemens [Wed, 24 Oct 2018 17:19:19 +0000 (17:19 +0000)]
Bug 15766: DBRev 18.06.00.044

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 15766: Fix incorrect GROUP BY
Jonathan Druart [Wed, 24 Oct 2018 14:51:12 +0000 (11:51 -0300)]
Bug 15766: Fix incorrect GROUP BY

'koha_kohadev.creator_batches.description' isn't in GROUP BY

Fix t/db_dependent/Creators/Lib.t if strict sql modes is on

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 15766: (follow-up) Fixing layout of description button
Aleisha Amohia [Wed, 6 Jun 2018 01:48:33 +0000 (01:48 +0000)]
Bug 15766: (follow-up) Fixing layout of description button

This patch moves the 'Save' button to the toolbar as suggested. The
description textbox and 'Save' button are hidden if the batch is new and
appears when items are added.

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 15766: (follow-up) Correct merge errors
Owen Leonard [Thu, 31 May 2018 16:54:43 +0000 (16:54 +0000)]
Bug 15766: (follow-up) Correct merge errors

This patch corrects some problems applying this on current master and
removes an old merge conflict marker.

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 15766: (follow-up) Hide description field if the batch is empty
Aleisha Amohia [Wed, 18 Oct 2017 22:40:13 +0000 (22:40 +0000)]
Bug 15766: (follow-up) Hide description field if the batch is empty

Because if it's empty, it hasn't actually been created yet. Hiding the
field prevents a lot of errors

Sponsored-by: Catalyst IT
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 15766: (follow-up) Save description link as button on patroncard side
Aleisha Amohia [Tue, 10 Oct 2017 03:21:33 +0000 (03:21 +0000)]
Bug 15766: (follow-up) Save description link as button on patroncard side

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 15766: (follow-up) Making 'Save description' link a button
Aleisha Amohia [Fri, 22 Sep 2017 02:29:54 +0000 (02:29 +0000)]
Bug 15766: (follow-up) Making 'Save description' link a button

For consistency's sake in response to Comment 17.

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 15766: Adding descriptions to patron card batches
Aleisha Amohia [Sun, 27 Aug 2017 21:48:06 +0000 (21:48 +0000)]
Bug 15766: Adding descriptions to patron card batches

This patch adds a 'description' column to the creator_batches table. The
description for a batch can be added and updated using ajax.

To test:
1) Apply patch and update database (you will have to restart memcached)
2) Go to Tools -> Patron card creator -> Manage batches
3) There should now be a Description column next to Batch ID. This
will be empty (as none of the batches have descriptions yet)
4) Click Edit for any batch
5) Notice new Batch description text field. Enter a description for
the batch in here and click Save description. Some text should show
saying the description was saved.
6) If you go back to the manage batches page, the description should
now show under the Description column.
7) Go to Tools -> Label Creator -> Manage labels
8) Repeat steps 3 to 6

Sponsored-by: Catalyst IT
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 21216: (follow-up) Exclude some columns from export
Owen Leonard [Mon, 24 Sep 2018 13:37:16 +0000 (13:37 +0000)]
Bug 21216: (follow-up) Exclude some columns from export

This patch adds a custom buttons configuration to the Notices table so
that columns with form controls are not included in copy/print/export
operations.

The DataTables columns settings include file has been modified
to check for an existing buttons export columns configuration before
applying the default.

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

Go to Tools -> Notices & slips. The table of notices should have a
DataTables toolbar with a filter form, column visibility, and export
buttons. Test the functionality of all these tools. Only the first four
columns of the table should be included in printouts and exported files.

Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21216: Add filter/search options to notices table
Owen Leonard [Sun, 19 Aug 2018 19:19:49 +0000 (15:19 -0400)]
Bug 21216: Add filter/search options to notices table

This patch adds a DataTables toolbar to the Notices & slips table,
including a filter field, column visibility, and data export options.

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

 - Go to Tools -> Notices & slips
 - Confirm that there is a table toolbar with a filter, a "Column
   visibility" button, and "Excel," "CSV," "Copy," and "Print" buttons.
 - Confirm that showing and hiding columns via the button is working
   correctly.
 - Confirm that only the first four columns are sortable.

Go to Administration -> Columns settings.

- Expand the "Tools" section.
- Find "id=lettert."
- Make some selections to configure default settings of the reports
  table.
- Return to reports and confirm that these defaults are applied.

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20554: (follow-up) KOHA_VERSION is not needed in opaclayoutstylesheet
Fridolin Somers [Wed, 24 Oct 2018 13:09:07 +0000 (15:09 +0200)]
Bug 20554: (follow-up) KOHA_VERSION is not needed in opaclayoutstylesheet

SET opaclayoutstylesheet does not need KOHA_VERSION, its defined by Asset.css()

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Fix a bad resolution conflict

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 15486: DBRev 18.06.00.043
Nick Clemens [Wed, 24 Oct 2018 13:22:46 +0000 (13:22 +0000)]
Bug 15486: DBRev 18.06.00.043

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 15486: (follow-up) Default to unlimited
Tomas Cohen Arazi [Mon, 24 Sep 2018 15:56:07 +0000 (12:56 -0300)]
Bug 15486: (follow-up) Default to unlimited

While it doesn't have a practical effect (the variable is reset several
lines below) I agree this should be explicitly set to its default.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Séverine QUEUNE <severine.queune@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>
5 years agoBug 15486: Make circ rules UI handle holds_per_day
Tomas Cohen Arazi [Wed, 7 Feb 2018 19:10:28 +0000 (16:10 -0300)]
Bug 15486: Make circ rules UI handle holds_per_day

This patch makes the staff UI correctly handle the holds_per_day
configuration.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
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>
5 years agoBug 15486: Modify request.tt to handle the new error string
Tomas Cohen Arazi [Wed, 19 Jul 2017 22:32:09 +0000 (19:32 -0300)]
Bug 15486: Modify request.tt to handle the new error string

This patch makes reserve/request.pl display a convenient error
description when a hold cannot be placed due to the new daily limit
configuration.

To test:
- Apply this patchset
- Upgrade
- Configure your circulation rules so there's a daily limit for holds
- Place holds so the patron reaches the maximum
- Place one more hold
- Notice the hold cannot be placed and a convenient error message is
displayed.
- Sign off :-D

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>
5 years agoBug 15486: Extend CanItemBeReserved so it handles daily holds limits
Tomas Cohen Arazi [Wed, 19 Jul 2017 21:14:19 +0000 (18:14 -0300)]
Bug 15486: Extend CanItemBeReserved so it handles daily holds limits

This patch implements the required changes in
C4::Reserves::CanItemBeReserved so it implements a daily limit on holds.

It returns the 'tooManyReservesToday' string if the policy doesn't allow
placing the hold. It returns 'OK' (current behaviour) otherwise.

To test:
- Run:
  $ sudo koha-shell kohadev
 k$ cd kohaclone
 k$ prove t/db_dependent/Holds.t
=> FAIL: Tests fail because the error condition is not making
CanItemBeReserved return the desired error code.
- Apply this patch
- Run:
 k$ prove t/db_dependent/Holds.t
=> SUCCESS: Tests pass!
- Sign off :-D

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>
5 years agoBug 15486: Unit tests
Tomas Cohen Arazi [Wed, 19 Jul 2017 19:30:24 +0000 (16:30 -0300)]
Bug 15486: Unit tests

This patch introduces unit tests for the new circulation rules option
that allows setting a max holds per day limit.

To test:
- Apply the patch
- Run:
  $ sudo koha-shell kohadev
 k$ cd kohaclone
 k$ prove t/db_dependent/Holds.t
=> FAIL: CanItemBeReserved doesn't check the amount of holds per day
   and the introduced error code is not returned. OK is returned
   instead.

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>
5 years agoBug 15486: DB structure change
Tomas Cohen Arazi [Fri, 7 Jul 2017 18:13:00 +0000 (15:13 -0300)]
Bug 15486: DB structure change

This patch adds a new column __max_holds_per_day__ to the issuingrules table.
It's going to be used to set a daily limit  for holds.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
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>
5 years agoBug 20044: (follow-up) Add min-width to .input_marceditor
Owen Leonard [Fri, 3 Aug 2018 14:37:09 +0000 (14:37 +0000)]
Bug 20044: (follow-up) Add min-width to .input_marceditor

This patch adds a min-width property to the first .input_marceditor rule
in order to prevent <selects> styled by Select2 from collapsing at
narrower browser widths.

To reproduce the bug, apply all patches on Bug 20044 except this one.
Open the MARC editor and narrow the browser width to below 768 pixels.
Reload the page and view a tab which contains a <select> styled by
Select2 (942c is often an example). The <select> will have narrowed to
be almost invisible.

Apply the patch and reproduce the steps above. The <select>s should be
fully visible.

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>
5 years agoBug 20044: Fix input_marceditor selectors
Jonathan Druart [Wed, 1 Aug 2018 19:18:04 +0000 (16:18 -0300)]
Bug 20044: Fix input_marceditor selectors

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
I can't reproduce the problem this patch is intended to fix, but the
changes are sensible either way.

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>
5 years agoBug 20044: (follow-up) Improve responsive behavior of MARC editor
Owen Leonard [Tue, 13 Mar 2018 09:02:51 +0000 (09:02 +0000)]
Bug 20044: (follow-up) Improve responsive behavior of MARC editor

This patch makes some changes to addbiblio.css in order to improve
responsive changes to the MARC editor.

Note: This patch does not make changes affecting narrow browser widths.
The changes are focused on adapting to larger layouts affected by the
switch to the Bootstrap grid.

To test, apply the patch and clear your cache if necessary. Open an
existing record for editing in the standard MARC editor. View the page
at various browser widths and confirm that it looks correct.

Note: Because of the way the floating toolbar is displayed it does not
dynamically resize when you resize the browser. Reload the page after
resizing the browser window to confirm that the toolbar adapts at
different widths.

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
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>
5 years agoBug 20044: Switch single-column templates to Bootstrap grid: Cataloging
Owen Leonard [Fri, 19 Jan 2018 15:10:18 +0000 (15:10 +0000)]
Bug 20044: Switch single-column templates to Bootstrap grid: Cataloging

This patch updates several cataloging module templates to use the
Bootstrap grid.

- cataloguing/addbooks.tt - Cataloging - The main page and the
  cataloging search results page should look correct.

- cataloguing/addbiblio.tt - Cataloging -> New record - The record edit
  page should look correct.

- cataloguing/merge.tt - Cataloging -> Search -> Select two records to
  merge. The merge reference selection page should look correct, as well
  as the source/destination selection page.

- cataloguing/moveitem.tt - Catalog -> Search -> View record -> Edit ->
  Attach item. The barcode submit form and confirmation screens should
  look correct.

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
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>
5 years agoBug 21492: Show subscriptions count in the sidebar menu
Owen Leonard [Wed, 10 Oct 2018 13:32:29 +0000 (13:32 +0000)]
Bug 21492: Show subscriptions count in the sidebar menu

This patch modifies the include file for the sidebar menu of
bibliographic views so that a count of subscriptions is shown on the
subscriptions tab.

To test you should have bibliographic record with one or more
subscriptions. View that bibliographic record and confirm that the
sidebar menu tab shows the count of subscriptions.

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

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21625: Fix wording and typo in SMSSendDriver system preference description
Katrin Fischer [Sun, 21 Oct 2018 02:34:25 +0000 (02:34 +0000)]
Bug 21625: Fix wording and typo in SMSSendDriver system preference description

SMSSendDriver was missing an S.
Koha is sending not receiving messages, so I think switching
that will be a little more clear.

To test:
Verify that the system preference description reads correctly.

Signed-off-by: Andreas Roussos <arouss1980@gmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21584: Wrong offset type for Lost Item
Tomas Cohen Arazi [Tue, 16 Oct 2018 18:15:10 +0000 (15:15 -0300)]
Bug 21584: Wrong offset type for Lost Item

Bug 2696 introduced account_offset_type.inc but 'Lost Item Return' doesn't match what is added on the database. Moreover, bug 20978 added references to this wrong value too in Koha::Account

This patch performs a trivial fix for this.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Patch matches what was outlined in test plan, also passes qa test tool

Signed-off-by: Alex Buckley <alexbuckley@catalyst.net.nz>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21614: Search bar on Stock rotation page displays both [-] and [+] simultaneously
Owen Leonard [Fri, 19 Oct 2018 11:50:06 +0000 (11:50 +0000)]
Bug 21614: Search bar on Stock rotation page displays both [-] and [+] simultaneously

This patch modifies the stock rotation template so that it include the
catalog search bar include instead of the patrons one.

To test, apply the patch and enable the StockRotation system preference.

 - Go to Tools -> Stock rotation.
 - Confirm that the search boxes at top are 'Check out,' 'Check in,'
   'Renew,' and 'Search the catalog.' 'Search the catalog' should be
   selected.

Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21486: Only fetch the items' barcodes
Jonathan Druart [Wed, 17 Oct 2018 15:32:11 +0000 (12:32 -0300)]
Bug 21486: Only fetch the items' barcodes

and avoid unecessary processing

Signed-off-by: Colin Campbell <colin.campbell@ptfs-europe.com>
Tested and found correct AU data is returned, and passes QA test tool

Signed-off-by: Alex Buckley <alexbuckley@catalyst.net.nz>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21486: Fix 'AU' for SIP
Jonathan Druart [Fri, 12 Oct 2018 15:47:04 +0000 (12:47 -0300)]
Bug 21486: Fix 'AU' for SIP

Signed-off-by: Colin Campbell <colin.campbell@ptfs-europe.com>
Signed-off-by: Alex Buckley <alexbuckley@catalyst.net.nz>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21607: Make Koha::Account::Line->apply store credits as negative amounts
Tomas Cohen Arazi [Thu, 18 Oct 2018 14:39:37 +0000 (11:39 -0300)]
Bug 21607: Make Koha::Account::Line->apply store credits as negative amounts

This is a trivial patch, that makes offsets have 'amount' stored as
negative values for applied credits.

The behaviour is changed on the tests and adjusted in the code. To test:
- Run
  $ kshell
 k$ prove t/db_dependent/Koha/Account/Lines.t
=> SUCCESS: Tests pass!
- Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20554: Compiled CSS
Nick Clemens [Fri, 19 Oct 2018 17:22:37 +0000 (17:22 +0000)]
Bug 20554: Compiled CSS

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20554: (QA follow up) Remove padding in mobile view
Claire Gravely [Fri, 14 Sep 2018 21:06:40 +0000 (21:06 +0000)]
Bug 20554: (QA follow up) Remove padding in mobile view

This patch removes the padding for mobile screen sizes.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20554: (follow-up) Add local font files and add method for loading them
Owen Leonard [Fri, 20 Apr 2018 17:08:21 +0000 (17:08 +0000)]
Bug 20554: (follow-up) Add local font files and add method for loading them

This patch adds local copies of the font files specified in the original
patch. A new JavaScript file has been added, fontfaceobserver.min.js,
which helps gracefully load font assets.

https://github.com/bramstein/fontfaceobserver

Information about the new assets has been added to the about page.

When using web fonts, there can be a delay, while the browser loads the
font files, between the time the page loads and the time the fonts
render. Font Face Observer allows us to specify a default font for the
initial page render, and then apply the web font after it has loaded.

To test, apply the patch and regenerate the OPAC css. View any page in
the OPAC and confirm that the custom font renders properly.

View the About page in the staff client and confirm that the new license
information looks correct.

Patch applies and OPAC and license look good. Looking forward to this.
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>
5 years agoBug 20554: New OPAC CSS
Claire Gravely [Tue, 10 Apr 2018 14:39:07 +0000 (14:39 +0000)]
Bug 20554: New OPAC CSS

A suggestion for updating the OPAC CSS

This patch updates the css styling of the OPAC

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 15282: Switch default CHECKIN notice to Template Toolkit
Kyle M Hall [Wed, 2 Dec 2015 15:46:41 +0000 (15:46 +0000)]
Bug 15282: Switch default CHECKIN notice to Template Toolkit

Test Plan:
1) Ensure dependancies are applied
2) Apply this patch
3) Update your CHECKIN notice to match the following:

The following items have been checked in:
----
[% biblio.title %]
----
Thank you.

3) Generate a CHECKIN notice for a patron
4) Note there is no change to the generated notice

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 15280: Switch default CHECKOUT notice to Template Toolkit
Kyle M Hall [Wed, 2 Dec 2015 15:21:11 +0000 (15:21 +0000)]
Bug 15280: Switch default CHECKOUT notice to Template Toolkit

Test Plan:
1) Ensure dependancies are applied
2) Apply this patch
3) Update your CHECKOUT notice to match the following:

The following items have been checked out:
----
[% biblio.title %]
----
Thank you for visiting [% branch.branchname %].

3) Generate a CHECKOUT notice for a patron
4) Note there is not change to the generated notice

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21505: Box around 'Additional fields' does not contain the fields
Owen Leonard [Tue, 9 Oct 2018 18:05:04 +0000 (18:05 +0000)]
Bug 21505: Box around 'Additional fields' does not contain the fields

This patch modifies the subscription detail page markup to eliminate a
confusing bordered <legend> tag. It is replaced with an <hr> to
delineate the sections and an <h3> tag to serve as the heading.

To test, apply the patch and regenerate the staff client CSS.

 - Configure one or more additional subscription fields.
 - View the detail page for a subscription and confirm that the
   "Additional fields" section is clearly labeled.

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>
5 years agoBug 21531: Subscription "New fields" button should read "New field"
Owen Leonard [Wed, 10 Oct 2018 12:10:45 +0000 (12:10 +0000)]
Bug 21531: Subscription "New fields" button should read "New field"

This patch changes the label of the "New fields" button on the
subscription add fields page to read "New field," making it consistent
with similar buttons in the staff client.

Also changed:

- Add missing id to <select> to make label clickable.
- Remove custom DataTables configuration in favor of defaults.

To test, apply the patch and go to Serials -> Add subscription fields.

- The button in the toolbar should read "New field."
- The DataTables' functionality of the table of existing custom fields
  should be correct.
- Click the "New field" button.
  - Cliking the "Authorised value category" label should put the focus
    on the dropdown.

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>
5 years agoBug 21523: Update two-column templates with Bootstrap grid: Serials part 2
Owen Leonard [Tue, 9 Oct 2018 16:41:55 +0000 (16:41 +0000)]
Bug 21523: Update two-column templates with Bootstrap grid: Serials part 2

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

 - Serials home page
   - Subscription search
     - Subscription details
       - Edit history (under the "Planning" tab. Manual history must be
         enabled for that subscription).
       - Subscribers
 - Serials -> Manage frequencies
 - Serials -> Manage numbering patterns

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>
5 years agoBug 21519: Update two-column templates with Bootstrap grid: Serials part 1
Owen Leonard [Tue, 9 Oct 2018 13:41:39 +0000 (13:41 +0000)]
Bug 21519: Update two-column templates with Bootstrap grid: Serials part 1

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

 - Serials -> Add subscription fields
   - Add or edit subscription fields
 - Serials -> Check expiration
 - Serials -> Claims
 - Serials -> Subscription
   -> Serial collection
      -> Edit serials
   -> Routing list
     - Save and preview routing list

Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21590: change virtual shelf to list in send list email.
Barton Chittenden [Wed, 17 Oct 2018 19:29:22 +0000 (19:29 +0000)]
Bug 21590: change virtual shelf to list in send list email.

To test

1) Choose a public list from the 'lists' menu in the OPAC.
2) Click 'Send list'
3) Log in as necessary
4) Fill in your own email address
5) Click 'send'
6) Check your email, the sent email will contain the text
   "sent you from our online catalog, the virtual shelf called".

Apply patch, re-test. The email will now contain
   "sent you from our online catalog, the list called".

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21005: Address QA tool failures on tabs
Mark Tompsett [Wed, 17 Oct 2018 01:39:41 +0000 (01:39 +0000)]
Bug 21005: Address QA tool failures on tabs

Only whitespace changes.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21005: Missing row/column defaults cause unexpected results in report wizards
David Cook [Fri, 10 Aug 2018 08:08:13 +0000 (18:08 +1000)]
Bug 21005: Missing row/column defaults cause unexpected results in report wizards

Some report wizards are missing row/column defaults, which sometimes return blank
pages (borrowers_stats.pl) or results always equalling 0, which a non-discerning
user may interpret incorrectly.

If the DEBUG environmental variable is enabled, missing row/column choices will
actually cause fatal software errors as well, which is also undesirable for users.

This patch adds default choices for row and column on
report wizards that had no radio buttons selected, so that a user
can't submit the form without choosing a row and column. This
prevents errors.

To test:
1) Apply patch
2) Visit /cgi-bin/koha/reports/issues_avg_stats.pl
3) Visit /cgi-bin/koha/reports/borrowers_stats.pl
4) Visit /cgi-bin/koha/reports/catalogue_stats.pl
5) Visit /cgi-bin/koha/reports/issues_stats.pl
6) Observe that default choices for row/column are there

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20592: Return early in ModItem if nothing to update
Mark Tompsett [Tue, 17 Apr 2018 23:59:58 +0000 (23:59 +0000)]
Bug 20592: Return early in ModItem if nothing to update

Two lines of code and move them earlier.
Add a check to make sure there are changes.

Followed the test plan, both the _BEFORE_ and after do as described.

Signed-off-by: Cori Lynn Arnold <carnold@dgiinc.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20592: Add tests
Jonathan Druart [Tue, 24 Apr 2018 18:53:02 +0000 (15:53 -0300)]
Bug 20592: Add tests

NOTE: It isn't really a test, but it does trigger
      the return line which was added to ModItem.

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21277: (follow-up) fr-CA translation for notices in sample_notices.sql
Caroline Cyr La Rose [Fri, 19 Oct 2018 00:18:54 +0000 (20:18 -0400)]
Bug 21277: (follow-up) fr-CA translation for notices in sample_notices.sql

This follow-up patch adds fr-CA translation for the SR_SLIP notice.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21277: fr-CA translation for notices in sample_notices.sql
Caroline Cyr La Rose [Mon, 27 Aug 2018 14:46:12 +0000 (10:46 -0400)]
Bug 21277: fr-CA translation for notices in sample_notices.sql

This patch adds fr-CA translations for the following sample notices:

- ACCOUNT_PAYMENT
- ACCOUNT_WRITEOFF
- ACQORDER
- AR_CANCELED
- AR_COMPLETED
- AR_PENDING
- AR_PROCESSING
- AR_SLIP
- CANCEL_HOLD_ON_LOST
- CHECKOUT_NOTE
- MEMBERSHIP_EXPIRY
- PASSWORD_RESET

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21617: DBRev 18.06.00.042
Nick Clemens [Fri, 19 Oct 2018 16:50:40 +0000 (16:50 +0000)]
Bug 21617: DBRev 18.06.00.042

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21617: statistics.ccode is not long enough (see also DBRev 18.06.00.032)
Marcel de Rooy [Fri, 19 Oct 2018 08:51:05 +0000 (10:51 +0200)]
Bug 21617: statistics.ccode is not long enough (see also DBRev 18.06.00.032)

Warn from a test:
DBD::mysql::st execute failed: Data too long for column 'ccode' at row 1 [for Statement "INSERT INTO statistics
        (datetime,
         branch,          type,        value,
         other,           itemnumber,  itemtype, location,
         borrowernumber,  proccode,    ccode)
         VALUES (now(),?,?,?,?,?,?,?,?,?,?)" with ParamValues: 0="z8LIyIV", 1='issue', 2=undef, 3='', 4='2584', 5='E_QkzaV5Ay', 6='oDnFRZyog2CS2_XoUB_MB2sBxyI3elbFPC_AekxLPrduGTXKnlNoLKEdQrXzpAw5zD1pGbZshV9ydZup', 7='2000005168', 8='', 9='j9ZDn74omZAoZrTOdC4a05SpWRSHPR2apfss7y5V6QJuQnBEk32XWXCfMp7'] at C4/Stats.pm line 138.

The dbrev 18.06.00.032 did not change it from 10 to 80 as in other tables.

We should either truncate to 10 chars in Stats.pm or increase to varchar(80). Since it is varchar and not char, we should not be afraid about size. I choose for the latter here.

Test plan:
Run db rev.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21497: Correctly format dates for ILL requests in OPAC
Owen Leonard [Fri, 5 Oct 2018 12:50:26 +0000 (12:50 +0000)]
Bug 21497: Correctly format dates for ILL requests in OPAC

This patch updates the opac ILL template to use the $KohaDates plugin
for displaying dates. Also updated:

- Added "title-string" sorting to allow for correct sorting of dates in
  the table of requests.
- Corrected capitalization as per our capitalization rules.
- Added self-closing / to inputs as per coding guidelines.

To test, apply the patch and log in to the OPAC as a user who has
multiple outstanding ILL requests.

 - In the table of ILL requests, the "Request placed" and "Last updated"
   dates should be formatted according to your system's dateformat
   preference.
 - Sorting of those columns should work correctly.
 - View a request and confirm that "Request placed" and "Last updated"
   dates in this view are also formatted correctly.

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 18959: Skip xt/author/Text_CSV_Various.t if Text::CSV::Unicode missing
Tomas Cohen Arazi [Sat, 13 Oct 2018 12:17:00 +0000 (09:17 -0300)]
Bug 18959: Skip xt/author/Text_CSV_Various.t if Text::CSV::Unicode missing

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 18959: Text::CSV::Unicode missing from dependencies
Tomas Cohen Arazi [Sat, 13 Oct 2018 12:15:52 +0000 (09:15 -0300)]
Bug 18959: Text::CSV::Unicode missing from dependencies

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21600: Use str param instead of dt for output_pref
Jonathan Druart [Thu, 18 Oct 2018 19:36:45 +0000 (16:36 -0300)]
Bug 21600: Use str param instead of dt for output_pref

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21600: /patrons should have timestamp/datetime values converted from rfc3339...
Tomas Cohen Arazi [Thu, 18 Oct 2018 18:50:27 +0000 (15:50 -0300)]
Bug 21600: /patrons should have timestamp/datetime values converted from rfc3339 into valid MySQL values

Bug 21597 enabled the option so set strict SQL modes in koha-conf.xml to
be able to improve Koha's comformance to current standards on DB
engines.

This causes lots of parts of Koha to fail because they rely on MySQL
fallbacks that are no longer default behaviours.

While we can workaround this by setting SQL modes on runtime, the
decision has been that this needs fixing.

This patch deals with the /patrons API failing to correctly convert
datetimes into valid SQL timestamps.

To test:
- Run:
  $ kshell
 k$ prove t/db_dependent/api/v1/patrons.t
=> SUCCESS: Tests pass
- Add <strict_sql_modes>1</strict_sql_modes> on your koha-conf.xml
  $ sudo vim /etc/koha/sites/kohadev/koha-conf.xml
- Restart memcached and Plack:
  $ restart_all
- Run:
 k$ prove t/db_dependent/api/v1/patrons.t
=> FAIL: Tests fail due to updated_on and/or lastseen fields wrong
format (MySQL error)
- Apply this patch
- Run:
 k$ prove t/db_dependent/api/v1/patrons.t
=> SUCCESS: Tests pass! It all makes sense!
- Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21554: Add missing use statement in subscription-batchedit
Jonathan Druart [Fri, 12 Oct 2018 14:27:27 +0000 (11:27 -0300)]
Bug 21554: Add missing use statement in subscription-batchedit

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21475: Fix crash on missing default itemtype
Marcel de Rooy [Mon, 15 Oct 2018 12:01:14 +0000 (14:01 +0200)]
Bug 21475: Fix crash on missing default itemtype

Test plan:
Enable ArticleRequests.
Find book without itemtype (942c). Maybe you need this:
  update biblioitems set itemtype=NULL where biblionumber=[...]
Goto opac detail for that book. No crash anymore?

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20521: Use a specific config for strict sql modes
Jonathan Druart [Thu, 18 Oct 2018 14:07:02 +0000 (11:07 -0300)]
Bug 20521: Use a specific config for strict sql modes

To avoid disrupting testers and new developers it will be turned off by default.

We will turn it on for Jenkins so devs will have to take care of the
regressions they introduce (!)

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21597: Incorrect decimal value: 't_value_bib639' for column 'price'
Jonathan Druart [Wed, 17 Oct 2018 23:24:09 +0000 (20:24 -0300)]
Bug 21597: Incorrect decimal value: 't_value_bib639' for column 'price'

Fix t/db_dependent/selenium/basic_workflow.t

We want to send specific values depending on the data type in DB
For instance integer, or varchar(10)

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21597: Field 'description' doesn't have a default value
Jonathan Druart [Wed, 17 Oct 2018 22:26:32 +0000 (19:26 -0300)]
Bug 21597: Field 'description' doesn't have a default value

Nick proposed another fix, see bug 21594.
The interface does not explode so I do not think we should make a DB
update in a rush.

Fix t/db_dependent/Koha/Object.t and t/db_dependent/Koha/ApiKeys.t

api_keys.description and api_keys.secret:
  `secret` varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL,
  `description` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,

    #   Failed test 'Exception is thrown correctly'
    #   at t/db_dependent/Koha/Object.t line 262.
    # expecting: Koha::Exceptions::Object::FKConstraint
    # found: DBIx::Class::Exception (DBIx::Class::Storage::DBI::_dbh_execute(): Field 'description' doesn't have a default value at /home/vagrant/kohaclone/Koha/Object.pm line 125
    # )
    # Looks like you planned 7 tests but ran 1.
    # Looks like you failed 1 test of 1 run.

and later, but not related:
Can't locate object method "message" via package
"DBIx::Class::Exception" at t/db_dependent/Koha/Object.t line 264.

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21597: Incorrect date value: '0' for column 'onloan'
Jonathan Druart [Wed, 17 Oct 2018 22:21:56 +0000 (19:21 -0300)]
Bug 21597: Incorrect date value: '0' for column 'onloan'

Fix t/db_dependent/Holds/DisallowHoldIfItemsAvailable.t

items.onloan
  `onloan` date DEFAULT NULL,

DBIx::Class::Storage::DBI::_dbh_execute(): Incorrect date value: '0' for
column 'onloan' at row 1 at /home/vagrant/kohaclone/t/lib/TestBuilder.pm
line 288

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21597: Data too long for column 'invitekey'
Jonathan Druart [Wed, 17 Oct 2018 22:18:58 +0000 (19:18 -0300)]
Bug 21597: Data too long for column 'invitekey'

Fix t/db_dependent/Virtualshelves.t

virtualshelfshares.invitekey
  `invitekey` varchar(10) COLLATE utf8mb4_unicode_ci DEFAULT NULL,

We should not insert a longer string!

DBIx::Class::Storage::DBI::_dbh_execute(): Data too long for column
'invitekey' at row 1 at /home/vagrant/kohaclone/Koha/Object.pm line 125

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21597: Field 'amount' doesn't have a default value
Jonathan Druart [Wed, 17 Oct 2018 22:11:29 +0000 (19:11 -0300)]
Bug 21597: Field 'amount' doesn't have a default value

Fix t/db_dependent/Accounts.t

Default value could be 0, or left as it.
It seems that the different initialisation we have in the code pass a
value for 'amount'

account_offsets.amount
  `amount` decimal(26,6) NOT NULL,

DBIx::Class::Storage::DBI::_dbh_execute(): Field 'amount' doesn't
have a default value at /home/vagrant/kohaclone/Koha/Object.pm line 125

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21597: Column 'notforloan' cannot be null
Jonathan Druart [Wed, 17 Oct 2018 22:07:20 +0000 (19:07 -0300)]
Bug 21597: Column 'notforloan' cannot be null

Fix t/db_dependent/Circulation.t

items.notforloan:
  `notforloan` tinyint(1) NOT NULL DEFAULT '0',

t/db_dependent/Circulation.t .. 115/119 DBD::mysql::st execute failed: Column 'notforloan' cannot be null [for Statement "UPDATE `items` SET `notforloan` = ? WHERE ( `itemnumber` = ? )" with ParamValues: 0=undef, 1='1046'] at /usr/share/perl5/DBIx/Class/Storage/DBI.pm line 1832.
        # No tests run!

    #   Failed test 'No tests run for subtest "item-level_itypes = 0"'
    #   at t/db_dependent/Circulation.t line 2356.
    # Looks like you failed 1 test of 2.

 #   Failed test 'CanBookBeIssued | notforloan'
 #   at t/db_dependent/Circulation.t line 2359.
Can't locate object method "rethrow" via package "DBD::mysql::st execute failed: Column 'notforloan' cannot be null [for Statement "UPDATE `items` SET `notforloan` = ? WHERE ( `itemnumber` = ? )" with ParamValues: 0=undef, 1='1046'] at /usr/share/perl5/DBIx/Class/Storage/DBI.pm line 1832.

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21599: Fix item type creation by defining default values
Jonathan Druart [Thu, 18 Oct 2018 11:32:59 +0000 (08:32 -0300)]
Bug 21599: Fix item type creation by defining default values

Same as what we have in Koha::Patron->new, empty strings should not be
inserted in integer or date column type

DBD::mysql::st execute failed: Incorrect decimal value: '' for column 'defaultreplacecost' at row 1 [for Statement "INSERT INTO `itemtypes` ( `checkinmsg`, `checkinmsgtype`, `defaultreplacecost`, `description`, `hideinopac`, `imageurl`, `itemtype`, `notforloan`, `processfee`, `rentalcharge`, `searchcategory`, `sip_media_type`, `summary`) VALUES ( ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? )" with ParamValues: 0="", 1="message", 2="", 3="xx", 4=0, 5='', 6="XX", 7=0, 8="", 9="", 10="", 11=undef, 12=""] at /usr/share/perl5/DBIx/Class/Storage/DBI.pm line 1832.

Test plan:
Create a new itemtype

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21598: 'koha_kohadev.aqbudgets.budget_parent_id' isn't in GROUP BY
Jonathan Druart [Wed, 17 Oct 2018 22:31:14 +0000 (19:31 -0300)]
Bug 21598: 'koha_kohadev.aqbudgets.budget_parent_id' isn't in GROUP BY

DBD::mysql::db selectall_hashref failed:
'koha_kohadev.aqbudgets.budget_parent_id' isn't in GROUP BY [for
Statement "

    at /home/vagrant/kohaclone/C4/Budgets.pm line 558.
and
    at /home/vagrant/kohaclone/C4/Budgets.pm line 565.

Test plan:
hit /cgi-bin/koha/admin/aqbudgets.pl

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21596: Handle empty string for lost when storing a patron
Jonathan Druart [Wed, 17 Oct 2018 23:02:12 +0000 (20:02 -0300)]
Bug 21596: Handle empty string for lost when storing a patron

lost - should default to 0 at DB level, not null
But let fix it as it for now

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21596: Handle empty string for other attributes when storing a patron
Jonathan Druart [Wed, 17 Oct 2018 23:01:47 +0000 (20:01 -0300)]
Bug 21596: Handle empty string for other attributes when storing a patron

lastseen, updated_on => dates
gonenoaddress, login_attempts, privacy_guarantor_checkouts => [tiny]int

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21596: Handle empty string for flags when storing a patron
Jonathan Druart [Wed, 17 Oct 2018 22:53:47 +0000 (19:53 -0300)]
Bug 21596: Handle empty string for flags when storing a patron

Incorrect integer value: '' for column 'flags'

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21596: Handle empty string for date_renewed when storing a patron
Jonathan Druart [Wed, 17 Oct 2018 22:51:50 +0000 (19:51 -0300)]
Bug 21596: Handle empty string for date_renewed when storing a patron

Incorrect date value: '' for column 'date_renewed'

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21593: Remove GROUP BY from GetAuthValueDropbox
Nick Clemens [Thu, 18 Oct 2018 10:05:38 +0000 (10:05 +0000)]
Bug 21593: Remove GROUP BY from GetAuthValueDropbox

With new MYSQL modes we are permitted only full group by.

In this case I don't think we need a GROUP BY at all

To test:
1 - Try to pay a fine or create a borrower
2 - Internal server error
3 - Apply patch
4 - Page should load
5 - Test various authorised values ot ensure they work
   e.g. Set bsort1 and bsort2 to have some authorised values with and
   without branch limits
   set PAYMENT_TYPE to have some values with and without branch limits

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20995: Add Request ID to table and request view
Andrew Isherwood [Tue, 26 Jun 2018 10:36:33 +0000 (11:36 +0100)]
Bug 20995: Add Request ID to table and request view

This patch adds the display of Request ID to the OPAC views of all a
user's requests and the individual request.

To test:

1) Ensure you have ILL enabled
2) Log into the OPAC as a user with at least one request
3) Go to the "your interlibrary loan requests" page
4) TEST: Ensure that Request ID is displayed as the first column in the
table
5) Click the "View" button on a request
6) TEST: Ensure that Request ID is displayed along with all the other
request information

Signed-off-by: mmg@interleaf.ie
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Bug 20995: (QA follow-up) Add html filters and fix doubled up columns from merge

Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21174: (follow-up) Removed MSG_IN_YOUR_CART and its usage in OPAC JS
Jonathan Druart [Tue, 9 Oct 2018 16:38:34 +0000 (13:38 -0300)]
Bug 21174: (follow-up) Removed MSG_IN_YOUR_CART and its usage in OPAC JS

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21174: Removed MSG_IN_YOUR_CART and its usage in OPAC JS
Alex Buckley [Sun, 30 Sep 2018 16:22:10 +0000 (16:22 +0000)]
Bug 21174: Removed MSG_IN_YOUR_CART and its usage in OPAC JS

The 'Items in your cart' message is obsolete with the cart dropdown
box being removed.

Therefore the assignment of this text into the
MSG_IN_YOUR_CART variable (which is done in the opac-bottom.inc), and
the use of the MSG_IN_YOUR_CART variable in the updateBasket() function
(in the OPAC's basket.js) has been removed.

Sponsored-By: Toi Ohomai Institute of Technology, New Zealand
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 21174: Open the OPAC cart with one click by default
Alex Buckley [Sat, 29 Sep 2018 05:24:22 +0000 (05:24 +0000)]
Bug 21174: Open the OPAC cart with one click by default

Feedback from the Koha mailing list in Aug 2018 showed there was
widespread concensus for making the default behaviour of the OPAC cart
to be to open with one click, rather than clicking on the cart icon then
on the dropdown box to load the cart popup.

This commit is a combination of Owen Leonard's alternative patch
(slightly changing the markup in masthead.inc) and my
work to remove the dropdown elements from the template and basket.js

Test plan:
1. In Koha OPAC click on the cart icon (making sure to have items in the
   cart and the dropdown box 'Items in your cart:..' appears.

2. Click this dropdown and the cart popup appears.

3. Confirm you can successfully remove items from and empty the
   cart

4. Apply patch

5. Restart memcached, and plack

6. Click on the cart icon (making sure to have items in the cart) and
   notice no 'Items in your: ..' dropdown appears
   instead the cart popup loads straight away.

7. Confirm the items in your cart are displayed by the cart popup

8. Confirm you can remove items from/empty the cart, and that as you do
   this the number of cart items shown by the number to the right of the
   cart icon changes accordingly

Sponsored-By: Toi Ohomai Institute of Technology, New Zealand
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20351: Shortcut serials scripts if a blocking error appeared
Jonathan Druart [Tue, 8 May 2018 17:25:57 +0000 (14:25 -0300)]
Bug 20351: Shortcut serials scripts if a blocking error appeared

The idea of output_and_exit_if_error (added by bug 18403) is to make sure
parameters are valid before executing the script.
If not (old or broken URLs), we shortcut everything coming next to display a
generic error ("object does not exist", "you do not have permission to do that", etc.)

This bug report fixes the scripts under serials/*.

Test plan:
Hit the script under the serials directory with an invalid subscriptionid parameter
and confirm you get an error instead of the normal view with empty values.

The goal is not to be exhaustive during the first iteration, but at least to fix
the most common views.

For instance:
/cgi-bin/koha/serials/subscription-detail.pl?subscriptionid=XXX
/cgi-bin/koha/serials/serials-collection.pl?subscriptionid=XXX
/cgi-bin/koha/serials/routing.pl?subscriptionid=XXX&op=new
/cgi-bin/koha/serials/subscription-add.pl?op=modify&subscriptionid=XXx
/cgi-bin/koha/serials/subscription-add.pl?op=dup&subscriptionid=XXX

Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Signed-off-by: Séverine QUEUNE <severine.queune@bulac.fr>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
5 years agoBug 20521: Enable problematic SQL modes for dev installs
Jonathan Druart [Wed, 4 Apr 2018 19:28:53 +0000 (16:28 -0300)]
Bug 20521: Enable problematic SQL modes for dev installs

So far we have bug 17258 (omnibus to list the issue we have with the new
default SQL modes), bug 20144 (which fixed our test suite with these
modes) and bug 20229.
This last one forces the SQL modes to avoid to modify the DBMS
configuration and define the SQL modes we support.

We should let developers catch the issues and report/fix them.
Also Jenkins must alert us if there is a regression with the test suite.

I suggest to enable the problematic SQL modes on dev installs.

Test plan:
- Revert commit 0180524bb9b1464c441bb1b858d0d8df37524d72
- prove t/db_dependent/Koha/Biblios.t

=> If you have dev_install defined in your Koha config file, the test
will fail with "Field 'datecreated' doesn't have a default value"
=> If you do not have dev_install, the tests will pass

NOTE: The commit number was wrong. Using
    git log -- t/db_dependent/Koha/Biblios.t
    This showed bug 20176 which was 524eab678833b2719187e67128ee4f83a2a48ba4
    Also dev_install was in koha_conf.xml already, so I just had to
    toggle 0 and 1.

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>