koha.git
6 years agoAdd release notes for Koha 16.11.09 v16.11.09
Koha instance kohadev-koha [Thu, 22 Jun 2017 09:34:33 +0000]
Add release notes for Koha 16.11.09

6 years agoIncrement version for 16.11.09 release
Koha instance kohadev-koha [Wed, 21 Jun 2017 10:58:58 +0000]
Increment version for 16.11.09 release

6 years agoFix pl-PL translation
Katrin Fischer [Wed, 21 Jun 2017 10:53:28 +0000]
Fix pl-PL translation

6 years agoTranslation updates for Koha 16.11.09
root [Wed, 21 Jun 2017 21:17:23 +0000]
Translation updates for Koha 16.11.09

6 years agoBug 17710 - C4::Matcher::get_matches and C4::ImportBatch::GetBestRecordMatch should...
David Cook [Wed, 11 Jan 2017 04:36:05 +0000]
Bug 17710 - C4::Matcher::get_matches and C4::ImportBatch::GetBestRecordMatch should use same logic

C4::ImportBatch::GetBestRecordMatch uses SQL to sort by score descending
then candidate_match_id descending. With C4::Matcher::get_matches, I
implement the same sort but use Perl code to do it, since we're sorting
search results.

It's a simple change, but it's in a big block of code, so I don't have
unit tests.

Signed-off-by: Alex Buckley <alexbuckley@catalyst.net.nz>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 6906b848a78ad4c7d52c1e7c7ce195f08cc6d2a6)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 50c886e0a96a39a2906756dae42ade5c9fd0f9d0)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18762: Remove some warnings from Search.t
Jonathan Druart [Thu, 8 Jun 2017 19:11:45 +0000]
Bug 18762: Remove some warnings from Search.t

Note that some are caused by CGI, see bug 18632

Test plan:
Confirm there are less warnings with this patch applied

Signed-off-by: Lee Jamison <ldjamison@marywood.edu>

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
(cherry picked from commit 6d78d7a6108afc75546f933d601b04fde8b76c9b)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit f7bcec64644ea76aa3bff71fec41fb57d4442c13)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18762: Remove a warning from History.t
Jonathan Druart [Thu, 8 Jun 2017 18:36:40 +0000]
Bug 18762: Remove a warning from History.t

Test plan:
  prove t/db_dependent/Search/History.t
should not display any warnings

Signed-off-by: Lee Jamison <ldjamison@marywood.edu>

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
(cherry picked from commit 15f9e830ece26b5eead340e67b8d05b4bd07e930)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 5c0e28d092730e8402739588f159e5607d518a6f)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18762: Remove warnings from xt/author/valid-templates.t
Jonathan Druart [Thu, 8 Jun 2017 18:35:02 +0000]
Bug 18762: Remove warnings from xt/author/valid-templates.t

Test plan:
Read the changes and make sure they make sense

Signed-off-by: Lee Jamison <ldjamison@marywood.edu>

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
(cherry picked from commit ab29b5efdc763269399c06aa62ac0a36a93152f8)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 9cd4fc3703de5882de8986d364221f9134aaaa80)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18761: Fix tests for AutomaticItemModificationByAge.t - clear cache
Jonathan Druart [Thu, 8 Jun 2017 17:17:53 +0000]
Bug 18761: Fix tests for AutomaticItemModificationByAge.t - clear cache

The mapping structure is cached and may be wrong if already populated.
We need to clear the cache when a framework is modified

Signed-off-by: Lee Jamison <ldjamison@marywood.edu>
Works as described in test plan and passes QA tools.

(cherry picked from commit c3a115916146e7c1e98c58c0b0a429e9841af461)
(cherry picked from commit a44c0f82712a1e9492b0604711fdaebdcfd345b2)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18601: OAI/Sets.t mangles data due to truncate in ModOAISetsBiblios
Marcel de Rooy [Mon, 15 May 2017 07:58:04 +0000]
Bug 18601: OAI/Sets.t mangles data due to truncate in ModOAISetsBiblios

This patch replaces the TRUNCATE statement in ModOAISetsBiblios by a
DELETE statement. A truncate will cause an implicit commit and will
therefore commit the transaction started in the test script.

Also simplifying the module load in the test script.

Test plan:
Do not apply this patch and observe that biblio records are added to your
database by running t/db_dependent/OAI/Sets.t.
Apply this patch, run the test again and verify that it does no longer
add records to your biblio table.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit e0444e8600efbe06016ff857f23ea85893a93041)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 28928c69376fd25edaee8a7843dc4fd4309f0615)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18752 - Automatic item modifications by age should allow 'blank' values
Owen Leonard [Thu, 8 Jun 2017 15:19:22 +0000]
Bug 18752 - Automatic item modifications by age should allow 'blank' values

This patch modifies the automatic item modification by age template to
correct errors in form validation:

- Age in days should not be required
- A value should not be required in substitutions.

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

- Go to Tools -> Automatic item modification by age.
- Confirm that when editing or creating a rule the only required field
  is the substitutions field name.

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 1bc45a470e55bcbb5e4031c001749a1ec9b35160)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 8c782759ef2ff01a5e125c05f998a3a678346455)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18584: Fix trailing spaces in C4/Accounts.pm
Lee Jamison [Sat, 10 Jun 2017 09:26:51 +0000]
Bug 18584: Fix trailing spaces in C4/Accounts.pm

Removed trailing spaces at line 182 of C4::Accounts.

Test plan:
1. Edit C4/Accounts.pm and verify trailing spaces
2. Apply patch
3. Verify that trailing spaces in C4/Accounts have been removed

Signed-off-by: Lee Jamison <ldjamison@marywood.edu>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit a80ed84d070f81065b1fb2fa14f5ced3c25d6431)
(cherry picked from commit abc32e9099376b6f6c9ffed8033e8e041c4cec68)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18694: Translatability: Get rid of exposing [%% FOREACH in csv/cash_register_stats.tt
Marc Véron [Tue, 30 May 2017 06:41:53 +0000]
Bug 18694: Translatability: Get rid of exposing [%% FOREACH in csv/cash_register_stats.tt

Code exposed is:
%s %s %s [%%- FOREACH field IN row; field IF !loop.last; ItemTypes.GetDescription(field) IF loop.last; sep IF !loop.last; END %%] %s TOTAL [%%- FOREACH field IN total; field; sep IF !loop.last; END %%]

Similar for: csv/orders_by_budget.tt

To test:
- Apply patch
- In staff client, verify that Cash register statistics work as before
  (Home > Reports > Cash register statistics)
- Verify the same for Home > Reports > Orders by fund (triggers orders_by_budget.tt)
- Bonus test: Create a "language" aa-AA (perl translate create aa-AA
  from folder misc/translator, verify that lines mentioned above do
  no longer appear in aa-AA-staff-prog.po )
- Run QA tools (newest version with test for newlines in tt directives)

Rebased on top of Bug 18734 2017-12-06 / mv

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit ec478e18f352d340c7a1ec4416121928229c2907)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 3db92ec25a91cfb9342da4d5b433601fa08bbb75)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18734 - Internal server error in cash_register_stats.pl when exporting to file
Nick Clemens [Fri, 9 Jun 2017 14:17:25 +0000]
Bug 18734 - Internal server error in cash_register_stats.pl when exporting to file

To test:
Output cash reigster stats report to file
Internal server error
Apply patch
Export to file
File is generated and correctly formed

Signed-off-by: Marc Véron <veron@veron.ch>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 855ff0fb9a1cf7755a0805910c367150b37b5f2a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 8e1cfdbd07bf0dceab147ab5df417d7deedaada8)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18656 - Require confirmation of deletion of files from patron record
Owen Leonard [Wed, 24 May 2017 13:46:50 +0000]
Bug 18656 - Require confirmation of deletion of files from patron record

This patch adds a JavaScript confirm to the deletion of files. It also
styles the file deletion link as a Bootstrap button.

To test, apply the patch and open the "Files" page for a patron who has
files attached.

- Verify that clicking any "delete" link prompts for a confirmation.
- Verify that confirming the dialog triggers the deletion of the correct
  file.
- Verify that canceling the confirmation dialog aborts the deletion.
- Confirm that the "Delete" button looks correct.

Signed-off-by: David Roberts <david.roberts@ptfs-europe.com>

Revision for QA: Replaced '.click(function' with '.on("click",function'

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit a38ffe2d48c35029ef80ea0a4294e36b408cd1a4)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 2bc4791dedc9d266b7aa3a121e62af2dc78354e2)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18773: Fix failing history.t test
Mark Tompsett [Fri, 9 Jun 2017 22:52:17 +0000]
Bug 18773: Fix failing history.t test

changed get() to get_ok() and increased test count to match.
Now the master build will only fail on search_utf8.t

TEST PLAN
---------
assuming KOHA_CONF is set.
$ export KOHA_INTRANET_URL=...
$ export KOHA_OPAC_URL=...
$ prove -v t/db_dependent/www/history.t

run koha qa test tools

Signed-off-by: Lee Jamison <ldjamison@marywood.edu>
Works correctly using text plan provided and passes QA tools.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 25bbc181c9ceacd84582368f0006d4025250ea1f)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 5c5290eb31efe31fe189b2f17f95741e02d00667)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18411: Fix failing search_utf8.t tests
Mark Tompsett [Fri, 9 Jun 2017 23:23:49 +0000]
Bug 18411: Fix failing search_utf8.t tests

TEST PLAN
---------
export KOHA_INTRANET_URL=...
prove -v t/db_dependent/www/search_utf8.t

something like seen before failure:
t/db_dependent/www/search_utf8.t .. 9/66 Error GETing http://koha_16_11:8080/cgi-bin/koha/tools/background-job-progress.pl?jobID=741d649f9d4472fe75f30761ba2488c0: Bad Request at t/db_dependent/www/search_utf8.t line 170.

apply this patch
prove -v t/db_dependent/www/search_utf8.t

Now it is the marc staging that is failing.
And that is failing in master for me.
So, I don't think it is the test that is a problem at this point,
but the actual staged marc records process.

Signed-off-by: Lee Jamison <ldjamison@marywood.edu>
I'm not sure why you had problems. All 66 tests passed
after patch application and the patch also passes QA Tools.
I tested this patch on a brand new kohadevbox without issue.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit bd14d2db9c6f6ac34a1dc0ea4ab741c05c22e5d3)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 1b228a9a29ac07518ed9f5054de22e2fb3e4a269)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18706 - Remove useless Javascript
Fridolin Somers [Wed, 31 May 2017 14:10:41 +0000]
Bug 18706 - Remove useless Javascript

Whe checking a subfield to be deleted, the code
  $(this).val($(this).siblings("[name='subfield']").val());
is useless, the checkbox already contains the subfield code :
  <input type="checkbox" ... name="disable_input" value="[% ite.subfield %]" />

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 6bb4a0405abe0d03be3915644c6a05e2e3ee1e9f)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 7bf1bf36f4b075979e4e47beb5de0891a1f1e533)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18706 - subfields to delete not disabled anymore in batch item modification
Fridolin Somers [Wed, 31 May 2017 14:02:44 +0000]
Bug 18706 - subfields to delete not disabled anymore in batch item modification

In Tools > Batch item modification, one can click a checkbox to delete a subfield.
This click use to disable the input to change the field value.

This comes from the patch : Bug 13501: Move "Required" and checkbox after input/select
Because input is found using JQuery next().

This patch replaces with $(this).parent().find("[name='field_value']").

Test plan :
- Go to Tools > Batch item modification
- Enter a barcode and submit
- Click on a checkbox on a non-mandatory subfield
=> Without patch the input or select is not disabled
=> With patch the input or select is disabled
- Submit
=> Check that subfield is deleted

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 7c9273be169ca4da47059aa152f8c6ea11137a52)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit dc1f51959ad1b7a5e7ca7e6259e0e42cc6260643)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18716: Remove CGI::param warns from updatesupplier.pl
Tomas Cohen Arazi [Fri, 2 Jun 2017 02:52:07 +0000]
Bug 18716: Remove CGI::param warns from updatesupplier.pl

This script floods the logs with this kind of warnings.

To test:
- Run:
  $ koha-plack-err
- Edit a vendor in the acquisitions module
- Save
=> FAIL: Logs show lots of warnings that look like:
 CGI::param called in list context from package CGI::Compile::ROOT::home_vagrant_kohaclone_acqui_updatesupplier_2epl
- Apply this patch
- Run:
  $ restart_all
  $ koha-plack-err
- Edit a vendor, add/delete vendor contacts
=> SUCESS: No more warnings
- Verify editing and storing vendor contacts works as expected.
- Sign off :-D

Signed-off-by: Marc Véron <veron@veron.ch>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit c35932923407e9ec088957f877e8607289b6b914)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 9c2d9c89a437605308ebf58d45fca858a3f56593)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18767: Remove useless diags from GetDailyQuote.t
Tomas Cohen Arazi [Fri, 9 Jun 2017 14:16:08 +0000]
Bug 18767: Remove useless diags from GetDailyQuote.t

This tests print useless debugging info.

To test:
- Run:
  $ sudo koha-shell kohadev
 k$ cd kohaclone
 k$ prove t/db_dependent/Koha/GetDailyQuote.t
=> FAIL: Some output telling what is doing on each step is printed.
- Apply the patch
- Run
 k$ prove t/db_dependent/Koha/GetDailyQuote.t
=> SUCCESS: No output, YAY!
- Sign off :-D

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 78a9f39f9a97179af3e3a38cf8cb17b3f043d88a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 4def0870d85975c4e926fb62dbc2a9db2807ae20)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18727: System preferences loose part of values because of double quotes
Marc Véron [Mon, 5 Jun 2017 04:52:58 +0000]
Bug 18727: System preferences loose part of values because of double quotes

System preferences do not display values of text fields properly if they
contain doulbe quotes.

To recreate:
- Go to Home > Administration > System preferences , then tab Acquisitions
- Enter values to both system preferences like proposed in the example (o=5|a="bar foo" and  o=5|a="foo bar")
- Save
- Click on tab Acquisitions to reload
- Wrong result: Both preferences show a value of: o=5|a=
  (parts with double quotes are truncated)

- Edit any of the email addresses (Bug 9814):
  KohaAdminEmailAddress, NoticeBcc, ReplytoDefault, PayPalUser
- Set value to: "The Library" <thelibrary@example.com>
- Search for this email address syspref to re-display it
- Wrong result:
  Use [     ] " autocomplete="off" /> as the email address for the
  administrator of Koha.

To test:
- Apply patch
- Try to recreate issues above
- Additionally, edit other system preferences that could contain double
  quotes, e.g. LibraryName or UsageStatsLibraryName
- Set value to: Bibliothek "Zur Leseratte"

(Note: patch contains a tiny fix for a typo in acquisitions.pref)

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 6e7c125a56be8971ec9c9bb52373bff5004a936a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit c5fcadf128e84c2a5deae5209b04fa82559845fb)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18689: calendar error with double quotes in title or description of holiday
Marc Véron [Sun, 4 Jun 2017 16:04:00 +0000]
Bug 18689: calendar error with double quotes in title or description of holiday

This patch fixes the calendar display with holidays having double qoutes in
title or description.

To test:
- Apply patch
- Go to Home > Tools > Calendar
- Create new holidays of each type (Day only, repeated wekly/yearly,
  range, yearly repeated range and enter double qoutes in their titles and
  descriptions
- Verify that calendar displays and works as expected
- Verify that you can edit the holidays

Signed-off-by: Lee Jamison <ldjamison@marywood.edu>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit f1d90f205e3dc8177c0d524b208d9d4a367cf56e)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 0f20a2c97acb04e137db35499f0c46d27d57bf0c)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18722: Fund name is not shown in received orders fund subtotals
Josef Moravec [Mon, 5 Jun 2017 11:20:18 +0000]
Bug 18722: Fund name is not shown in received orders fund subtotals

Test plan:
1) Go to acquisition and receive some orders
2) Show the receive summary for invoice
--> without patch, the fund name in subtotal is not shown
--> with patch the name is shown as expected

Signed-off-by: Michael Cabus <michael@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 6a2ef935ac63c67a4b31d8c3eb9bcb8d974d844e)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit b0cb001e83a7810233e488f99b67fae7c4776918)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18730: Batch Mod Edit <label> HTML validation fails
Mark Tompsett [Mon, 5 Jun 2017 16:24:07 +0000]
Bug 18730: Batch Mod Edit <label> HTML validation fails

[tag] [reply] [−] Description M. Tompsett 2017-06-05 16:30:21 UTC
Know the barcode of an existing item.
Home -> Tools -> Batch Item Modification
Enter the barcode
Click
View Page source
select and copy it into validator.w3.org direct input.
There will be complaints about <labels>.

Apply this patch

refresh the page.
select and copy it into validator.w3.org direct input.
There will be no complaints about <labels>.

This is intended to be a highly focused HTML bug, as the
missing form tag which will fix the <div> issues at the bottom
is corrected on bug 18710.

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
(cherry picked from commit eb0a67ea10c9210dbfb42f810c280b7515b04a16)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit d6c6392440396a3c4a9832e2bd924844ba87378b)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18746: Add license and remove diag
Jonathan Druart [Fri, 9 Jun 2017 13:21:33 +0000]
Bug 18746: Add license and remove diag

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit fcec2c71b4e362ffa7e1a443cdff9ace91761b9d)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 81f849d6da8c42983eaaee6113fd1255c4b841b1)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18746: Text_CSV_Various parse failures
Mark Tompsett [Wed, 7 Jun 2017 22:07:13 +0000]
Bug 18746: Text_CSV_Various parse failures

While it might be an idea to just delete it,
this patch attempts to catch everything and make it
clear that Text::CSV::Unicode (binary) is the parser
that should be used.

Signed-off-by: Lee Jamison <ldjamison@marywood.edu>
Running 'prove xt/author/Text_CSV_Various.t' passes

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 89d36585bb3483ac46c87224391b6867ae8468bb)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit d3ccdd1df3eda8c933cbc841532a0000707cc9e2)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18641 - Translatability: Get rid of template directives in translations for ...
Marc Véron [Sat, 20 May 2017 07:18:10 +0000]
Bug 18641 - Translatability: Get rid of template directives in translations for *reserves.tt files

Template directives should not be exposed in translation, but lines like the following pop up in the translation tool:
Cancel [% IF TransferWhenCancelAllWaitingHolds %]and Transfer [% END %] All

This patch fixes it.

To test:
- Apply patch
- Verify that code changes make sense
- Verify that submit buttons of pendingreserves.tt and waitingreserves.tt
  still work and display the same string as before

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Bug 18641: (RM-followup) for waitingreserves.tt

Code changed for waitingreserves.tt as asked for in comment #7

Bug 18641: Followup for pendingreserves.tt (less %s)

Change as of comment #13 to reduce %s

After creating a new translation for a "language" aa-AA, we have
the following in the file aa-AA-staff-prog.po

msgid ""
"(Inclusive, default is %s days ago to %s days ahead. Set other date ranges "
"as needed.)"
msgstr ""

msgid ""
"(Inclusive, default is %s days ago to today. Set other date ranges as "
"needed.)"
msgstr ""

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 78b30baf3fa975ab9eabc58733a2252b08d22f25)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 485f2cdc7e44b16c90c9c6ba5a9861751e31c215)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18759: (follow-up) Try to fix random failure from Circulation.t
Jonathan Druart [Fri, 9 Jun 2017 13:08:37 +0000]
Bug 18759: (follow-up) Try to fix random failure from Circulation.t

If IndependentBranches, CanBookBeRenewed will set ITEMNOTSAMEBRANCH
or BORRNOTSAMEBRANCH flags, if the branches do not match.

(cherry picked from commit 1577460c713e3ac7e602dce81738f974e86ddf9d)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit d45bc6ad530bc28b3065818e1fbd29c75af43cce)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18759: Try to fix random failure from Circulation.t
Jonathan Druart [Thu, 8 Jun 2017 14:54:18 +0000]
Bug 18759: Try to fix random failure from Circulation.t

Circulation.t is failing randomly on our CI
https://jenkins.koha-community.org/job/Koha_Master_D8/192/console

    #   Failed test at t/db_dependent/Circulation.t line 1147.
    #          got: '1'
    #     expected: '0'

    #   Failed test at t/db_dependent/Circulation.t line 1152.
    #          got: '1'
    #     expected: '0'

    #   Failed test at t/db_dependent/Circulation.t line 1156.
    #          got: '1'
    #     expected: '0'

    #   Failed test at t/db_dependent/Circulation.t line 1170.
    #          got: '1'
    #     expected: '0'

    #   Failed test at t/db_dependent/Circulation.t line 1184.
    #          got: '1'
    #     expected: '0'
    # Looks like you failed 5 tests of 23.

Sometimes one of the alert or impossible flags is set.
This patch guesses that it's because of the 'restricted' value of the item that is evaluated to 1.
If it is not fixed by this patch, we will have more info next time (at least know
if alert or impossible is set).

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
The fix is trivial. Using random data will lead to this situations. The good thing is that
it lets us spot places in which tests need more fine-grained data.

(cherry picked from commit 9a55f5783c91b92cb8518f423ab23bd9727051ee)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 178ecea26000f6c3b8b16630ac6f13277d828d68)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18675: Translatability: Get rid of [%% in translation for csv-profiles.tt
Marc Véron [Fri, 26 May 2017 09:06:56 +0000]
Bug 18675: Translatability: Get rid of [%% in translation for csv-profiles.tt

Translation tool for file csv-profiles.tt picks following line:
%s [%% IF csv_profile.encoding == encoding OR NOT csv_profile AND encoding == 'utf8' %%]
It is is due to a line break inside a template directive. This patch removes it.

To test:
- Verify that code change makes sense
- Apply patch
- Verify that csv exports behave as before

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit dd9da3e8f64ac4eb8fde5a1a58e0d692542ce2e6)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit e464f291b8793909400d9f44d0b297d5bee238d7)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18690 - Typos in Koha database description (Table "borrowers")
Marc Véron [Mon, 29 May 2017 18:13:03 +0000]
Bug 18690 - Typos in Koha database description (Table "borrowers")

This string patch fixes typos in kohastructure.sql as described in initial
comment.

To test:
- Carefully verify that string changes make sense

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 279126d710233f7925432ab1f8fa6ae9f947889e)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 7ff2fd6e9a3bcd40e22a4f69c5c303fe0f7d1706)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18681 - (followup) Remove on more [%% in translation for about.tt
Marc Véron [Tue, 30 May 2017 07:37:02 +0000]
Bug 18681 - (followup) Remove on more [%% in translation for about.tt

Test plan same as in previous patch
Run QA tools in newest version (test for line breaks in tt directives)

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 880c2e19c3c5f10f110fd80a44f0d111b9d05472)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 3fa60aaf969962f5d184c2fdff2dc4c37bfbe5c5)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18681: Translatability: Get rid of [%% in translation for about.tt
Marc Véron [Fri, 26 May 2017 17:11:59 +0000]
Bug 18681: Translatability: Get rid of [%% in translation for about.tt

Translation tool picks a line
%s [%% IF warnPrefBiblioAddsAuthorities || warnPrefEasyAnalyticalRecords ||
...due to a line break inside a template directive.
This patch fixes it.

To test:
- Update QA tools
  (see https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18675#c2)
- Verify that code change makes sense
- Apply patch
- Run QA tools

Followed test plan and everything was as intended
Signed-off-by: Alex Buckley <alexbuckley@catalyst.net.nz>

Signed-off-by: Alex Buckley <alexbuckley@catalyst.net.nz>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 1c8c84f4be8665d95ededf5174c406e1a63d6529)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit e90f5494f36f8af9dad5659d0220656767a9bbb3)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18695: Translatability: Get rid of [%% INCLUDE in translation for circulation.tt
Marc Véron [Tue, 30 May 2017 08:47:48 +0000]
Bug 18695: Translatability: Get rid of [%% INCLUDE in translation for circulation.tt

The file circ/circulation.tt exposes the following line to translation:
%s %s [%% INCLUDE 'blocked-fines.inc' fines = chargesamount %%] %s %s
Translators should not be confronted with code internals.

This patch fixes it by removing a line break.

To test:
- Verify that code change makes sense
- Run QA tools in newest version (check for line breaks in tt directives)
- Bonus test: Create a "language" aa-AA (perl translate create aa-AA
  from folder misc/translator, verify that line mentioned above do
  no longer appear in aa-AA-staff-prog.po )

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit c5726913774ed25c4125e65a12054a00c2f7dd76)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 6a3477b2cc5d67adc51dae81a0c953f4923b1d99)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18693: Translatability: Get rid of exposing a [%% FOREACH loop in translation...
Marc Véron [Tue, 30 May 2017 05:13:31 +0000]
Bug 18693: Translatability: Get rid of exposing a [%% FOREACH loop in translation for branch-selector.inc

The file branch-selector.inc exposes the following line to translation
(due to newlines insied a tt directive):
%s %s [%% FOREACH branch IN branches; IF branch.selected; selectall = 0; END; END %%]

Additionally, export.tt exposes the following line to translation:
[%% INCLUDE 'branch-selector.inc' branches = libraries %%]

To test:
- Apply patch
- In Staff client, go to Home > Tools > Export data
- Verify that library selection behaves as before
- Bonus test: Create a "language" aa-AA (perl translate create aa-AA
  from folder misc/translator, verify that lines mentioned above do
  no longer appear in aa-AA-staff-prog.po
- Run QA tools (newest version with test for newlines in tt directives)

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 0ee3249438b85cb47aa9ff623bac4f405df7161f)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit b6f5f0331d6ea8b472a1e06b54d787482f4ae88d)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18644: Translatability: Get rid of pure template directives in translation for...
Marc Véron [Tue, 30 May 2017 09:23:20 +0000]
Bug 18644: Translatability: Get rid of pure template directives in translation for memberentrygen.tt

Translation for memberentrygen.tt exposes a lot of template directives
like the following:
[% UNLESS opduplicate %][% othernames | html %][% END %]
Translators should not be confronted with such code internals.

To test:
- Review code changes
- Verify that creating / editing patrons works as before
- Bonus test: Create a "language" aa-AA (perl translate create aa-AA
  from folder misc/translator, verify that lines like mentioned above
  do no longer appear in aa-AA-staff-prog.po

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 5a30dea05b158fd6a77b0495ee047310865072eb)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 649cdbb91bffb37b0ea4958e80b55975ddce65bb)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18682 - Translatability: Get rid of [%% in translation for 2 files av-build-dropb...
Marc Véron [Tue, 30 May 2017 12:27:56 +0000]
Bug 18682 - Translatability: Get rid of [%% in translation for 2 files av-build-dropbox.inc

Two files av-build-dropbox.inc has linebreaks inside template directives,
 exposing internals (comments and tt code) to translations as mentioned
in initial comment.
Translators should not be confronted with such interal code.

This patch fixes it.

To test
- Verify, that code changes make sense and have no more line breaks insied
  tt directives.
- Run QA tools in newest version (checking for line breaks inside tt
  directives)
- Bonus test: Create a "language" aa-AA (perl translate create aa-AA
  from folder misc/translator, verify that lines mentioned above do
  no longer appear in aa-AA-staff-prog.po and in aa-AA-opac-bootstrap.po

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 953504a0769a38a60f379a2e9c72bf7b71814fd0)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 9db81e5ead064b21394c75ee9746cd825ec9954f)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18701: Translatability: Get rid of exposed tt directives in matching-rules.tt
Marc Véron [Tue, 30 May 2017 15:50:57 +0000]
Bug 18701: Translatability: Get rid of exposed tt directives in matching-rules.tt

Translation for file matching-rules.tt exposes a lot of template directives.

Translators should not be confronted with internal code like the following:

[%% PROCESS norms_select selected_norm=\"none\" id=\"mc_1_src_c_1_n_1_norm\" "name=\"mc_1_src_c_1_n_1_norm\" %%]

To test:
- Apply patch
- Verify that code changes make sense (removes line breaks in directives)
- Run QA tools in newset version (tests for line breaks in tt)
- Bonus test: create a new translation e.g. fpr language 'aa-AA', verify
  that such lines no longer appear in po/aa-AA-staff-prog.po
  (for matching-rules.tt)

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 1a023a670c1bf0faffe51faefc42fdd6407c2320)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 884467bf481a4c77d0dae5a7add47ebc828f17ce)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18648: Restore hyphen
Jonathan Druart [Fri, 9 Jun 2017 16:24:07 +0000]
Bug 18648: Restore hyphen

(cherry picked from commit 6999dbafbd2d6708d4c3a8fae7e83855902ebdbb)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 7a181f3e912663ff642ba8dc569416ad4598ca26)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18648: Fix syntax 'unexpected end of input'
Jonathan Druart [Tue, 6 Jun 2017 14:06:29 +0000]
Bug 18648: Fix syntax 'unexpected end of input'

(cherry picked from commit 023b0890a25d1420a0f4ecb28d54c08a06e6479e)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit fae5977438c23ed2fd4a0f4eeb395729a77cae97)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18648: Translatability: Get rid of tt directives in translation for macles.tt
Marc Véron [Tue, 30 May 2017 19:10:32 +0000]
Bug 18648: Translatability: Get rid of tt directives in translation for macles.tt

koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/macles.tt contains
template directives inside a div tag:
<span title="[% FOREACH lib IN cell.libs %][% lib.lib |html %] - [% END %]">
This is exposed in translation tool.

To test:
- Carefully examine code changes
- Apply patch, verify that the directive is no longer exposed (picked for
  po files), e.g. by creating a new "language" aa-AA and examing aa-AA-staff-prog.po
- If you know where / how this macles is used, verify that it behaves as before

(Note: New patch, needs new sign off)

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 00d3a883b5e4d2ff1f5badef3c5dc33d7913bebe)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit e7cf94446e1c6ff413bb8d725f9c6cbf2e9adca9)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 13747: Fix problems with frequency descriptions containing quotes
Marc Véron [Sun, 4 Jun 2017 20:09:14 +0000]
Bug 13747: Fix problems with frequency descriptions containing quotes

If a serial frequency description contains quotes or is surrounded by
quotes, the description is empty ("TEST" > empty) or shown without the
quotes part (TEST "sth" > TEST) on editing the frequency.

To verify:
- Create a new frequency with description: "Test"
- Modify frequency
- Verify the description field is empty

To test:
- Apply patch
- Try to recreate, verify that the description field is
  correctly filled when editing
- Test also with a name like: 'A "souble quoted" name'

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 16307c40343cdb0ed4ff69c9c001fc4d9e1a459f)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 17df2459ddc294eb2499fce6d9f6f32d20e6db67)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18653: Possible privacy breach with OPAC password recovery
Marc Véron [Tue, 23 May 2017 05:08:41 +0000]
Bug 18653: Possible privacy breach with OPAC password recovery

OPAC password recovery allows to find out which email address belongs to an account. An attacker could systematically guess login names. If they hit an existing one, OPAC displays a message like:
An email has been sent to "xxx@yyy.zz".

Having a combination of login name and email, attackers could use the information e.g. for phishing or other personalized actions.

To reproduce:
- Enable OPAC password recovery (syspref OpacResetPassword)
- 'Guess' a login name e.g. by using a common pattern like ptester for Peter Tester
- If such account exists, you get to know the related email address

This patch removes the email address from the success message. Additionaly, it changes
wording to address Bug 18570 ('will be sent' instead of 'has been sent')

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Simplified the wording. "Will be sent shortly" is used elsewhere too.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit eddf975cf0244c731f987c64af5126090f73f9f2)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 2d1dad1a4afa1bfaa14715b7953ed8265dbdb398)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 13913 - Renewal error message in OPAC is confusing
Owen Leonard [Sat, 29 Apr 2017 17:14:10 +0000]
Bug 13913 - Renewal error message in OPAC is confusing

This patch adds some formatting to the error message a patron receives
when there are renewal failures in the OPAC.

This is pretty much the least which could be done to address this
problem. However, I don't think the issue can be fixed without
re-thinking how renewals are processed. Sending error messages back to
opac-user.pl via URL parameter isn't flexible enough.

To test, apply the patch and attempt to renew multiple items in the OPAC
which cannot be renewed for some reason, for instance because they have
been renewed too many times. The error messages should appear in a list
rather than strung together in one long block of text.

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>
(cherry picked from commit 281e1253777d2bd635610075fe610bedb2d47360)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 14e8f5bb713bd4f45a85f028e0c9b5738f3eefd5)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Changed borrower back to patron as it was before this patch.

6 years agoBug 11122: Follow up - Fix some display issues and typos
Katrin Fischer [Mon, 1 May 2017 23:08:02 +0000]
Bug 11122: Follow up - Fix some display issues and typos

This patch fixes the display of copyrightdate for MARC21 installations.
As MARC21 already requires you to add punctuation in cataloguing, there
is usually no need for punctutation in the templates.

Also fixes a template variable name typo and the basket summary page.

To test (all 3 patches):
- Add several order lines to an order, one should be uncertain
- Verify that the publisher and publication year are displayed
- Check the uncertain price page
- Verify that the publisher code and publication year are displayed
- Fix uncertain price and close your order
- Basket summary: Verify... (you know what)
- Cancel one of your orders
- Verify... for cancelled orders
- Receive shipment
- Verify... for unreceived orders
- Receive order
- Verify ... for received orders
- Finish receiving
- Verify ... on the invoice summary page

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

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

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit cbb5096934907ec56df27d6ee3e77d752cd5e401)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 428467a0228429ba78020e9097ede7c43ad6d04e)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 11122: Address MARC21 vs. UNIMARC issue
Mark Tompsett [Mon, 20 Apr 2015 00:28:21 +0000]
Bug 11122: Address MARC21 vs. UNIMARC issue

In comment #6 and comment #17, Katrin pointed out the discrepancy
between UNIMARC (using publisheryear) vs. Other MARC installations
(using copyrightdate). This was dealt with in invoice.tt already.
This patch does similar logic for the other 3 template files.

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

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

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

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit c470b3e38486e3c6040a10f6b0bf90af069f4566)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 003e52896eeb74ca8c9d9ea253eff4f6022e52c0)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 11122 - publisher code and publication year not fetched in acq orders
Fridolyn SOMERS [Wed, 23 Oct 2013 10:05:23 +0000]
Bug 11122 - publisher code and publication year not fetched in acq orders

In acquisition, several templates try to display publisher code and publication year : invoice.tt, parcel.tt, transferorder.tt.
Thoses pages use C4::Acquisition methods GetPendingOrders or GetInvoiceDetails.
The bug is that in the SQL query of those methods, biblioitems.publishercode and biblioitems.publicationyear.
In uncertainprice.pl those datas are fetch using GetBiblioData.
It whould be better to fetch them in GetPendingOrders and GetInvoiceDetails.

This patch changes SQL queries to fetch wanted datas : aqorders.*,biblio.title,biblio.author,biblioitems.isbn,biblioitems.publishercode,biblioitems.publicationyear. GetInvoiceDetails also needs : biblio.seriestitle,biblioitems.volume.
This patch also unifies the way biblio datas are displayed :
  <a href="link to catalog using biblionumber">[title]</a> <em>by</em> [author] &ndash; [isbn]
  <em>Publisher:</em> [publishercode], [publicationyear]

Test plan :
- Choose a biblio record containing a data in :
    biblio.title,
    biblio.author,
    biblioitems.isbn,
    biblioitems.publishercode,
    biblioitems.publicationyear,
    biblio.seriestitle,
    biblioitems.volume.
- Create an order using this biblio.
- Look at this order in pages : parcel.pl, transferorder.pl, uncertainprice.pl
=> You see publisher code and publication year
- Look at this order in page : invoice.pl
=> You see publisher code, publication year, series title and volume

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

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

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

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit c59e395b749132080fefb81e5b12f8c0b6654665)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 44a80fe0665c0d375faf6b5bded8a2fe96b5ff24)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18700 Fix grammar (data cannot be pluralized)
Colin Campbell [Tue, 30 May 2017 14:17:58 +0000]
Bug 18700 Fix grammar (data cannot be pluralized)

data is a mass noun or plural of datum - datas is ungrammatical
and jarring for a native speaker.
Split the awkward sounding sentence into two for more clarity,
thanks to Marc Véron for the suggestion.

Signed-off-by: Marc Véron <veron@veron.ch>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 60b31a7a2219dea16f124684bd21e6d12a35c05a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit ad741d2512e23746ceb009b2c0a7f57403ab3bb5)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18704 - File types limit in tools/export.pl is causing issues with csv files...
Nick Clemens [Tue, 30 May 2017 20:55:19 +0000]
Bug 18704 - File types limit in tools/export.pl is causing issues with csv files generated by MS/Excel

To test:
1 - Save a csv of biblionumber from MS/Excel
2 - Attempt to export records using this file
3 - It fails (mimetype is appliction/vnd.ms-excel)
4 - Apply patch
5 - Try again
6 - It succeeds!

Signed-off-by: Jason Palmer <jpalmer@switchinc.org>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit ef6211b319b58b4c35e8cb8555e1caa4da9b2a8f)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 283ccd4da55ce950cf7ace02688daf0db7c0e494)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18179: Update existing calls
Jonathan Druart [Tue, 18 Apr 2017 16:50:36 +0000]
Bug 18179: Update existing calls

This patch updates the existing occurrences of ->find called in a list
context.
There are certainly others that are not easy to catch with git grep.
Test plan:
Confirm that the 4 modified scripts still works as expected.

We need this one ASAP in master to make sure we will not get other
side-effects of this kind and to catch possible uncaught occurrences
before the release.

Tested scripts changed by this patch, they work as expected.
Signed-off-by: Marc Véron <veron@veron.ch>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>

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

6 years agoBug 18478 - QA Followup
Nick Clemens [Tue, 23 May 2017 20:11:06 +0000]
Bug 18478 - QA Followup

Make sure to build necessary letters
Fix awkward construction

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18478 - Unit tests
Nick Clemens [Wed, 17 May 2017 16:58:09 +0000]
Bug 18478 - Unit tests

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoRevert "Bug 18551 - Hide with CSS dynamic elements in member search"
Katrin Fischer [Mon, 5 Jun 2017 13:54:52 +0000]
Revert "Bug 18551 - Hide with CSS dynamic elements in member search"

This reverts commit 243c75430c97df727c4f6a51228d95c401face88.

6 years agoRevert "Bug 18551: followup - hide advanced filters in header, move hidding to css...
Katrin Fischer [Mon, 5 Jun 2017 13:54:38 +0000]
Revert "Bug 18551: followup - hide advanced filters in header, move hidding to css file"

This reverts commit 50f10a39280d741945e501f7de8c12a34429cd5b.

6 years agoBug 18264 - (QA Followup) Remove use of GetBiblioFromItemNumber Replace <blank> with...
Nick Clemens [Mon, 20 Mar 2017 11:22:41 +0000]
Bug 18264 - (QA Followup) Remove use of GetBiblioFromItemNumber Replace <blank> with (blank)

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

Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 0d239e4e6f3c7095173773252dc9ce38b48c0799)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18264 - Course reserves - use itemnumber for editing existing reserve items
Nick Clemens [Tue, 14 Mar 2017 14:16:09 +0000]
Bug 18264 - Course reserves - use itemnumber for editing existing reserve items

This patch alters the crouse reserves module to use itemnumber as the
lookup method for existing reserves as opposed to barcode

To test:
1 - Apply patch
2 - Add some items to a course reserves - all should work as expected
3 - Delete the barcode for an item on reserve
4 - Note the edit link still resolves to the correct item

Followed test plan, works as expected.
Signed-off-by: Marc Véron <veron@veron.ch>

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

Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 2ead301181c33f42d3c88abffa8d18b8a416b40a)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 17974 (QA Followup)
Nick Clemens [Thu, 16 Feb 2017 11:04:11 +0000]
Bug 17974 (QA Followup)

    Use the $biblio_rs variable

    In case of Koha::Object you can call new_from_dbic directly, however,
    it fails for Koha::Objects so using an intermediary variable should
    be done for consistency

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 236dbdf5f1922f98305df8b4c3aee040c0086b05)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 17974: Add the Koha::Item->biblio method
Jonathan Druart [Sat, 21 Jan 2017 15:45:34 +0000]
Bug 17974: Add the Koha::Item->biblio method

Test plan:
  prove t/db_dependent/Koha/Items.t
should return green

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
(cherry picked from commit c614342f2743b1076b6a7a6740ea6586acf547ac)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18478 - Some notices sent via SMS gateway fail
Nick Clemens [Wed, 17 May 2017 16:54:44 +0000]
Bug 18478 - Some notices sent via SMS gateway fail

It seems that for HOLD and DUE (and maybe more) notices we rely on
C4::Letters::SendQueuedMessages
to populate the correct address.

This patch adjust that subroutine to correctly populate the field and/or
fail messages if no SMS provider available

To test:
 1 - Define a messaging prefs for a patron to recieve hold notices via
 SMS
 2 - Ensure you have defined an SMS message for 'HOLD' letter
 3 - Set an SMS alert number for patron
 4 - Set the SMS::Send driver to 'Email'
 5 - Fill a hold for the patron
 6 - Check the db and note the address is null
 7 - run process_message_queue.pl
 8 - Check db - address is null and message pending
 9 - Apply patch
10 - run process_message_queue
11 - Message to_address should be populated and message sent

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 4fa3df9462eaa4a6a2399af4d7036d2f3ee990ce)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18482 False duplicates detected on adding a batch-[16.11.x]
Olivier Crouzet [Sat, 22 Apr 2017 16:20:48 +0000]
Bug 18482 False duplicates detected on adding a batch-[16.11.x]

For applying on 16.11.x
When adding a batch from a stage file with defaut matching on
title/author, if a duplicate is detected, all following records
treated in the batch are discarded from import even if they are not duplicates

Signed-off-by: Alex Buckley <alexbuckley@catalyst.net.nz>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18512: Add tests 16.11.X version
Jonathan Druart [Tue, 2 May 2017 20:27:48 +0000]
Bug 18512: Add tests 16.11.X version

Remove use of build_object

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18512 - GetAuthorisedValues.GetByCode Template plguin should return code (not...
Nick Clemens [Fri, 28 Apr 2017 18:11:00 +0000]
Bug 18512 - GetAuthorisedValues.GetByCode Template plguin should return code (not empty string) if value not found

To test:
1 - Create or edit a borrower with info in Sort1 and Sort2 field, not
mapped to authorized values
2 - Note this info does not display on moremember.tt
3 - Apply patch
4 - Note value is passed through

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>
(cherry picked from commit 62c337065590a0eca51db37d286bcb04fa7971ff)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 14399: Results form also needs a few interface changes
Marcel de Rooy [Wed, 12 Apr 2017 14:06:29 +0000]
Bug 14399: Results form also needs a few interface changes

Currently, the value of compareinv2barcd is used to determine if the
Seen column, the Select/Clear all buttons and the Mark seen buttons are
displayed. But if we scanned barcodes, we already marked items as seen.
So we should only display these buttons when we did not upload barcodes.

Test plan:
[1] Upload a barcode file. Check that the result form does not show
    the buttons.
[2] Generate an inventory list, so do not upload a barcode file. Verify
    that you still see the buttons.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit af89df12e72ea51010039a2206bb942bcc4c4b50)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 14399: Interface changes
Marcel de Rooy [Wed, 5 Apr 2017 13:12:31 +0000]
Bug 14399: Interface changes

A part of the confusion around the inventory script may arise from the
fact that the form offers several options that are only used under
certain conditions. This patch hopefully rearranges a few options more
logically and only offers options when appropriate.

The barcode fieldset now also contains Compare barcodes and Do not check in
checkboxes. These are meaningful when a barcode file is uploaded.

The fieldset Item location filters (new name) contains fields that are
always used. Same for tne only control left under Additional options,
Export to CSV.

The fieldset Optional filters depends on the status of the barcode file
and the Compare checkbox. It is now shown or hidden depending on what
you select: if you do not upload a file, it is shown; or if you upload
a file and check Compare, it is shown. Otherwise we hide it, since the
script will not look at these values. Under this fieldset last inventory
date and Skip items on loan are added, since their behavior is the same
as the various item statuses.

Test plan:
In this test plan we test both the script changes from the previous patch
and the interface changes here. We follow the three main scenario's as
mentioned in the previous patch.

[1] First we prepare a few test items.
    Pick two biblios A, B and create five items say A1,A2,B1,B2,B3.
    Pick a not-existing callnumber range you want to test and move these
    five items there. Add barcodes too (say A1..B3).
    Edit one item A1 to a not-existing notforloan status (doing this on
    the mysql command line is fastest).
    Like: update items set notforloan = '9' where barcode='A1';
    Now simulate that we did not add/edit these items today:
    update items set datelastseen='2017-01-01' where barcode in ('A1','A2','B1','B2','B3');
    Note: We need this when comparing with last inventory date in the last
    scenario.

Scenario 1 (no barcodes uploaded)
[2] Enter the callnumber range on inventory form.
    Verify that "Set inventory date", Compare barcodes and "Do not check
    in" are disabled on the form. Check that you see the Optional filters
    box.
    Submit the form. Verify that you see all five items.
    Do the same. Check Export to CSV. Check result file contents.

Scenario 2 (upload barcodes, do not compare)
[3] Create a barcode file with the barcodes of A1, A2 and B1. Add another
    existing barcode outside the test callnumber range.
    After uploading this file, verify that "Set inventory date", Compare and
    "Do not check in" are enabled. The Optional filters should be hidden.
    Leave "Set inventory date" to today. Enter the callnumber range again.
    Submit the form.
    What do we expect? Four items should have been updated (alert). We
    should see barcode A1 with problem Unknown status. We should see
    also the barcode from the other range (Found in wrong place).
    Repeat this step with the same file. But now export to CSV. Verify that
    you see two barcodes with problems again in the csv file.

Scenario 3 (upload barcodes, compare)
[4] Create another barcode file with barcodes of B2 and one existing barcode
    outside the test callnumber range.
    After uploading this file, check the Compare checkbox. Verify now that
    the Optional filters box is displayed again.
    Leave "Set inventory date" to today. Enter the callnumber range again.
    Also set "Last inventory date" to today (important!).
    Submit the form.
    What do we expect now? Two items should be updated (see alert).
    We should see barcode B3 with problem Missing. We should also see the
    barcode from the other range (wrong place).

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 35b73aa3c6fb163f1389d30f0c175bec19696698)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 14399: Numerous small refinements to the inventory script
Marcel de Rooy [Mon, 3 Apr 2017 13:16:42 +0000]
Bug 14399: Numerous small refinements to the inventory script

This patch contains the following changes:

[01] Label "Inventory date" reworded to "Last inventory date", adding a
small explanation for its purpose.
[02] Restructured the results: it was an array with items and possible
error messages. Multiple messages duplicated individual items. Now the
results are in a hash, pulling all error messages for one item together.
At the end of the script they are copied to an array. (A helper sub
additemtoresults is added in this regard.) We no longer use array
@items_with_problems.
[03] Both datepickers are no longer connected to the same class. This
prevents changing the set date by filling the last inventory date.
[04] Input markseen in the template and $markseen in the script are
no longer needed.
[05] The paragraph before the detail link in the results table in the
Title column has been removed. Same for problems column. This makes
vertical spacing consistent.
[06] Problem status 'missingitem' is no longer used; the missing items
are marked as 'not_scanned'. Two additional statuses are: no_barcode and
checkedout.
[07] Removed unused $itemtype, $totalrecords and $count. We use variable
$moddatecount to report a count to the template.
[08] The script updated scanned items twice. The first time with ModItem
and the second time with ModDateLastSeen. The second call is removed.
[09] If a book is checked in, we do no longer return an error message when
the checkin is successful (ERR_ONLOAN_RET). The updated datelastseen is
passed to the results.
[10] $wrongplacelist is renamed to $rightplacelist. It is only built when
we need it. (Same for inventorylist now.)
[11] Datelastseen (last inventory date) is always used for building the
inventory list. It allows you to process partial barcode lists or make
a list of items not seen after some date. We do no longer use variable
$paramdatelastseen.
[12] The section where items.datelastseen was compared with the inventory
date has been removed. Scanned items were already updated; to get items
seen before some date, you can now use last inventory date without passing
barcodes.

The form can mainly be used for the following three cases:
[1] Prepare an inventory list or csv file; we do not upload barcodes.
[2] Update items for uploaded barcodes without comparing to inventory.
    Last inventory date is useless in this case.
    Errors wrongplace, checkedout and changestatus are reported.
    Use this scenario for partial scanned barcode lists (all but last).
[3] Update items for uploaded barcodes and compare to inventory, filtered
    by an optional last inventory date.
    Apart from the errors mentioned under [2], this also reports
    not_scanned ("missing") and no_barcode.
    Use this scenario too for the last partial barcode file (together with
    inventory date).

Test plan:
See next patch ("Interface changes").

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 6da97c7c8713bb16cbf6cf079df18534c3661414)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 14399: Prevent display of double zero notforloan status
Marcel de Rooy [Mon, 3 Apr 2017 11:05:13 +0000]
Bug 14399: Prevent display of double zero notforloan status

On bug 12913 a zero status is added on the inventory form. This prevents
a lot of false warnings for a wrong notforloan status. The zero status
is not included in the default setup. But if you would add one, the
status will display here twice now.

This patch checks if the status already exists.

Test plan:
[1] Add a zero NOTFORLOAN status if it does not yet exist in Authorized
    values.
[2] Check that you do not see two "For loan" statuses on inventory form.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit e162c4d526e042c4b382629a7aec880dcfced346)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 5395: Update C4::Acquisition::SearchOrders POD
Mark Tompsett [Wed, 24 May 2017 05:54:02 +0000]
Bug 5395: Update C4::Acquisition::SearchOrders POD

Comparing the perldoc to the function:
- basketname
- basketgroupname
- budget_id
Were missing. This adds them.

Also, a description of ordernumber and search were
added, as they are not self-evident by their name
alone.

There are no code changes, so all tests should pass
or fail identically before and after patch.

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

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 8ed599113c7592ec2e2227e3a7265a7e9cc9ca0e)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18669 - RewriteCond affecting wrong rule in koha-httpd.conf
David Cook [Thu, 25 May 2017 04:37:21 +0000]
Bug 18669 - RewriteCond affecting wrong rule in koha-httpd.conf

One of the RewriteCond directives in koha-httpd.conf was affecting
the wrong RewriteRule after its original RewriteRule was commented out
years ago.

_TEST PLAN_
0) Before applying patch, build Koha from source
    *) make
    *) make install (or make upgrade)
    *) Copy or symlink etc/koha-httpd.conf to your Apache vhost directory
        (and enable if you're on a Debian based system)
    *) Restart Apache
1) Make sure that you have at least 1 bibliographic record in Koha
(URL like this http://server:port/cgi-bin/koha/opac-detail.pl?biblionumber=1)
2) Go to http://server:port/bib/1
3) Note that you get a 404 error
4) Apply the patch
5) Rebuild Koha from source as per step 0
6) Go to http://server:port/bib/1
7) Note that you now see the same page as you would if you went to
http://server:port/cgi-bin/koha/opac-detail.pl?biblionumber=1

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 9026169a235aa8133660ef649d98d8cedc5a4692)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18611: [QA Follow-up] Add unit test for GetItemNumbersFromImportBatch
Marcel de Rooy [Fri, 26 May 2017 08:25:10 +0000]
Bug 18611: [QA Follow-up] Add unit test for GetItemNumbersFromImportBatch

Test plan:
Run t/db_dependent/ImportBatch.t

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 01e7523dfb1ec9789f38dd6d7819cb5e3d7d7cc2)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18611: [QA Follow-up] Make SQL query more readable
Marcel de Rooy [Fri, 26 May 2017 08:20:00 +0000]
Bug 18611: [QA Follow-up] Make SQL query more readable

Make it more explicit by adding join statements.

Test plan:
See next patch for adding a unit test.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit b37df275b85114ccd23986d94af7ed21544269e6)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18611 - Followup, remove tabs to make qa tools happy
Josef Moravec [Tue, 23 May 2017 11:03:04 +0000]
Bug 18611 - Followup, remove tabs to make qa tools happy

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 092f02d227417ac9786e23651ab13fbd566589c8)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18611 - Create labels action fails in manage-marc-import.pl if an item has been...
Nick Clemens [Tue, 16 May 2017 09:40:28 +0000]
Bug 18611 - Create labels action fails in manage-marc-import.pl if an item has been deleted from the import batch.

To test:
1 - Import a batch with some items
2 - Delete one of the imported items
3 - Browse to Tools->Staged MARC record management
4 - Click (Create label batch) for the batch you imported
5 - Recieve an error
6 - Apply patch
7 - Click (Create label batch)
8 - Batch is created with remaning items from the import

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 7249351f120f3bd02d7f7829af10bd89cae490dc)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18600 - DBRev 16.11.00.002
Katrin Fischer [Mon, 5 Jun 2017 12:38:20 +0000]
Bug 18600 - DBRev 16.11.00.002

6 years agoBug 18600: Add pref TalkingTechItivaPhoneNotification if missing
Jonathan Druart [Tue, 23 May 2017 19:16:39 +0000]
Bug 18600: Add pref TalkingTechItivaPhoneNotification if missing

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

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit ec4b976289d68b4122f081f05ff7a7a023a32580)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18204 - Authority searches are not saved in Search history
LeireDiez [Thu, 11 May 2017 15:09:22 +0000]
Bug 18204 - Authority searches are not saved in Search history

When you search an authority in Authority search, this search is not saved in Search history.

EnableOpacSearchHistory is enabled

Steps to test:
 1- Login your account (opac)
 2- Search an authority in Authority search
 3- Go to Search history -> Authority
 4- It says "Your authority search history is empty"

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit d4e3e6af9fd054dc64844be49e8d1a0f28b545bd)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 16295: Fix access to MMT admin page
Jonathan Druart [Tue, 23 May 2017 17:10:20 +0000]
Bug 16295: Fix access to MMT admin page

There was a typo in the permission code

Test plan:
Try to access the marc modification templates admin page with the
marc_modification_templates permission (and not all tools permissions)

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit d046474805b065f7419fefb06902d6ae18a0cd29)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18663 - DBRev 16.11.00.001
Katrin Fischer [Mon, 5 Jun 2017 12:26:35 +0000]
Bug 18663 - DBRev 16.11.00.001

6 years agoBug 18663: Add pref ExportRemoveFields if missing
Jonathan Druart [Tue, 23 May 2017 19:16:17 +0000]
Bug 18663: Add pref ExportRemoveFields if missing

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 6f29c775d92d72bd03188efea4a41b3fbb49e928)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 15465: Fix typo in bugs.k-c.org
Jonathan Druart [Fri, 26 May 2017 14:45:31 +0000]
Bug 15465: Fix typo in bugs.k-c.org

(cherry picked from commit 0b7c517bfe9c76b0e40f25f1fa5b1f3cf7a00dd3)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18548: Print usage when missing instance name in koha-create script
Josef Moravec [Fri, 5 May 2017 10:23:23 +0000]
Bug 18548: Print usage when missing instance name in koha-create script

Test plan:
1. Run: debian/scripts/koha-create --request-db
-> Without patch you see the getent error message
-> With patch you see usage and "Missing instance name" message

Signed-off-by: Dilan Johnpulle <dilan@calyx.net.au>

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit d2ed4fadc59260372baedab038d16bd7cb169b1c)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18569 - Quick add patron will not copy over details from cities and towns pull...
Nick Clemens [Fri, 12 May 2017 13:38:37 +0000]
Bug 18569 - Quick add patron will not copy over details from cities and towns pull down into patron details

Followed test plan and the city value updates in the quick add form correctly.
Signed-off-by: Dilan Johnpulle <dilan@calyx.net.au>

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit e609679eb278383f573eda78048f8fa107ae159b)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18598 - Quick add form doesn't clear values when switching
Nick Clemens [Fri, 19 May 2017 02:00:44 +0000]
Bug 18598 - Quick add form doesn't clear values when switching

To test:
1 - Fill out some fields in quick add
2 - Switch to full form and clear fields
3 - Switch back and fields are still populated
4 - Fill a field in long form
5 - Switch to quick add and clear it
6 - Save
7 - Value set in 4 is saved
8 - Apply patch
9 - Repeat 1-6 - values should be cleared and not saved

Signed-off-by: Marc Véron <veron@veron.ch>

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit c762cd827e0a80960f3b23513981a382025b3bee)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18596 - Quick add form duplicating password confirm
Nick Clemens [Fri, 12 May 2017 13:18:45 +0000]
Bug 18596 - Quick add form duplicating password confirm

To test:
1 - Add password to BorrowerMandatoryField
2 - View quick add form
3 - See confirm password twice
4 - Apply patch
5 - See confirm password once
6 - Add password to QuickAddFields
7 - Confirm one confirm field
8 - Remove password form BorrowerMandatory field
9 - Confirm there is one confirm field and password fields are not
required

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 3e5dbef9ef18e0eaadfff9c7d7b5838aec75fb36)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18647: Resolve internal server error on category_type
Marcel de Rooy [Tue, 23 May 2017 12:31:01 +0000]
Bug 18647: Resolve internal server error on category_type

See bug 18552. When we resolved the housebound_role bug, the hash got
filled correctly again. And this revealed that the (second) call to
Koha::Patrons->find was not appropriate. It can be removed, as Jonathan
explained on the report.

Note: Commit 95429af6855e8ed37945b681dc466bf360deffb added this call, but
it was hidden until the template variable hash got fixed.

Test plan:
Restart Plack and go to patron details again.

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: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 87bb59304e53755d7b4565c517578a838e1f0041)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18552: [16.11.X] [QA Follow-up] Resolve warnings
Marcel de Rooy [Fri, 19 May 2017 10:22:03 +0000]
Bug 18552: [16.11.X] [QA Follow-up] Resolve warnings

Like:
Problem = a value of AutoResumeSuspendedHolds has been passed to param without key at /usr/share/koha/masterclone/C4/Templates.pm line 137.
Problem = a value of relatives_borrowernumbers has been passed to param without key at /usr/share/koha/masterclone/C4/Templates.pm line 137.

Problem is functions returning undef in list context (in this case
housebound_role).
No need to call Patrons::find a second time.

Note: The call of GetDebarments in the first patch suffered from this too.
It is in a fine place now too. But strictly speaking, should not have been
moved.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18552: [16.11.X] Borrower debarments not showing on member detail page
Aleisha Amohia [Thu, 18 May 2017 23:10:13 +0000]
Bug 18552: [16.11.X] Borrower debarments not showing on member detail page

To test:
1) Go to a borrowers details page and create a manual restriction
2) Notice the restriction shows at the top of the page but the
restriction tab says the member is currently unrestricted
3) Apply patch and refresh page
4) Restrictions tab should now correctly show debarments and correct
number is shown
5) Confirming deleting and adding restrictions still works as expected

Sponsored-by: Catalyst IT

Followed test plan, works as expected
Signed-off-by: Marc Véron <veron@veron.ch>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 17108 - Update debian/control
Mirko Tietgen [Mon, 22 May 2017 07:49:47 +0000]
Bug 17108 - Update debian/control

Last changes in debian/control as added to 16.11.08

Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>

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

6 years agoAdd release notes to 16.11.08 release v16.11.08
Katrin Fischer [Mon, 22 May 2017 05:35:27 +0000]
Add release notes to 16.11.08 release

6 years agoMerge remote-tracking branch 'transl/16.11.08-translate-20170521' into 16.11.x
Katrin Fischer [Mon, 22 May 2017 05:26:12 +0000]
Merge remote-tracking branch 'transl/16.11.08-translate-20170521' into 16.11.x

6 years agoTranslation updates for Koha 16.11.08
Bernardo Gonzalez Kriegel [Sun, 21 May 2017 23:29:03 +0000]
Translation updates for Koha 16.11.08

6 years agoIncrement version for 16.11.08 release
Katrin Fischer [Sun, 21 May 2017 22:54:29 +0000]
Increment version for 16.11.08 release

6 years agoBug 18551: followup - hide advanced filters in header, move hidding to css file
Josef Moravec [Tue, 9 May 2017 13:33:52 +0000]
Bug 18551: followup - hide advanced filters in header, move hidding to css file

Test plan:
The same as first patch, but also with advanced search form in header hidden
on page load - see comment 4

Issue with advanced search form is gone.
Signed-off-by: Marc Véron <veron@veron.ch>

Signed-off-by: Philippe <philippe.audet-fortin@inlibro.com>

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 9719284622e2c3027ef615286ef417f920238c9f)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18551 - Hide with CSS dynamic elements in member search
Fridolin Somers [Fri, 5 May 2017 13:00:05 +0000]
Bug 18551 - Hide with CSS dynamic elements in member search

In member search page, the result table is in Ajax so fully managed by Javascript. There is also a yellow dialog message prepared in HTML.

Thoses elements are hidden by JS code : ie $("#patron_list_dialog").hide().

The problem is that the static page is first loaded an displayed then the JS code runs an hides the elements.
On a low performance computer, this action is visible and looks like there is a blinking yellow message.

I propose to hide with CSS so that thoses elements are not displayed in static page and are there shown in dynamic JS code.

Test plan :
Check display is unchanged :
- Go to home page /cgi-bin/koha/members/members-home.pl
- Perform patron search from header search box
- Perform patron search by clicking on a letter
- Perform patron search from filters (left of results table)
- Select a patron and add it to a list => you see the yellow message

Yellow message does no longer appear with this patch.
Signed-off-by: Marc Véron <veron@veron.ch>

Signed-off-by: Philippe <philippe.audet-fortin@inlibro.com>

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 5cc536c68b221823f4335b5b5db1108521f88a71)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18578: Use subdirectory in /tmp for session storage during installation
Marcel de Rooy [Thu, 11 May 2017 07:10:50 +0000]
Bug 18578: Use subdirectory in /tmp for session storage during installation

Apply the change from bug 15553 to InstallAuth.pm too.

Test plan:
[1] Remove all cgisess_* files from your /tmp directory.
[2] Remove directory /tmp/cgisess_koha_[your instance], if there.
[3] Run the webinstaller
    /cgi-bin/koha/installer/install.pl?step=1&op=updatestructure
[4] Check if you have cgisess_ files in /tmp/cgisess_koha_[your instance].

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit c9de665c294f0e4416a9f1ea751e2859eb065a9c)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18536: [QA Follow-up] Tiny regex simplification
Marcel de Rooy [Fri, 19 May 2017 09:39:24 +0000]
Bug 18536: [QA Follow-up] Tiny regex simplification

Simplify regex for removing table name.
No need to escape a dot between the square brackets. No need to specify a
number of 1 between parentheses.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 63c6eaca8d649cb7864b90e5e1ee9ac019daffdf)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18536: Generating CSV using profile in serials late issues doesn't work as described
Josef Moravec [Thu, 4 May 2017 08:54:30 +0000]
Bug 18536: Generating CSV using profile in serials late issues doesn't work as described

Description on editing csv profiles says:

"You can also use your own headers (instead of the ones from Koha) by
prefixing the field name with an header, followed by the equal sign."

So the header should be optional, but in fact it's mandatory. Also the
regular expression to cut table name from beginning of db column is not
right.

Test plan:

0. Don't apply the patch
1. Make two CSV profiles for exporting late issues
    a) SUPPLIER=aqbooksellers.name|TITLE=subscription.title|ISSUENUMBER=serial.serialseq|LATE SINCE=serial.planneddate
    b) aqbooksellers.name|TITLE=subscription.title|ISSUE NUMBER=serial.serialseq|LATE SINCE=serial.planneddate
2. Export late issues, profile a) works as expected, profile b) doesn't
3. Apply the patch
4. Both profiles should work

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

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 6b8f9d7e14a8b93143185e814464393ef275631d)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18597 - Quick add form does not transfer patron attributes values when switching...
Nick Clemens [Fri, 12 May 2017 14:00:29 +0000]
Bug 18597 - Quick add form does not transfer patron attributes values when switching forms/saving

The function that switches between quick add/fulll form assumes labels
are followed by values - patron_attr don't follow this pattern. This
patch just moves the hidden input field

To test:
1 - Have some patron attributes (with/without auth values set)
2 - Add them to QuickAddFields (patron_attr2 for example)
3 - view quick add form and set some values
4 - Switch to full form, values not transferred
5 - Switch to quick add, view values, save
6 - Values are not saved :-(
7 - Apply patch
8 - Repeat 3 - 5
9 - Values are transferred and saved :-)

Signed-off-by: Peggy Thrasher <p.thrasher@dover.nh.gov>

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

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 48c87a19a68bf1157c471b8355f5eafe9ec305c1)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 18534 - When IndependentBranches is enabled the pickup location displayed incorre...
Nick Clemens [Wed, 3 May 2017 19:21:40 +0000]
Bug 18534 - When IndependentBranches is enabled the pickup location displayed incorrectly on request.pl

To recreate:
1 - Place a hold for pickup at Midway
2 - Enable independentbranches
3 - Login to staff interface as admin without superlibrarian status from
a different branch
4 - View the holds for the title you placed a hold on
5 - The hold placed in step 1 should show a dropdown with current branch
as pickup location, current branch is the only in that dropdown
6 - Verify it displays correctly for superlibrarian
7 - Apply patch
8 - The correct pickup location should show and not be editable
9 - Verify it is a dropdown

Signed-off-by: Alex Buckley <alexbuckley@catalyst.net.nz>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 90575b64d5c4ed63e1eeded043865796bbcde244)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

6 years agoBug 16568 - Talking Tech generates phone notifications for all overdue actions
Kyle M Hall [Mon, 23 May 2016 14:05:58 +0000]
Bug 16568 - Talking Tech generates phone notifications for all overdue actions

Regardless of whether the phone transport has been selected for a given
overdue action or not, the Talking Tech outbound script generates and
sends a line for that action.

Test Plan:
1) Enable Talking Tech
2) Create one or more overdue actions without a phone transport selected
   and one or more with the phone transport selected
3) Generate the overdues csv file to send to Itive
4) Note the csv file has lines for actions that do not have the phone
   transport selected
5) Apply this patch
6) Repeat step 3
7) Note the csv file now only has lines for actions that have the phone
   transport selected

Signed-off-by: Jonathan Field <jonathan.field@ptfs-europe.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 86678bbc26954e5e4eddf8b11b652b4c83e80425)
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>