Owen Leonard [Tue, 3 May 2016 17:09:54 +0000 (13:09 -0400)]
Bug 16159 - guarantor section missing ID on patron add form
In the patron entry form template most <fieldset> and <legend> tags have
unique ids. This patch adds ids to fieldsets and legends which lack
them.
To test apply the patch and view the patron entry form. There should be
no visual changes. There should be no HTML validation errors triggered
by this change.
Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit 553d06073b8af0ab6ed33393b22a953e3feca1e6) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Fri, 18 Mar 2016 13:39:27 +0000 (13:39 +0000)]
Bug 16105: Do not initialize the memory cache if not needed
Cache::Memory is loaded and Koha::Cache::_initialize_memory is called
even if a memcached cache has been correctly initialize, it does not
make sense.
It should only be initialize if needed.
Test plan:
Correctly configure a memcache server and confirm that the memory cache
is not initialize.
Do not configure correctly a memcache server and confirm that the cache
system default on Cache::Memory
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 2026be47fd79fb15f1e9fb83be34403e8eb18079) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Mark Tompsett [Mon, 4 Apr 2016 22:59:33 +0000 (18:59 -0400)]
Bug 14144: Clean ups and refactors
perltidy
old new calls to new call format
attrType -> attr_type (perlcritic friendlier)
double quotes to single quotes
'' combinations to q{} (perlcritic friendlier)
refactored parameters to mock_net_ldap_search into a HASH
This piece is not necessary, but I think it is nicer.
Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as expected. No koha-qa erros
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit fdda5d7d7cf8c724e57e5bb8b1e55533cb0e7b8b) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Revisiting this bug, I noticed that C4::Context->config() was mocked
poorly. I expanded the mock function a little and have quieted the
test which seemed to be working in a broken manner before.
TEST PLAN
---------
1) prove t/db_dependend/Auth_with_ldap.t
-- shibboleth noise
2) apply this patch
3) prove t/db_dependend/Auth_with_ldap.t
-- no noise
4) run koha qa test tools
Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit b140c4b2fdc894c0d53eca2bf2f2bb5cb1982a91) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Kyle M Hall [Tue, 5 Nov 2013 16:31:20 +0000 (11:31 -0500)]
Bug 11203 - Datatables in acqusitions do not ignore "stopwords" in titles
Sorting by the "summary" column does not produce the preferred results.
Title beginning with 'a', 'an', or 'the' are sorted using those
articles.
Test plan:
1) Place an order for 2 items with the titles "Alpha" and "The Alpha",
along with some other records with titles starting with something
between 'a' and 't', and 't' and 'z'
2) Sort the "pending orders" table, note the incorrect sorting
3) Receive all the items
4) Sort the "already received" table, note the incorrect sorting
5) Apply the patch
6) Repeat steps 1-4, note the corrected sorting
7) Check acqui/basket.pl for correct sorting
8) Check acqui/invoice.pl for correct sorting
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 8e9e56d0d4aefef9ef7bd7bc48d9e859aadc465e) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Kyle M Hall [Tue, 19 Apr 2016 11:55:28 +0000 (11:55 +0000)]
Bug 9393 [QA Followup] - Don't display link if librarian cannot view the modification
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit b46f4128ea250010b644aa55b544c3c663a7fd17) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Kyle M Hall [Tue, 18 Dec 2012 19:18:16 +0000 (14:18 -0500)]
Bug 9393 - Add note to circulation.pl if borrower has pending modifications
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
New link "patron modifications" (if there are) on the checkout page.
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 23f45686411aa4e26dab157d69b156c896136915) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Thu, 5 May 2016 13:52:04 +0000 (14:52 +0100)]
Bug 16447: Remove occurrence of the borrow permission which does no longer exist
Bug 7976 has removed this permission, but other patches re-added it...
Note that the occurrences in sendbasket.pl, edithelp.pl, opac/svc/login should
have been removed by bug 7976.
Test plan:
git grep 'borrow.*=> 1'
should not return any results.
Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit c4eabeda0b1ca6b856483b3d225b9093dc6e316a) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Mon, 2 May 2016 09:46:59 +0000 (10:46 +0100)]
Bug 16407: Simplify comments
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 671f81e877a3e23127a2e8078921760e9b449a27) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
This test was using hardcoded borrower number, assuming they should be
present. Now we use TestBuilder.
Test plan:
Run the test.
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Test pass before and after patch.
No errors
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit d8d4277471908bf046d04b4e94eed6cd4c94f63b) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
This test fails if you do not have a MPL branch, but a closer look shows
that we only need to replace one occurrence.
Test plan:
Run Accounts.t
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 6dbceac466772fa65fe3676163b89dec37151b23) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Owen Leonard [Tue, 26 Apr 2016 18:54:23 +0000 (14:54 -0400)]
Bug 16369 - Clean up and improve plugins template
This patch makes multiple changes to the plugins home page template to
bring it up to date with current interface patterns.
Test the following changes:
- Breacrumb links have been corrected to include "Tools" in the path.
Verify that this link is correct.
- A toolbar has been added for an "Upload plugin" button. Uploading is
an action, not a view, so it should be displayed in a toolbar. Verify
that the button works correctly.
- Messages are now formatted as messages rather than as headings. To
test, trigger a message by, for instance, uninstalling all plugins or
passing an invalid "method" parameter with the URL.
- Incorrect capitalization corrected.
- Plugin actions are moved to a single "Actions" dropdown menu. This
includes 'Run report,' 'Run tool,' 'Configure,' and 'Uninstall.' Test
that all these menu options work correctly.
- The standard "Tools" sidebar menu has been added.
- An "onclick" attribute has been removed in favor of defining the event
in JavaScript. Test by choosing the 'Uninstall' menu item for a
plugin. Test both confirm and cancel actions.
Also changed:
- Corrected capitalization on the tools home page.
- Adding missing plugins link to the tools sidebar menu.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 822509eee5f50e0425115a576be8d1f2c0450d35) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Owen Leonard [Thu, 21 Apr 2016 16:39:53 +0000 (12:39 -0400)]
Bug 16321 - 'Show all details' checkbox triggers JS error after jQuery upgrade
This patch fixes problems with show/hide actions on a few pages
caused by some problematic jQuery syntax.
To test, apply the patch and go to Acquisitions.
Testing basket.tt:
- Locate a vendor which has an open basket with multiple orders.
- View the details of that basket.
- Click the 'Show all details' checkbox above the table of orders.
- Checking the box should trigger the display of additional columns in
the table.
- Unchecking the box should hide them again.
Testing invoice.tt:
- Go to Acquisitions -> Invoices and perform an invoice search.
- Click to view an invoice which includes one or more received records.
- Click the 'Show all details' checkbox above the table of titles and
confirm that it fuctions as described above.
Testing newordersubscription.tt:
- Go to Acquisitions and locate a vendor which is linked to a
subscription
- Create or add to a basket for that vendor.
- Add an order using the 'From a subscription' option.
- Perform a search for subscriptions.
- In the table of subscriptions search results, checking or
unchecking the "Show only renewed" checkbox should work correctly.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 080ae7a8b9587aaa31b0adfb8925981dc574aa65) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Owen Leonard [Tue, 3 May 2016 13:48:11 +0000 (09:48 -0400)]
Bug 16315 - OPAC Shelfbrowser doesn't display the full title
This patch adds subtitle information to the display of titles in the
OPAC's shelf browser.
To test, apply the patch and make sure OPACShelfBrowser is enabled.
- View the detail page for any title in the OPAC which has items.
- Click the "Browse shelf" link next to any item in the holdings table.
- The titles in the shelf browser should display with all subtitle
information as defined in Keywords to MARC mapping.
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Adding 245a and c as 'subtitle' in Keywords to Marc make them
show on shelf browser.
No errors.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit 67f91f24e537ef93d0c121b68681dcdec9f417e1) Signed-off-by: Julian Maurice <julian.maurice@biblibre.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 6e0b6ecf1347a91c2d324abc08e76f1cd8d9ffd0) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Items.t inserts an item via biblioitem not correctly linked to biblio.
The new foreign key constraint does not allow that.
Actually, we should be choosing to either remove biblioitems from Koha or
remove biblionumber from items.
Note: This seems to be the only case where an item is added this way.
Test plan:
Run Items.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 1608b89b7ff90ae1cc307d9f096ddaab29ba2192) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Mark Tompsett [Thu, 31 Mar 2016 00:11:45 +0000 (20:11 -0400)]
Bug 16170 - Corrected to make work more smoothly
Signed-off-by: Mark Tompsett <mtompset@hotmail.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 503cc30d9ae03f12b3c412d2d280ea76393b97da) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Marcel de Rooy [Wed, 23 Mar 2016 15:59:26 +0000 (16:59 +0100)]
Bug 16170: Pseudo foreign key in Items
While many of us would like to get rid of biblioitems one day, the current
scheme includes a biblioitemnumber and a biblionumber in Items.
(Which is not so great..)
But also note that biblionumber is NOT defined as a foreign key in Items,
although a belongs_to relation has been added to the DBIx scheme!
This inconsistency should be resolved. The "remove biblioitem table"
operation is a large one, but in the meantime we better make biblionumber
a regular FK not a 'pseudo' one.
Note: If in an (very) exceptional case biblionumbers are found in items,
that do not exist in biblio, this patch prints a warning at upgrade
time and does not add the constraint.
@RM: Please update the DBIx scheme accordingly.
Test plan:
[1] Run the upgrade. Check if the FK constraint has been added.
[2] Remove the FK constraint. Change the biblionumber of one item to an
unexisting record. Run the upgrade again. Notice the warning.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Tested both cases: constraint added as well as warning printed.
Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 33694a8faac22e760e0559d99a9d013f7c90275b) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Wed, 30 Mar 2016 07:42:12 +0000 (08:42 +0100)]
Bug 16041: Turn off StaffAuthorisedValueImages by default
This feature is enabled by default, but the users are not aware of it
and it costs a lot of time processing to get the images.
There are 2 prefs to drive this feature: StaffAuthorisedValueImages and
AuthorisedValueImages. AuthorisedValueImages is not added by sysprefs.sql and
does not appear in updatedatabase.pl, we could easily imagine that
nobody uses it.
With XSLT enabled, the feature is only visible on a record detail page
at the OPAC, if AuthorisedValueImages is set.
Otherwise you need to turn the XSLT off. In this case you will see the
images on the result list (OPAC+Staff interfaces) and OPAC detail page,
but not the Staff detail page.
The idea of this patch is to introduce a quick switch if the feature is
not used by the library.
Test plan:
1/ Turn the pref on and set authorised_values.imageurl to NULL
Execute the DB entry
=> The pref have been turned off
2/ Turn the pref on and set an image for an authorised value
Execute the DB entry
You will get a warning
3/ Turn the pref off and set an image for an authorised value
Execute the DB entry
You will get a warning
4/ Turn the pref off and set authorised_values.imageurl to NULL
Execute the DB entry
You won't get a warning
Note that the opac detail page now checks the pref before retrieving the
images.
Followed test plan, works as expected. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Fixed update message 'that means'.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 78605bceb368ed298e7d47fbb64b255dfcdd2842) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Aleisha [Tue, 23 Feb 2016 04:06:30 +0000 (04:06 +0000)]
Bug 15823: Can still access patron discharge slip without having the syspref on
EDIT: Fix for OPAC side
EDIT: Comment 10
EDIT: Merge conflicts
To test:
1) Ensure syspref useDischarge is disabled
2) Go to /cgi-bin/koha/members/discharge.pl?borrowernumber=X&discharge=1
3) Validate that you are still able to generate a discharge slip for this patron
4) Apply patch and refresh page
5) Confirm that you are redirected to the circulation.pl page for the user and that an error message is there.
OPAC SIDE
6) Go to the OPAC
7) Go to /cgi-bin/koha/opac-discharge.pl
8) Confirm you get a message saying discharges are disabled
9) Go to /cgi-bin/koha/opac-discharge.pl?op=request
10) Confirm you see same message
Sponsored-by: Catalyst IT
Followed test plan, works as expected (both staff client and OPAC).
Re-tested, works OK. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 853d3cfe4d76d6f847e4f30dca4d50d278951fd0) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Nick Clemens [Mon, 28 Mar 2016 20:01:30 +0000 (20:01 +0000)]
Bug 15682 - Merging records from cataloguing search only allows to merge 2 records
To test:
1 - Perform a cataloging search
2 - Attempt to merge 0 results - should fail
3 - Attempt to merge 1 resutls - should fail
4 - Attempt to merge 2 results - should succeed
5 - Attempt to merge 3 results - should succeed
6 - Test any other amount of records and if more than 1 it should
succeed
**Note: On shelves.pl you can merge a single record. I think that is
incorrect so made this only work for 2. Will add a followup to fix
shelves.pl
Signed-off-by: Chris Cormack <chrisc@catalyst.net.z> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit 8f1e5ad95fd78cbf09028e3d2dfe0b2b77d4dd21) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jesse Weaver [Fri, 6 May 2016 19:52:46 +0000 (13:52 -0600)]
Bug 15816: Redirect back to correct page after login
This uses a hacky but simple method to get the correct script name under
proxied packaged Plack.
Test plan:
1) Log out of both the OPAC and staff side.
2) Try to access a page that requires login (opac-reserve.pl is a
good one for the OPAC), then log in.
3) You will be redirected back to mainpage.pl or opac-user.pl.
4) Repeat above for both staff side and OPAC.
5) Apply patch.
6) Repeat steps 1-4; you should be redirected back to the original
page you were on.
7) Repeat the above for both a traditional CGI and kohadevbox/package
Plack installation.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit bc707baf02c672fdd8f6d2095137694d7e400a97) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Sat, 23 Apr 2016 06:30:35 +0000 (07:30 +0100)]
Bug 14632: Add Copyright for the Koha Dev Team
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
https://bugs.koha-community.org/show_bug.cgi?id=14362
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 68dbe8415f17801798fea26803b9bd9fd5e713bb) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Mark Tompsett [Mon, 8 Jun 2015 03:40:50 +0000 (23:40 -0400)]
Bug 14362: Regression tests
This should trigger the error. Attempts to shift system time
zones did not make sense as to the number of failures.
Added Time::Fake dependency, if it isn't installed these extra
tests don't run. There is a nice skip message about it.
Added License text.
TEST PLAN
---------
1) apply test patch
2) sudo dpkg-reconfigure tzdata
-- set your system time to GMT (Africa/Abidjan)
3) prove t/Circulation/AgeRestrictionMarkers.t
-- should not fail, even if you change system
time to any time.
4) sudo dpkg-reconfigure tzdata
-- set your timezone to Eastern
5) sudo date -s"2015-06-18 21:15:00"
6) date
-- should be past 9pm Eastern timezone
7) prove t/Circulation/AgeRestrictionMarkers.t
-- kaboom!
8) sudo date -s"2015-06-18 12:00:00"
9) date
-- should be noon Eastern timezone
10) prove t/Circulation/AgeRestrictionMarkers.t
-- success?! Time sensitive tests are bad tests.
11) sudo apt-get install libtime-fake-perl
12) prove t/Circulation/AgeRestrictionMarkers.t
-- kaboom!
-- changing timezone to anything other than GMT
should trigger a kaboom.
13) apply fix patch
14) prove t/Circulation/AgeRestrictionMarkers.t
-- should work all the time.
15) less t/Circulation/AgeRestrictionMarkers.t
-- the license text should be similar to
http://wiki.koha-community.org/wiki/Coding_Guidelines#Licence
16) koha qa test tools.
Signed-off-by: Nick Clemens <nick@bywatersolutions.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 a2aba3c86f106603212eb2c5beb52c3cdfe49857) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Conflicts:
C4/Installer/PerlDependencies.pm
Mark Tompsett [Mon, 8 Jun 2015 01:26:53 +0000 (21:26 -0400)]
Bug 14362: PEGI15 Circulation/AgeRestrictionMarkers test fails
It is best to test when UTC date is a date in the future compared
to your timezone. I'm in Eastern, so right now, I expect this
test to fail for another 2.5 hours.
TEST PLAN
---------
1) prove t/Circulation/AgeRestrictionMarkers.t
-- fails for PEGI 15 after 9pm.
2) Apply patch
3) prove t/Circulation/AgeRestrictionMarkers.t
-- works.
4) koha qa test tools
Signed-off-by: Nick Clemens <nick@bywatersolutions.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 73f55165bef229668a135bee7e8c90a2c9c3f0a7) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Julian Maurice [Mon, 9 May 2016 09:42:05 +0000 (11:42 +0200)]
Bug 13041: Fix add of basket's manager when name contains a single quote
If you are trying to add a user as a manager of a basket in
acquisitions, a JavaScript error will be triggered if that user has a
single quote in their name (e.g. "O'Neil"). This patch corrects the
issue.
Also changed by this patch: Increased the size of the patron search
popup and made a correction to some invalid HTML.
To test you should have a patron whose name contains a single quote who
is also a user with permission to manage acquisitions.
- Apply the patch and go to Acquisitions.
- Locate an open basket and view the details for that basket.
- In the "Managed by" section, click the "Add user" button to trigger
the patron search popup.
- Search for the patron described above and click the "Add" button.
- In the parent window, the patron you chose should have been added to
the "Managed by" section.
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Marc Véron [Wed, 27 Apr 2016 10:38:58 +0000 (12:38 +0200)]
Bug 12721: (followup) Replace mysqlism by DBIx::Class
This patch removes the mysqlism (see comment #18)
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Fixed QA tools complaints about missing lines before
and after =cut in POD.
Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit ef97b6b301a5c1a9ef5c63cc93933bf7442513fc) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
- Change syspref to any combination of location|itype|ccode
=> Result: Table displays columns as appropriate
- Change syspref to some garbage
=> Result: Same as with empty syspref (was crashing without patch)
- Change syspref to valid combination with trailing |
=> Result: Table displays columns as appropriate (was crashing
without patch)
- Change syspref to a combination of valid and invalid fields
(location|blah|ccode)
=> Result: Table displays column of valid fields only (was crashing
without patch)
Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 5fc93bce9b786797724539bea1a1689e959078e6) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Marc Véron [Sun, 18 Oct 2015 16:27:58 +0000 (18:27 +0200)]
Bug 12721 - Syspref StatisticsFields: Warning on About page and text change in System preferences
This patch adds a warning to the about page if the syspref 'StatisticsFields' is misconfigured.
Additionally, the text on Home > Administration > SystemPreferences for 'Statistics Fields'
is changed.
To test:
- Apply patch
- Edit syspref 'StatisticsFields'. Verify that the explanation makes sense.
- Leave field empty
=> verify that no message appears on About page, tab System information
- Insert valid field names, e.g. location|itype
=> verify that no message appears on the About page
- Add trailing char
=> verify that the warning message appears on the About page
- Fill in some garbage or misspell a field name
=> verify that the warning message appears on the About page
Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 95f492b4d2505103269b295a34bab74804df9746) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Nick Clemens [Tue, 8 Mar 2016 22:04:32 +0000 (22:04 +0000)]
Bug 12663 - SCOUserCSS and SCOUserJS ignored on selfcheck login page
Currently if not logged in when browsing to
http://YOURCATALOG/cgi-bin/koha/sco/sco-main.pl
You are redirected to opac-auth.tt and SCOUserCSS and SCOUserJS are not
loaded. This page passes through a parameter to the template to indicate
this is an SCO login and appropriate CSS and JS should be loaded.
Additionally this patch ensure that when loggin in using the form you
are redirected to the sco-main.pl instead of the patron account page for
the user.
To test:
1 - Verify that normal login works on both staff and opac
2 - Verify that SCO link goes to login page if AutoSelfCheckAllowed is
set to "Don't allow"
3 - Enter changes into SCOUserJS and SCOUserCSS and observe these are
present on SCO log in page with AutoSelfCheck disabled
4 - Verify that a logged in opac user without permissions cannot access
the self-checkout module
5 - Verify that AutoSelfCheckAllowed and associated system preferences
function as expected
6 - Verify the AutoSelfCheck user is logged out if they attempt to visit
another page
Followed test plan.
If I go to http://YOURCATALOG/cgi-bin/koha/sco/sco-main.pl, CSS and JS trigger already on
the login form, I suppose that is intended. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit e476be5568d41bb06ce2fef5e8da6417cf9ed682) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Tue, 3 May 2016 07:58:33 +0000 (08:58 +0100)]
Bug 16426: follow-up of bug 15840 - correctly manage userid while inserting patrons
Bug 15840 tried to fix a bug but makes things more complicated than it
was before.
If an userid is not provided for 1 or more rows of the csv file, it
should not be updated. However, if a userid is provided and it already
used by an other patron, the import should fail for this row (but not
crash!).
Test plan:
0/ Create a patron with a userid=your_userid
1/ Use the import patron tool to update this userid
=> userid should have been updated
2/ Update another data and do not provide the userid
=> data should have been updated and not the userid
3/ Update another data and provide the userid, but set it to an empty
string, or '0'
=> data should have been updated and not the userid
4/ Update another patron, and set userid=your_userid
=> Update should fail and an error whouls be displayed ("already used by
another patron")
Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 7b76b24fad305b0253eb1d779f074d265087ca73) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Tue, 3 May 2016 07:58:26 +0000 (08:58 +0100)]
Bug 16426: Add tests for ModMember - do not update userid
Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit e883c19f3778c0247c11e6bdd3f27bbdd927468d) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Wed, 6 Apr 2016 14:59:02 +0000 (15:59 +0100)]
Bug 12752: FIX letter names in 3.15.00.041
3.15.00.041 was wrong, the name of the letter should not always been the
name of the first HOLD notice.
PREDUE_PHONE should be updated with the first name of the PREDUE notice,
same for OVERDUE_PHONE and OVERDUE
Signed-off-by: Chris Cormack <chrisc@catalyst.net.z> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 6d52cd63f351cd56f36492b80c10c0d8568ef03d) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Wed, 6 Apr 2016 15:35:23 +0000 (16:35 +0100)]
Bug 16217: Resync names of notices
Bug 12752 has fixed a bug for installations upgrading from 3.14, but has
not fixed the problem for new installations.
Because of some wrong data manipulations, the names for a given letter
code may diverge.
In particular OVERDUE and PREDUE names of phone notices have been
wrongly modify by bug 11867: they have been set to the name of the first HOLD
notice.
Trying to be back on our feet, this update DB entry will try to guess
and set back up the correct name.
To know if your install is affected by this bug, the following SQL query
can help you:
SELECT code, name, message_transport_type
FROM letter
WHERE code="PREDUE" OR code="OVERDUE";
If the names are different for the same code, something went wrong.
Executing this update DB entry should fix the divergence.
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Fix the problem, see comment #6 for test.
No koha-qa errors
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit f04e9919755c85b03c7016f838d747523c0effb5) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jacek Ablewicz [Thu, 28 Apr 2016 07:35:51 +0000 (09:35 +0200)]
Bug 16373: merge.pl reports success but files are not merged
To recreate:
1) Select two biblios to merge
2) Merge them
3) Sucess reported but list of bibs contains only the reference record.
4) View the 'new' record, it won't have any additional items
5) View the 'merged' record, it is still there with its items
This happens because record IDs (biblionumbers) are not correctly
set up in the template on the 2nd merge stage, since Bug 15358.
To test:
1) apply patch
2) try to recreate this issue once again, confirm that a problem
is resolved
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 404d9001febc47f53a89be349abd8628d75dd8f6) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Sophie Meynieux [Tue, 26 Apr 2016 16:04:45 +0000 (18:04 +0200)]
Bug 16356: Fix Error 500 when returning an item which itemtype is not in itemtypes table
Test plan :
* Find an item with itemtype (itype or bilbioitems.itemtype
depending on syspref) does not exist in itemtypes table
* If necessary, change itemtype of one of your item
* Check out this item
* Try to check it in, you've got a 500 Error and item is not
returned
With the patch
* Try to check your item in. Item is correctly returned
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Alex Arnaud [Tue, 19 Apr 2016 15:18:41 +0000 (17:18 +0200)]
Bug 16296 - Fix records displaying in virtualshelves
Test plan:
- Empty OPACXSLTResultsDisplay system preference,
- select a virtual shelf in the dropdown list "Lists" on navigation bar
(Or create one and add records),
- check that records are correctly displayed (title, author, publisher
etc...).
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Display is now correct
No errors
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 8c807b9466b005b2094320d7fabf07e9e91d3607) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Kyle M Hall [Wed, 20 Apr 2016 20:37:13 +0000 (20:37 +0000)]
Bug 16317 - Attempt to share private list results in error
When sharing a private list, the the receiver of the share link will get
the following error when they are logged in and try to click the link:
DBIx::Class::Storage::DBI::_dbh_execute(): Unknown column 'sharedate
desc' in 'order clause' at /home/koha/kohaclone/Koha/Objects.pm line 150
Test Plan:
1) Create a private list
2) Share that list to another account
3) Log in as the other account
4) Click the link in the email you recieved
5) Note the error
6) Apply this patch
7) Click the link again
8) You should see no error and be able to view the list!
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit ce47345c21930074a4ebf79f658d4a43b8944f6c) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Thu, 7 Apr 2016 08:45:58 +0000 (09:45 +0100)]
Bug 15757: Make GetLoanLength defaults to 0 instead of 21
GetLoanLength arbitrary defaulted to 21. The expected behavior seems to
be to default on 0 (loan will be dued today).
IMPORTANT NOTE: This patch will introduce a change in the behaviors for
configuration with a 0 in issuelength. Before this patch, the rule with
a issuelength==0 was skipped, now it's used!
Test plan:
1/ Do not define any rule: the due date will be today (before this patch
was +21 days)
2/ Define some rules which does not match the patron category, itemtype
or branchcode: the due date will be today (before this patch was +21
days).
3/ Modify a rule to match the checkout and set issuelength=0: the due
date will be today (before this patch, the rule was skipped)
4/ Modify this rule and set the issuelength to something > 0: the due
date will be adjusted (same behavior as before this patch)
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Works ok, checked 1-4
All test pass
No koha-qa errors
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 769728015cea465bbb47d27f69077962a8f2429d) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Thu, 7 Apr 2016 09:13:43 +0000 (10:13 +0100)]
Bug 15757: Make issuelength default to null instead of 0
When editing circ rules, if the Loan period "issuelength" is not defined
(empty string), the default value was 0, not it's inserted in the DB as
NULL.
Test plan:
1/ Create or edit a circ rule
2/ Do not fill the Loan period column
3/ Save
=> Without this patch, the value was 0
=> With this patch it's now an empty string (in the DB it's set to NULL)
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Works as described.
No errors
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit d46a664ef6b79f6ceee2c00629f5933b4eaedfc3) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Thu, 7 Apr 2016 08:44:51 +0000 (09:44 +0100)]
Bug 15757: Add one test for GetLoanLength
The usual call (3 params) of this subroutine was not tested.
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit d83aff33c603d1ba4d16de53ad926bd93a09629b) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Wed, 6 Apr 2016 10:33:11 +0000 (11:33 +0100)]
Bug 15930: Make patron searches defaulting on 'contain'
The default patron search types has changed from 'contain' to
start_with. Users consider it as a bug.
This patch revert the previous changes to default on 'contain'.
Test plan:
Search for patrons in different places (guarantor, checkout, patron
module, acquisition module, etc.) and confirm that the default is always
'contain'
Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Jesse Weaver <jweaver@bywatersolutions.com> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit a8491dc156db9d746b0f5ddd6175b66bf1bfa4ab) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Fri, 18 Mar 2016 13:31:27 +0000 (13:31 +0000)]
Bug 16104: Remove warnings "used only once: possible typo"
Since bug 11998, the following warnings are raised:
Name "Tie::Hash::FIELDS" used only once: possible typo at /usr/share/perl/5.22/fields.pm line 135.
Name "Cache::RemovalStrategy::LRU::FIELDS" used only once: possible typo at /usr/share/perl/5.22/fields.pm line 135.
Name "Cache::RemovalStrategy::FIELDS" used only once: possible typo at /usr/share/perl/5.22/fields.pm line 135.
Test plan:
perl -wc C4/AuthoritiesMarc.pm
should return green
QA note: this may have an impact on performance but I have not found any other workarounds.
NOTE: I applied 15870 to master, got the error (-v 2 -c 5), applied 16104,
rebased it in front, error disappeared (still only -c 5), rebased it at the end,
and signed off 16104.
Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit 6b319a2d487257e8a08bc26af9c6b2e7fa2ece2c) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Mason James [Fri, 1 Apr 2016 02:23:22 +0000 (15:23 +1300)]
Bug 1750 - Report bor_issues_top erroneous and truncated results.
Signed-off-by: Mason James <mtj@kohaaloha.com>
TEST PLAN
---------
1) Ensure you have some checkouts
2) Home -> Reports
-> Patrons with the most checkouts
3) Click 'Submit'
-- you get a list
4) Click a patron name.
5) Note the borrower number.
6) In MySQL run something like:
> UPDATE borrower SET firstname=NULL WHERE borrowernumber=####
7) Refresh the report page
-- name goes totally blank
8) apply patch
9) Refresh the report page
-- only first name is lost
10) run koha qa test tools
Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit b859739c2a6dc899176276022782ac3af7a0ad0c) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Setting X-Frame-Options to SAMEORIGIN is enough for mordern browsers:
https://developer.mozilla.org/en-US/docs/Web/HTTP/X-Frame-Options
The antiClickjack trick should be removed at the OPAC as we want to keep
the OPAC usable even if the user has disabled JS.
That means the OPAC will be vulnerable to XFS if a user is navigating
with a prehistoric browser:
Firefox 3.6.9 September 2010
IE 8 March 2008
Opera 10.5 March 2010
Safari 4 February 2009
Chrome 4.1.… somewhen 2010
Test plan:
Confirm that there are no regression of bug 15111 with modern browsers
Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit d496d03e8aa3079e0d29837b27b31b9a55afd02e) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Mon, 22 Feb 2016 09:24:29 +0000 (09:24 +0000)]
Bug 15111: Do not include the antiClickjack legacy browser trick for greybox
Most of the scripts called via greybox (which uses iframe) don't include
doc-head-close. But some do.
This patch adds a popup parameter for these templates, not to include
the legacy browser trick and avoid the replacement of the location.
Test plan:
1/ Export patroncard and label
2/ translate itemtypes
3/ click on a idref link at the OPAC
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit fc640d2a86f395ad392f84314bce22e8b4dab1fe) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Fri, 13 Nov 2015 08:19:57 +0000 (08:19 +0000)]
Bug 15111: Change X-Frame-Options with SAMEORIGIN
There are some places where frames are used, the greybox JS plugin for
instance.
We need either to allow them from Koha or replace this plugin.
The easier for now is to switch the value from DENY with SAMEORIGIN.
Test plan:
- modify a record in a batch (tools/batch_record_modification.pl)
- click on preview marc
=> With only the previous patch you will get a blank page.
=> With this patch apply, it will work as expected.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit fb167c0e4b897bf9a93b4fd6176b15e2d4dbd4df) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Kyle M Hall [Mon, 2 Nov 2015 17:11:17 +0000 (12:11 -0500)]
Bug 15111 - Koha is vulnerable to Cross-Frame Scripting (XFS) attacks
Web pages that can be embedded in frames are vulnerable to cross-frame
scripting attacks. Cross-frame scripting is a type of phishing attack
that involves instructions to an unsuspecting user to follow a specific
link to update confidential information in an online application.
Because the link leads to a legitimate page from the online application
that is embedded in a frame hosted by the attackers' server, the
attackers can capture all the information that the user enters.
https://www.owasp.org/index.php/Clickjacking_Defense_Cheat_Sheet Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit dc03bca76cf5b7cb48d98d1ce245fc65b98be929) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
can fail when $report_ids[0] is a substring of some saved_sql fields
from other reports (reports that have a different id than
$report_ids[0]).
We can only be sure that get_saved_reports will return at least 1
report.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit 08017f89f150394b6224fafb64fe8d12fc146ff1) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Mon, 4 Apr 2016 13:45:48 +0000 (14:45 +0100)]
Bug 16179: Do not crash if "rate me" is clicked and not rate selected
If JS is disabled and a user clicks on the "Rate me" button, Koha will
crashes with:
DBIx::Class::ResultSet::create(): Column 'rating_value' cannot be null
at /usr/share/koha/lib/C4/Ratings.pm line 208
To avoid that, opac-ratings.pl will check if a rate has been selected.
Test plan:
Disable JS
On a record detail page, click on the "Rate me" button
TESTED PLAN:
1) go to /cgi-bin/koha/opac-ratings.pl?biblionumber=1
-- kaboom as above.
2) apply patch
3) refresh
-- either login screen (don't know why)
-- or if already logged in, detail page.
4) koha qa test tool
Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Owen Leonard <oleonard@myacpl.org>
I tested successfully by temporarily removing the modification made by
Bug 16210.
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit b679cac96409b7248f8e224e10c73dafa4c82890) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Tue, 5 Apr 2016 08:13:05 +0000 (09:13 +0100)]
Bug 16055: Do not allow basketgroup deletion unless empty
If a basketgroup has basket attached, it should not be deletable.
This patch just removes the Delete button from the interface if it
cannot be deleted.
When editing a basketgroup, the "Delete basket group" button is no
longer displayed.
Test plan:
1/ Create a basketgroup
2/ Attach 1+ baskets to this basketgroup
3/ Confirm you are not able to delete it
4/ Remove the baskets from this basketgroup
5/ Confirm you are able to delete it
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit be33e1b46537d85b3d49abc076348916dd50004b) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Alex Arnaud [Tue, 16 Feb 2016 15:33:17 +0000 (16:33 +0100)]
Bug 15832 - Fix filter and items split-up in pendingreserves.tt
Test plan:
- Go to circ/pendingreserves.pl (Ensure that there are biblios with many
items on different branches),
- Check the libraries filter at the bottom of datatable. There should be
duplicates.
- Apply this patch and return to circ/pendingreserves.pl,
- check that libraries filter should not contain duplicate,
- check that the filter works.
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit 82be93af1ccbd3544646a6345ab51183a62d05cb) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Nick Clemens [Mon, 28 Mar 2016 20:01:30 +0000 (20:01 +0000)]
Bug 15682 - Merging records from cataloguing search only allows to merge 2 records
To test:
1 - Perform a cataloging search
2 - Attempt to merge 0 results - should fail
3 - Attempt to merge 1 resutls - should fail
4 - Attempt to merge 2 results - should succeed
5 - Attempt to merge 3 results - should succeed
6 - Test any other amount of records and if more than 1 it should
succeed
**Note: On shelves.pl you can merge a single record. I think that is
incorrect so made this only work for 2. Will add a followup to fix
shelves.pl
Signed-off-by: Chris Cormack <chrisc@catalyst.net.z> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit 8f1e5ad95fd78cbf09028e3d2dfe0b2b77d4dd21) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Bug 15113: koha-rebuild-zebra should check USE_INDEXER_DAEMON and skip if enabled
This patch changes the behaviour of the koha-rebuild-zebra script in the following way:
USE_INDEXER_DAEMON=no
- Keeps the current behaviour
USE_INDEXER_DAEMON=yes
- It skips incremental indexing to avoid races.
Caveats:
- A --force option is introduced for useing in a specific situtation that might need it
(i.e. the administrator knows what he's doing).
- If --full is passed, the reindexing is not skipped.
The documentation files and messages are adjusted accordingly.
This patch should help users that want to use the indexing daemon, in which case they wouldn't need
to change their default 5 min cronjob (it will be just skipped). Ultimately, koha-common could have
USE_INDEXER_DAEMON = yes by default, but that's subject for another bug report.
To test:
- Play with the different option switches and USE_INDEXER_DAEMON
- Things work as expected
- Sign off
Regards
Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as expected
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Your Full Name <your_email>
(cherry picked from commit 997ad166c6ea53d47e3e15e7720d63da9f3b0a80) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Julian Maurice [Thu, 7 Jan 2016 14:38:57 +0000 (15:38 +0100)]
Bug 14816: Fix multiple selection in item search
Send each selected value as a separate parameter. Otherwise DataTables
(or jQuery ?) joins all values with a comma
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
I could not reproduce the bug when selecting multiple home libraries,
but I could by selecting multiple item types or collection codes. The
patch allowed those queries to complete correctly.
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit 9aa8bf46f6b45ebcd342c09bd3a09ae55f3dd4a8) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Tue, 12 Apr 2016 08:24:18 +0000 (09:24 +0100)]
Bug 16240: (follow-up for 16082) Do not display message if no borrowernumber passed
"This patron does not exist" message should not be displayed on the
"Checkouts home page". The message should only be displayed if the
borrowernumber parameter is passed.
Test plan:
Go on circ/circulation.pl
=> No message
Go on circ/circulation.pl?borrowernumber=424242
=> You should see the message
Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit 8ec54c86feb92989807837d71f4c0a5e901e07e3) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit a96adaadb2c4bbf54ad8440164b73aa74a38cc96) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Add `api` folder to INTRANET_CGI_FOLDER in Makefile.PL so that the new
RESTFul API introduced in bug #13799 works also when installing with make.
Test plan:
- apply patch and do a `perl Makefile.PL` install
- observe that INSTALL_DIR/intranet/cgi-bin now has a folder `api`
containing the swagger files and the api cgi mount, app.pl.
Signed-off-by: Chris Cormack <chrisc@catalyst.net.z> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher <bredan@bywatersolutions.com>
(cherry picked from commit c20c70c99d79c0d02a37a0e41d0e90afb5c69681) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Nick Clemens [Fri, 26 Feb 2016 21:08:55 +0000 (21:08 +0000)]
Bug 15928 - Show unlinked guarantor
To test:
1 - Add guarantor data to patron account by typing it in but do not 'Set to patron'
2 - Note it is not displayed on patron details
3 - Apply patch
4 - Note the info is displayed
5 - Test that linked guarantors show as expected
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Julian Maurice [Thu, 14 Apr 2016 12:29:38 +0000 (14:29 +0200)]
Bug 15962: Block the currency deletion if used
A currency should not be deleted if used by a vendor or a basket.
Test plan:
1/ Add a new currency
2/ Create a vendor using this currency
3/ Create a basket using this currency
4/ Try to delete the currency
5/ Delete the basket
6/ Try to delete the currency
7/ Delete the vendor
8/ Delete the currency
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Marcel de Rooy [Fri, 4 Mar 2016 10:25:27 +0000 (11:25 +0100)]
Bug 13871: [QA Follow-up] Add $server for FID_SCREEN_MSG
When you are ready, you still see that small detail.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 617b72a54eb80fd7ea5e55be9484cf1dbf5e292f) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Marcel de Rooy [Sat, 27 Feb 2016 13:40:44 +0000 (14:40 +0100)]
Bug 13871: [QA Follow-up] Adjust Patron Info Request
Conform QA comment, Patron Info request is slightly adjusted to be
consistent with changes to Patron Status request.
If the cardnumber is ok and the password is wrong, BL=N is reported but
also add 'Invalid password' in AF.
Additionally, an invalid card number is reported in AF.
Test plan:
[1] Send patron info request for invalid card.
[2] Idem for valid card, no password.
[3] Idem for valid card, good password.
[4] Idem for valid card, wrong password.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Verified by telnetting SIP server.
And tested additionally with the new unit test of bug 15956.
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit b02aa7c4217ed75c42b95bd6af11a49472737144) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Marcel de Rooy [Sat, 27 Feb 2016 13:26:51 +0000 (14:26 +0100)]
Bug 13871: [QA Follow-up] Adjust Patron Status Request
Conform QA comment on Bugzilla, we do this:
[1] Attribute for overdrive mode/invalid credentials is not really needed.
We can always pass a screen message that card or password is invalid.
[2] If the cardnumber is correct and the password is wrong, we should
still honour the request. The bad password is recognized by BLN and
an additional message in AF.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Verified by telnetting SIP server.
And tested additionally with the new unit test of bug 15956.
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit a32a5c4e0843ec8e08e8c75118f648cbbfdb762c) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 8637627dc9c99b2f1e47b4748c7e4360dbaac5f1) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Mason James [Mon, 23 Mar 2015 01:30:26 +0000 (14:30 +1300)]
Bug 13871: [TITLE_AMENDED] Additional changes
The original perltidy patch from Mason has been amended.
The perltidy itself has been moved to a separate patch with the current
perltidyrc applied.
As noted on Bugzilla, the original perltidy patch included some extra
changes:
[1] You prefix timestamp with Sip
This is not actually needed (it is imported), but if we should prefix it,
we should prefix now with C4::SIP::Sip. But you only changed two
occurrences (out of 26). So I remove these two changes.
[2] You remove the $server parameter from two calls of maybe_add:
A closer look at the remaining code tells me that $server is always
passed to maybe_add for FID_SCREEN_MSG. So this only left me the
current whitespace change.
But at least we documented what we did or did not, and why..
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 42e731857d53134f91ecf0099ae6b7c13393166c) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Marcel de Rooy [Fri, 26 Feb 2016 08:42:13 +0000 (09:42 +0100)]
Bug 13871: Adjusted perl tidy on MsgType.pm
Run perltidy pro=xt/perltidyrc on the file.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit a5babb0effb760aa1d0d9de83ce8bb690099678c) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Marc Véron [Wed, 23 Mar 2016 07:11:49 +0000 (08:11 +0100)]
Bug 16133: Translatability of database administrator account warning
This patch removes sentence splitting of the database administrator warning with
a button styled link.
Additionally, it uses the same wording as in the warning on the 'About' page.
To test:
- Apply patch
- Log in to Staff client as database administration user
- Verify that the wording of the warning is the same as on the About page (Tab
'System information')
- Verify that the link to the patron administration page is styled as a button
and behaves correctly
NOTE: Actually, the category is irrelevant. But I like the improved message.
Categories may or may not be set up at the initial log in.
Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit e53b80dedf91617f9eecb9defd2d6f5222f03d65) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Owen Leonard [Mon, 14 Mar 2016 16:41:58 +0000 (12:41 -0400)]
Bug 16027 - Use Font Awesome icons in the professional cataloging interface
The professional cataloging interface uses Glyphicons. They should be
replaced with Font Awesome icons.
I have replaced the "Import record" icon as per the discussion on Bug
15966 about which icon better expresses import vs. export.
To test, apply the patch and go to Cataloging -> Advanced editor.
- Confirm that the icons in the toolbar look correct.
- Click the "Macros" button and confirm that toolbar buttons in the
modal look correct.
- Click the "Advanced" link in the left-hand sidebar and confirm that
the buttons in that modal look correct.
- Click the "Save" button without adding anything to the blank record.
Confirm that the "Missing..." error messages are styled with the
correct icon.
Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 5fb78052f4e3cd3bb5562fcc2471628438a0fe77) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Owen Leonard [Wed, 9 Mar 2016 15:27:03 +0000 (10:27 -0500)]
Bug 16025 [Revised] Use Font Awesome icons on item types localization page
The item types localization page uses a Glyphicon. This patch converts
it to a Font Awesome icon.
Also changed in this patch: "Delete" text has been added to the delete
link, and a dummy "href" attribute has been added to the link so that it
triggers the right kind of cursor. The deletion confirmation JavaScript
has been edited to ignore the default click action.
To test, apply the patch and go to Administration -> Item types.
- Edit any existing item type and click the "Translate into other
languages" link.
- If there is not an existing translation, add one. Close the modal
window and click the "Translate into other languages" link again to
redisplay it.
- Confirm that there is a "Delete" link next to your translation which
is styled correctly.
- Confirm that the behavior of the "Delete" link is correct both when
confirming and when canceling.
Revision adds the "actions" class to the table cell with the delete link
to prevent a line break between the icon and the text.
Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
(cherry picked from commit dfb8982ca79595297c7430243ad90b77e21d8a67) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Aleisha [Sun, 20 Mar 2016 23:37:38 +0000 (23:37 +0000)]
Bug 15861: Isolated 'The' in help files untranslatable
Changes made:
help/reports/reports-home.tt
Line 11: Koha database schema: shows the entire Koha database structure so that you can write effective SQL Queries
Line 12: Koha reports library: lists reports written by Koha users around the world.
help/rotating_collections/rotatingCollections.tt
Line 7: Important: AutomaticItemReturn (system preference) must be set to ..
TEST PLAN
---------
1) Log in to staff client
2) Click 'Reports'
3) Click 'Help'
-- Notice the two lines starting with 'The'
4) Click 'Tools'
5) Click 'Rotating collections' in the Catalog column
6) Click 'Help'
-- Notice the Important has a 'The'
7) Apply patch
8) Repeat steps 2-6
-- Notice the wording has changed to eliminate 'The'
9) Run koha qa test tools
Sponsored-by: Catalyst IT Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
(cherry picked from commit b72f9b8c51eb11861b931f193628460e2219a4fc) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Owen Leonard [Wed, 9 Mar 2016 15:02:08 +0000 (10:02 -0500)]
Bug 16023 - Use Font Awesome icons on audio alerts page
The audio alerts management page uses Glyphicons in a few places. This
patch replaces them with Font Awesome icons.
To test, apply the patch for Bug 15886 if necessary and enable
the AudioAlerts system preference.
- Go to Administration -> Audio alerts
- Confirm that icons for "Edit" and "Delete selected" look correct.
- Edit an existing alert and confirm that the "play" button looks
correct and works correctly.
Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
(cherry picked from commit 5d266693edc042c0a2f795588058ae8b3d12da22) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Owen Leonard [Thu, 17 Mar 2016 13:08:39 +0000 (09:08 -0400)]
Bug 16047 [Follow-up] Software error on deleting a group with no category code
This follow-up take the original patch a little further, making category
name required on the entry form as well. Without a category name there
is no label in the interface when selecting a category. That doens't
make any sense.
Also changed on the group entry form:
- Added "required" attribute to labels on required fields.
- Changed "Update" submit button label to "Submit."
- Added a "Cancel" link.
- Added the "validated" class to the form so that our built-in
validation script will process it (not strictly necessary but makes
the validation appearance more consistent).
Followed test plan, form displays and behaves as expected. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
(cherry picked from commit df127ebad814ad1710b161b85a69d408de95de85) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Aleisha [Thu, 10 Mar 2016 21:49:57 +0000 (21:49 +0000)]
Bug 16047: Making category code a required field on creating a group
This will prevent users from creating a group without a category code,
which causes a software error when you try to delete it
To test:
1) Go to Admin -> Libraries and groups
2) Create new group without category code
3) Attempt to delete the group you just created and notice software
error
4) Apply patch
5) Create new group without category code
6) Notice you now cannot save the group without putting in a category
code
Sponsored-by: Catalyst IT Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
(cherry picked from commit 577aa86eb96160088c70008bfe85ae2c0820f547) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Aleisha [Sun, 13 Mar 2016 23:40:53 +0000 (23:40 +0000)]
Bug 16029: Hide patron toolbar if patron does not exist
To test:
1) Create a patron, take note of the borrower number
2) Delete the patron
3) Navigate to the page of the patron you just deleted by typing the url (ie /cgi-bin/koha/members/moremember.pl?borrowernumber=X)
4) Confirm that the patron toolbar is not showing on the page
5) The message now has a link that says 'Find another patron?'. Click this link and confirm you are taken to the member home pgae.
Sponsored-by: Catalyst IT
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 Gallagher brendan@bywatersolutions.com
(cherry picked from commit 1870141874667d854f9b5508c563169baefb2328) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Owen Leonard [Fri, 18 Mar 2016 13:41:15 +0000 (09:41 -0400)]
Bug 15984 - Correct templates which use the phrase "issuing rules"
This patch corrects two places in the templates where the phrase
"issuing rules" is used instead of "circulation and fine rules."
To test, apply the patch and view the help pages for Administration ->
Circulation and fine rules; and Tools -> Automatic item modification by
age. Confirm that the term "circulation and fine rules" is used instead
of "issuing rules."
Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
(cherry picked from commit 98a9e30f040661e0a67a594f72abd8ab02cf9ad6) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Fri, 12 Feb 2016 11:49:28 +0000 (11:49 +0000)]
Bug 14076: Do not use CGI->param in list context - opac-authorities-home.pl
See bug 15809 for more info on why we should not use CGI->param in list
context.
Note: I have not found any places where several values for the same
params are passed to this script but, just in case, this patch won't
change this ability.
Test plan:
Do an authority search at the OPAC
Test with several values of the form.
Confirm that the results are always the same before and after this
patch.
Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
(cherry picked from commit 3fa2b10150a9ea2db2897be1246cba3785c55e55) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Jonathan Druart [Fri, 12 Feb 2016 11:32:02 +0000 (11:32 +0000)]
Bug 15809: Redefine multi_param is CGI < 4.08 is used
On debian Jessie, the CGI version is >= 4.08
Since this version, the param method raise a warning
"CGI::param called in list context".
Indeed, it can cause vulnerability if called in list context
There is a long journey to get rid of these warnings.
First I suggest to redefine the multi_param method when the CGI version
installed is < 4.08, it will allow us to move the wrong ->param calls to
->multi_param without waiting for everybody to upgrade.
The different ways to call these 2 methods are:
my $foo = $cgi->param('foo'); # OK
my @foo = $cgi->param('foo'); # NOK, will raise the warning
my @foo = $cgi->multi_param('foo'); #OK
$template->param( foo => $cgi->param('foo') ); # NOK, will raise the warning
# and vulnerable
$template->param( foo => scalar $cgi->param('foo') ); # OK
Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Tested a call to multi_param with CGI < 4.08.
With reference to the comments on Bugzilla, this workaround is arguable,
but provides a base to move to multi_param. If we come up with a better
solution, it should be easy to adjust.
Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
(cherry picked from commit 94dde6b48d6e20a5260ea49f9b98ec884c2c25b5) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Aleisha [Thu, 17 Mar 2016 22:34:08 +0000 (22:34 +0000)]
Bug 15421: Show 'Duplicate' and 'Schedule' on Reports toolbar
To test:
1) Go to Reports -> Use saved
2) Click 'Show' on the dropdown for any report
3) Confirm that 'Duplicate and 'Schedule' are now on the toolbar and work as expected
Sponsored-by: Catalyst IT Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan Gallagher brendan@bywatersolutions.com
(cherry picked from commit a9d7292a103918ecddcfabc430ea07cdd3513148) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Mason James [Fri, 1 Apr 2016 02:56:34 +0000 (15:56 +1300)]
Bug 16184 - Report bor_issues_top shows incorrect number of rows
TEST PLAN
---------
1) Have at least 6 patrons with checkouts and some checkins.
2) Reports -> Patrons with the most checkouts
3) Click 'Submit' (default is 5)
-- more than 5 entries listed.
4) Apply patch
5) Refresh page
-- only 5 entries listed.
6) Run koha qa test tools
NOTE: While this works, I'd be much happier with a refactor
as it would also speed up the report. See comment #5.
Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 2c68980467009a9d19116440d4f28356707e9e7c) Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>