Bug 12593: search facets die with regex error if biblio has square brackets in fields
It's quite common to have [something] within facet data, and it produces following error:
Unmatched [ in regex; marked by <-- HERE in m/^[ <-- HERE
This problem was intoduced in Bug 12151 but is trivial to fix.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Good catch.
To test:
- Created a bibliographic record, linked to an authority record (personal name). Did a search that returned the author as a facet.
- Added a [ symbol to the author name.
- Repeated the search
=> FAIL: "Unmatched [ in regex; marked by <-- HERE in m/^[ <-- HERE"
- Apply the patch
- Retry the search
=> SUCCESS: No error, bracket shows correctly.
Passes koha-qa.pl too.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12592 - Minor correction for C4::DelBiblio documentation
The function header says that DelBiblio checks to make sure there aren't
any issues on any of the items. What the code does, on the other hand,
is to check whether biblio has any items attached, and refuses to
delete biblio if it has any.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Jonathan Druart [Thu, 17 Jul 2014 08:50:30 +0000 (10:50 +0200)]
Bug 11349: (qa follow-up) Fix pod
FAIL cataloguing/value_builder/unimarc_field_125.pl
FAIL pod
*** ERROR: empty =head1 in file cataloguing/value_builder/unimarc_field_125.pl
*** ERROR: Spurious text after =cut in file cataloguing/value_builder/unimarc_field_125.pl
FAIL cataloguing/value_builder/unimarc_field_126b.pl
FAIL pod
*** ERROR: empty =head1 in file cataloguing/value_builder/unimarc_field_126b.pl
*** ERROR: Spurious text after =cut in file cataloguing/value_builder/unimarc_field_126b.pl
FAIL cataloguing/value_builder/unimarc_field_225a.pl
FAIL pod
*** ERROR: =over on line 40 without closing =back (at head1) in file cataloguing/value_builder/unimarc_field_225a.pl
*** ERROR: empty =head1 in file cataloguing/value_builder/unimarc_field_225a.pl
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This patch just adjusts several POD stuff, and in a few cases
reorganizes a hash definition in order to use spaces instead of tabs
for the QA script to be happy.
Nothing important, really. This patch series just changes '.tmpl' for
'.tt'.
Regards
To+
PS beware that running the koha-qa.pl script can take lots of time on this one
:-D
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Since all scripts use the '.tt' sufix for template names
there's no need for and regexp that changes from '.tmpl'
to '.tt'.
Regards
To+
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 11349: Change .tmpl -> .tt in scripts using templates
Since we switched to Template Toolkit we don't need to stick with the
sufix we used for HTML::Template::Pro.
This patch changes the occurences of '.tmpl' in favour of '.tt'.
To test:
- Apply the patch
- Install koha, and verify that every page can be accesed
Regards
To+
P.S. a followup will remove the glue code.
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Fridolin Somers [Tue, 17 Jun 2014 14:38:54 +0000 (16:38 +0200)]
Bug 12438 - Bad encoding in acquisition basket
We noticed a bad encoding (diacritics replaced by <?>) in acquisition basket when updating a server to Debian Wheezy.
We found it comes from a query containing biblio.title twice.
Maybe the mysql newer version creates this side-effect.
Test plan :
- Create an order on a record containing a diacritic in title
- Look at the basket : cgi-bin/koha/acqui/basket.pl?basketno=x
=> Without the patch the record title is bad encoded (with <?>)
=> With this patch the record title is well encoded
- Check also basket CSV export
Signed-off-by: Paola Rossi <paola.rossi@cineca.it> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Good catch!
Works as expected, passes tests and QA script. Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Duplicated biblio.title is a (minor) bug, and should be removed.
The side-effect of it solving an encoding problem might be seen
as problematic: it hides a real problem.
The efforts on 11944 actually solve this encoding problem (11944
merged into master actually fixes this), so I'm pushing it, for
a short term solution for stable, with the hope that we will soon
have 11944 pushed.
BTW, non-diacritic but non-ASCII characters are not broken either.
Colin Campbell [Thu, 15 May 2014 11:24:57 +0000 (12:24 +0100)]
Bug 12263: Fix startup issues blocking response to HUP
If you do a kill -s HUP sipserver_pid the server process
should restart its children.
This was not happening although it was logging the commencement
of the process.
Removed traces of Exporter usage this was always incorrect
this program inherits from Net::Server 'use base' to make inheritance
clearer. Removed unnecessary begin block
made file executable so it can run
added a shebang line so OS knows to invoke perl to compile and run
the file.
I've removed the debug code dumping the config to STDOUT,
it should not have gone into the production version.
One of the first things this program does is close stdout etc and
reopens the sip sockets to them. Assuming you can print to them other
than as part of the sip dialogue is not always safe.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
David Cook [Mon, 20 Jan 2014 00:54:26 +0000 (11:54 +1100)]
Bug 11575 - OPACBaseURL sometimes set by ENV variable and not system preference
This patch changes how the OPACBaseURL parameter gets set in the subroutine
get_template_and_user in Auth.pm.
Currently, it's being set by the $ENV{'SERVER_NAME'} variable. In many
cases, this will probably match the URL that the user uses to access a
page. However, this causes problems with reverse proxies.
There are ways to compensate for proxy servers (such as inspecting
other variables set by the web server), but such a solution seems
a bit convoluted...especially since we already use the system preference
OPACBaseURL in many other parts of Koha.
We probably shouldn't be passing OPACBaseURL from Auth.pm at all, and
instead use the Koha TT plugin and using_https param to determine
protocol. However, that's outside the scope of this bug/patch.
This patch is just meant to fix an existing bug.
I did leave the $ENV{'SERVER_NAME'} as a full back if OPACBaseURL isn't
set, but that's it.
_TEST PLAN_
Before applying:
1) Clear your OPACBaseURL preference
2) Perform a search in the OPAC
3) Click on or hover over the orange RSS icon
4) Note that the URL used for the RSS links is either:
a) The same URL you used to access Koha (no reverse proxy)
b) The ServerName from your Koha apache conf which isn't the
same URL you used to access Koha (reverse proxy)
5) Add an OPACBaseURL that isn't the same as the actual OPAC URL
6) Note that the OPACBaseURL system preference has no effect here
After applying the patch:
7) Refresh the page
8) Note that the URL you see now is actually the OPACBaseURL system
preference that you set
9) Clear your OPACBaseURL system preference
10) Refresh your search page
11) Note that the URL has reverted back to the URL that you saw before
(either the original Koha site URL or the Koha ServerName defined
in Apache and not the URL of the proxy)
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Kyle M Hall [Thu, 25 Oct 2012 11:48:15 +0000 (07:48 -0400)]
Bug 12377 - Add date pickers to serials-edit.pl
There are two date fields when receiving serials on serials-edit.pl,
these inputs should have a calendar widget like other date fields
in Koha.
Test Plan:
1) Apply this patch
2) Recieve a serial
3) Note when clicking on the "Published on" or "Expected on" fields
you will now have a calendar popup. Note you can still manually
edit the date if you wish to.
Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
being evaluated in list context inside $template->param() call arguments.
Signed-off-by: Christopher Brannon <cbrannon@cdalibrary.org> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Jacek Ablewicz [Wed, 11 Jun 2014 06:51:34 +0000 (08:51 +0200)]
Bug 10519: Suggestions: 'Organize by' and correct display of tab descriptions broken
The tabbed display in suggestions offers different options to organize
the tabs. The descriptions on the tabs and some of the search options were
not working correctly, displaying as "Unknown".
To test:
- Add several suggestions to your installation, make sure you have:
- suggestions from different users
- suggestions managed by different users
- suggestions with different statuses
- suggestions with different selected item types
Test all the 'organize by' options (except "Organize by: Library"
- see note below), make sure that the tabs and search options
have correct descriptions and do no longer display as "Unknown".
- Add 1 or 2 custom status to SUGGEST_STATUS authorized value.
- Verify display is still correct and your new status are displayed.
Note: "Organize by: Library" option is currently severely broken
(and not easily fixable, especially for 'IndependentBranches'
enabled). But this turns out to be a separate issue, with a different
underlaying causes, and it's outside the scope of this patch.
This should be dealt with later, in it's own bug report.
Signed-off-by: Christopher Brannon <cbrannon@cdalibrary.org> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Jonathan Druart [Wed, 19 Feb 2014 12:37:40 +0000 (13:37 +0100)]
Bug 11744: Add regression tests
Before the patch:
prove t/db_dependent/Acquisition/CancelReceipt.t
returns 1 failure.
After the patch, the 2 tests pass.
Signed-off-by: marjorie barry-vila <marjorie.barry-vila@ccsr.qc.ca> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Yay! Regression tests!
Jonathan Druart [Wed, 19 Mar 2014 11:54:15 +0000 (12:54 +0100)]
Bug 11744: A receipt should not be cancelled if holds exist
Test plan:
1/ Set acqCreateItem pref to on receiving
2/ Receive 1 of 2 items ordered
3/ Place a hold on the record
4/ Verify you are not able to cancel the receipt.
This is not the best way to do that but it is the easy one.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Jonathan Druart [Wed, 19 Feb 2014 12:39:39 +0000 (13:39 +0100)]
Bug 11744: Cancel a receipt does not delete items created on receiving
If items is created on receiving, cancel a receipt should delete them.
The code only manage the case if the order is a child of another order
(partial).
To reproduce:
1/ Set AcqCreateItem to receiving
2/ Order one or more item(s)
3/ Receive the order and verify the item is created
4/ Cancel the receipt
5/ The item is not deleted
Test plan:
1/ Apply this patch and do again previous steps. The item should not be
deleted at step 5.
2/ Set AcqCreateItem to ordering and verify the item is not deleted.
Signed-off-by: marjorie barry-vila <marjorie.barry-vila@ccsr.qc.ca> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Jonathan Druart [Wed, 9 Jul 2014 07:49:19 +0000 (09:49 +0200)]
Bug 11226: subscription frequencies and numbering patterns should be editable with serials permissions
Bug 7688 does now allow patrons with serials permissions to edit
subscription frequencies/numbering patterns.
Test plan:
Try to access to serials/subscription-frequencies.pl and
serials/subscription-numberpatterns.pl with the "serials" permissions.
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
With patch and only serial permissions can now access
frequences and patterns.
No koha-qa errors
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 8773 - Start per-instance koha-index-daemon in .deb setup
Short:
Launch an indexing daemon (rebuild_zebra.pl -daemon) process for each
enabled instance. Enabling/disabling the use of the indexer is handled
by global configuration variables in /etc/default/koha-common.
Also provides command line tools to manage the running indexer daemons
for your instances.
Long:
Using an indexing daemon avoids launching a new interpreter each time
the cron triggers the indexing, and also allows sub-minute incremental
reindexing, a requirement from our librarians.[1]
Using the indexer daemon could remain "experimental" until it gets more
testing; so is disabled by default initially. To enable the use of the
indexer the user has to tweak the /etc/default/koha-common config file.
Specifically the USE_INDEXER_DAEMON variable, which is clearly explained
in the file.
Frecquency defaults to 5 sec, and can be changed by tweaking the
/etc/default/koha-common config file too.
This patch uses rebuild_zebra.pl in daemon mode, but it is crafted to
allow changing the indexing daemon and passing specific option switches
it might need.
Regards
To+
[1] This is the .deb version of http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8519
Sponsored-by: Universidad Nacional de Cordoba Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12265: [QA Follow-up] Replace DBIx search by find
This patch replaces DBIx search by find at two places in z3950servers.pl.
Furthermore, it adds testing on the results of the find method, passing
a not-found-message to the template whenever needed.
The function ServerSearch is adjusted to use HashRefInflator instead of
manually mapping the columns of result objects.
An additional defined-test in _form_data_hashref prevents shifting of
names and values in the result hash.
Test plan:
List all servers. Edit, copy and delete a server.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Marcel de Rooy [Mon, 12 May 2014 13:28:41 +0000 (15:28 +0200)]
Bug 12265: Improve Z39.50 servers administration
This patch makes a few tiny improvements on the form, does some
housekeeping/tidying up, and replaces SQL code by DBIC statements.
In detail:
- Adds an id parameter (more precise than searchfield).
- With the move from searchfield to id, you can rename a server now.
- A Copy button is added to clone a server.
- Confirming a delete is moved to javascript. No additional form anymore.
- A message about an insert, update or delete is shown in a div dialog
alert above the table instead of a separate form.
- Remove offset parameter, Next/Prev button and associated logic.
- All SQL statements are replaced by DBIC.
- Function StringSearch is renamed to DBICified ServerSearch.
- Remove tabs from script and template. Adjust some indentation.
Test plan:
- Test adding, editing and deleting Z3950 servers.
- Test searching for a server with the top search box (not table).
- Add a server with quotes in the name. Search for it. Edit or delete.
Followed tet plan. Patch behaves as expected. Signed-off-by: Marc Veron <veron@veron.ch> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12534 - PROG/CCSR deprecation: Make getlanguages() theme independent for opac
This patch removes a reference to prog theme on getlanguages()
when ENV var HTTP_ACCEPT_LANGUAGE is checked.
Changed to use sysprefs to find theme for opac and intranet
To test:
1) Apply the patch
2) Translate for a couple of languages: de-DE, fr-FR, es-ES, etc
3) Enable those languages for OPAC on I18N prefs
4) Using Firefox, clean all history/cookies
5) Change variable intl.accept_languages (will do several times)
a) got to about:config
b) search 'lang'
c) look for the variable, double click, change to 'de-DE'
6) Go to opac page, must load in german
7) Repeat for each translated lang: clean > change val > reload opac
On each case opac must load on configured language
8) Just to test, set variable on untranslated lang, opac page
must load on first value of list of enabled languages
9) prove t/Languages.t
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Yohann Dufour [Tue, 24 Jun 2014 12:27:21 +0000 (14:27 +0200)]
Bug 12470: adding unit tests for the routines CheckValidBarCode and CheckIfIssuedToPatron of the module C4::Circulation.pm
The routines CheckValidBarcode and CheckIfIssuedToPatron were not tested
Test plan:
1/ Apply the patch
2/ Execute : prove t/db_dependent/Circulation/CheckValidBarcode.t t/db_dependent/Circulation/CheckIfIssuedToPatron.t
3/ The result of the command has to be a success without error or warning :
t/db_dependent/Circulation/CheckValidBarcode.t ...... ok
t/db_dependent/Circulation/CheckIfIssuedToPatron.t .. ok
All tests successful.
Files=2, Tests=32, 3 wallclock secs ( 0.04 usr 0.01 sys + 2.88 cusr 0.17 csys = 3.10 CPU)
Result: PASS
Owen Leonard [Wed, 2 Jul 2014 13:10:33 +0000 (09:10 -0400)]
Bug 12517 - Download and send list popups broken in bootstrap OPAC
A JavaScript error prevents the download list and send list links in the
bootstrap OPAC from functioning correctly. A variable declaration was
removed from basket.js during the creation of the theme but
opac-shelves.tt was not changed accordingly. This patch corrects it.
To test, view an existing shelf in the bootstrap OPAC and test the
"download list" and "send list" links. They should each trigger popups
without any errors.
David Cook [Thu, 3 Jul 2014 06:32:57 +0000 (16:32 +1000)]
Bug 12522 - Fatal database error when viewing Holds for Bib with no Items
This patch fixes some potential SQL syntax errors, which can cause
fatal software errors in Koha when the environmental variable DEBUG
is on.
_TEST PLAN_
Before applying:
0) Ensure that you don't have "SetEnv DEBUG 1" in your Apache config
1) Create a new bib record
2) Click on the "Holds" tab before creating any items
3) Note the message "Cannot place hold: this record has no
items attached."
4) Add "SetEnv DEBUG 1" to your Apache config
5) Restart Apache
6) Refresh your page
7) Note the following Software Error: "DBD::mysql::st execute failed:
You have an error in your SQL syntax; check the manual that
corresponds to your MariaDB server version for the right syntax to
use near ')' at line 3 at /koha/lib/C4/Koha.pm line 835.
8) Apply the patch
9) Refresh your page
10) Note the message from Step 3
Thorough tester:
11) Remove "SetEnv DEBUG 1" from your Apache config, restart Apache,
and refresh your page. You should see the message from Step 3.
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Error reproduced, patch fixes it.
Tested following test plan, no koha-qa errors.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12558: (follow-up) remove old versions of schema classes for two tables
The newer version of DBIx::Class::Schema::Loader tweaks
how it maps plural table names to class names. As a consequence,
two (currently-unused) classes are renamed.
Signed-off-by: Galen Charlton <gmc@esilibrary.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12558: Require DBIx::Schema::Loader v0.07039 or higher
This patch shifts required DBIx::Schema::Loader to a newer
version to take advantage of improved smarts about foreign
key relationships.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com> Signed-off-by: Yohann Dufour <dufour.yohann@gmail.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Update DBIx::Class schema classes to use a newer
version of DBIx::Class:Schema::Loader.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com> Signed-off-by: Yohann Dufour <dufour.yohann@gmail.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 12307: Catalog details page displaying incorrect status for items with itemtype level notforloan status
The template markup that controls that status column for
the items table in catalogue/detail.pl does not account
for the itemtypes.notforloan flag.
Test Plan:
1) Find an item that is currently available
2) Go to the itemtype editor and mark that itemtype of that item
as being not for loan
3) Browse to the catalog details page for that item's record
4) Note the item status is still "Available"
5) Apply this patch
6) Reload the catalog details page
7) Note the item status is now "Not for loan"
Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Good catch! Works as described, no problems found.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12508: adding an error message if a contract cannot be removed
If a contract cannot be removed, no errors is displayed. Now, it displays an dialog messag error and the list of contracts.
Test plan:
1) Log on with a superlibrarian permission
2) Go on the page acqui/supplier.pl (Acquisitions > Button "New vendor")
3) Record a vendor with a nonzero "name"
4) Go on the page admin/aqcontract.pl (click on the "Contracts" item in the menu)
5) Click on the button "New" > "Contract" and record a new one
6) Click on "New" > "Basket" and record a basket by selectioning the created contract
7) Click on the contract name, then click on the "Contracts" item in the left menu
8) Try to delete this contract, an error is displayed : "Contract has not been deleted. Maybe a basket linked to this contract exists."
9) Delete the basket linked to the contract
10) Delete the contract, no errors is displayed
Signed-off-by: Juhani Seppälä <jseppal@student.uef.fi> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes QA script an tests.
Also tested adding, editing and deleting unused contracts.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Viktor Sarge [Mon, 16 Jun 2014 12:09:10 +0000 (13:09 +0100)]
Bug 12332: Fix for tab "Purchase suggestions" not lighting up
This patch changes the file purchase-suggestions.pl with "suggestionsview => 1" for the template parameter.
In circ-menu.inc i changed the condition from "suggestions" to "suggestionsview" since it seemed to conflict with the existing variable suggestions (and in that case only highlighting the tab when there were suggestions).
Please note that I fixed the troubles with the tab "Fines" in a separate patch 9245.
Test plan:
1) Verify that "Purchase suggestions" does not light up as it should when clicked.
2) Install the patch.
3) Verify that the tab "Purchase suggestions" now actually light up when clicked.
Signed-off-by: Christopher Brannon <cbrannon@cdalibrary.org> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Works as advertised.
Viktor Sarge [Mon, 16 Jun 2014 11:21:06 +0000 (12:21 +0100)]
9245 Fixes visual bux with fines tab not highlighting
This patch makes shure that mancredit.pl, maninvoice.pl and pay.pl passes the value "finesview=1" that makes the tab active.
Test plan:
1) Go to a library user and the fines tab. Note that the "Fines" tab loses it's highlight when you click "Pay fines", "Create manual invoice" and "Create manual credit".
2) Install the patch.
3) Redo the first step and make shure that the left menu tab "Fines" is now highlighted all the time.
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Works as advertised, no regression found on the rest of the tabs.
Bug 11030 - Add 359, 947 and 969 fields in french unimarc_complete framework - followup
Signed-off-by: Gaetan Boisson <gaetan.boisson@biblibre.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Mathieu Saby [Wed, 9 Oct 2013 18:28:27 +0000 (20:28 +0200)]
Bug 11030 : add fields 947,969,359 in unimarc_complete french framework
This patch must be tested on top of bug 11021
This patch adds 3 fields to unimarc_complete french framework
- 359 (2-a-b-c-d-e-f-g-h-i-p-u-v) used by Sudoc network, to be displayed in tab 3
- 947 (c) used by Electre
- 969 (a-h) used by Electre
I don't know the difference between 969a and 969h so I gave them quite the same name
To test :
1) take a fresh Koha with unimarc marcflavor
2) in web installer, select french language, unimarc marflavor and "Grilles de catalogage complètes".
3) check default framework in Administration > MARC Frameworks : it should contains 359/947/969 fields
Signed-off-by: Gaetan Boisson <gaetan.boisson@biblibre.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Owen Leonard [Mon, 30 Jun 2014 14:12:06 +0000 (10:12 -0400)]
Bug 12429 [OPAC] patron seeing fines codes
Bug 2546 introduced translatable handling of Koha account type codes but
missed several codes. This patch adds handling of these codes to the
bootstrap OPAC.
This patch also corrects a couple of instances of incorrect
capitalization.
To test, apply the patch and log in to the OPAC as a user who has
existing fines and charges. View the "Your fines" page. You should not
see any account type codes like CR, LR, or FU.
Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Owen Leonard [Fri, 27 Jun 2014 18:21:03 +0000 (14:21 -0400)]
Bug 12429 [staff client] patron seeing fines codes
Bug 2546 introduced translatable handling of Koha account type codes but
missed several codes. This patch adds handling of these codes to the
staff client.
This patch also corrects a couple of instances of incorrect
capitalization.
To test, apply the patch and view fines page (Patron details ->
Fines) and the pay fines page (Patron details -> Fines -> Pay fines).
You should not see any account type codes like CR, LR, or FU.
Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Janusz Kaczmarek [Fri, 31 Jan 2014 14:09:07 +0000 (15:09 +0100)]
Bug 11650: multiplicated authorities after link_bibs_to_authorities.pl
Under certain circumstances misc/link_bibs_to_authorities.pl creates
multiple authority with identical heading.
Test plan:
1. Have some (2-3) biblio records with some repeated headings
Have BiblioAddsAuthorities = allow, AutoCreateAuthorities = generate
Have no authority records
2. Run misc/link_bibs_to_authorities.pl script
3. You will get multiple authority records -- one for each occurence of a
heading in biblio record.
4. Apply the patch.
5. Repeat 1-3 (remember to have "fresh" biblios, without $9, and no
authorities).
6. The problem should be fixed.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Works as described.
David Roberts [Mon, 30 Jun 2014 11:22:46 +0000 (12:22 +0100)]
Bug 12495 - Include streetnumber in hold alert address
Steetnumber is not included in the addess in the hold alert add the
field to those displayed
To test this, place a hold on an item that is on-loan, having first made
sure that the requesting user has a value in the street number field of
his address. Check the item in, and an alert should appear giving the
name and address of the requesting user. This address should include the
contents of the street number address field.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
I was able to confirm three of the four template changes for the
following cases:
- Item placed on hold for a patron at the current library, not waiting
- Item placed on hold for a patron at the current library, already
waiting
- Item placed on hold for a patron at another library, not waiting
I don't know how to trigger the case [% IF ( diffbranch ) %].
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes QA script and tests.
Note: Maybe sample slip templates should also include street number?
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Kyle M Hall [Tue, 1 Jul 2014 15:29:56 +0000 (11:29 -0400)]
Bug 12511 - Novelist Select not using https in bootstrap
In prog we have:
[% IF ( NovelistSelectProfile ) %]
<script type="text/javascript"
src="https://imageserver.ebscohost.com/novelistselect/ns2init.js"></script>
[% END %]
but in bootstrap we have
[% IF ( NovelistSelectProfile ) %]
<script type="text/javascript"
src="http://imageserver.ebscohost.com/novelistselect/ns2init.js"></script>
[% END %]
Because bootstrap isn't using https, we get an error like this:
[blocked] The page at
'https://koha.mylibrary.com/cgi-bin/koha/opac-detail.pl?biblionumber=105315&query_desc=kw%2Cwrdl%3A%20home'
was loaded over HTTPS, but ran insecure content from
'http://imageserver.ebscohost.com/novelistselect/ns2init.js': this
content should also be loaded over HTTPS.
Test plan would require having a subscription to Novelist Select.
I think this is trivial enough to go without.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Very small change, trusting Kyle and the sign-off here.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12062: Follow up to fix more untraslatable cases
This patch modifies staff printslip.tt to take into account
caller. Also fixes similar problem on opac printslip.tt
To test:
staff
1. Print hold transfer slip
2. Print transfer slip
3. Print member slip
opac
4. Print self checkout slip
5. Update translation files, check new strings are present
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This patch rewrites transfer slip code to make some
strings translatable.
Also simplifies some code and parameters.
To test:
1) Produce a transfer slip, no changes must be noted.
2) Update PO file, new strings
msgid "%s %s%s%sNo hold found%s %s %s "
msgid "%s%s%sNo hold found%s "
msgid "Koha › Circulation › Transfers"
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
The tests for the subroutines : GetMessageTransportType, EnqueueLetter, SendQueuedMessages, GetQueuedMessages, GetLetters, getletter, addalert, getalert, delalert and GetPreparedLetter of the module C4::Letters have been added.
Test plan:
1) Apply the patch
2) Execute the unit tests by launching :
prove t/db_dependent/Letters.t
3) The result has to be a success without error or warning :
t/db_dependent/Letters.t .. ok
All tests successful.
Files=1, Tests=45, 2 wallclock secs ( 0.04 usr 0.01 sys + 1.44 cusr 0.08 csys = 1.57 CPU)
Result: PASS
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
All test pass, no errors.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12151: Remove uses of smartmatch operator from Koha/Solr/QueryBuilder.pm
Just that.
Regards
To+
Sponsored-by: Universidad Nacional de Cordoba Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes QA script and tests.
Could only verify by reading the code.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12151: Remove use of smartmatch operator in tools/batchMod.pl
The '~~' smartmatch operator is used to compare MARC::Field->subfield(code)
(i.e. a string) and the text element of each MARC::Field->subfields() which
is also plain text.
Substituting '~~' for 'eq' should be harmless then.
Regards
To+
Sponsored-by: Universidad Nacional de Cordoba Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes QA script and tests.
Tested batch modification of items, no problems found.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12151: Remove uses of smartmatch operator in report scripts
This patch removes the use of smartmatch operators in report scripts.
Regards
To+
Sponsored-by: Universidad Nacional de Cordoba Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes QA script and tests.
Acquisition and Patron statistics wizard tested, no regressions found.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Bug 12151: Remove uses of smartmatch operator in Search.pm and opac-search.pl
This patch removes the use of smartmatch operators in the search code.
Regards
To+
Edit: this revision uses 'grep' instead of Lists::MoreUtils::any
Sponsored-by: Universidad Nacional de Cordoba Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script.
Tested search, no problems found.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Jonathan Druart [Thu, 12 Jun 2014 09:06:58 +0000 (11:06 +0200)]
Bug 12409: Fix fields order on exporting to bibtex
The C4::Record::marc2bibtex subroutine supposes hashref keys are sorted
which is wrong with perl 5.18
Note that the t/db_dependent/Record.t fails without this patch.
Test plan (for perl >= 5.18 only):
1/ prove t/db_dependent/Record.t should return green
2/ Try to export a record to bibtex and verify the order is correct
(should be author, title, year, published, etc.).
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Wrong Bug number on heading.
Work as described, test pass, no koha-qa errors.
The problem is to think that a hash returns
keys in a particular order, that's not true
and no matter which perl version.
Code as was left is... misleading.
Comments talks about a hash, which is no more.
On array asignment "a => b" is equivalent to "a, b",
but the former is usually used on hashes, so a
replacement of '=>' by ',' could clarify what are we storing.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Fixing the comments in a follow-up patch.
Tests pass now without problems and records export ok.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This patch extracts variables with HTML from addbiblio.pl
and an instance of CGI::scrolling_list
As it changes how MARC editor show input fields, I prefer
not add patches for other cases mentioned on Comment #1
To test:
1. Verify there are no regressions on MARC editor
Add/Edit records, modify values
2. Update translation file for a language,
check new string 'Tag editor'
About the error message on error when deleting biblio,
it must be localized but the script is not trying to
use a template file, only prints a basic html and aborts.
Perhaps a way of handling errors more gracefully is needed,
but again it need to be solved on it's own bug.
Updated test plan
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Yohann Dufour [Thu, 26 Jun 2014 12:28:58 +0000 (14:28 +0200)]
Bug 12482: removing the use of the module C4::SQLHelper.pm, it is replaced by DBIx::Class
This patch includes:
- removing the use of subroutines InsertInTable, UpdateInTable, SearchInTable replaced by subroutines of DBIx::Class in the subroutines AddBudget, ModBudget, GetBudgets, AddBudgetPeriods, ModBudgetPeriod and GetBudgetPeriods and admin/aqbudgetperiods.pl
- removing old database fields in OrderFromSubscription.t, Bookseller.t, Budgets.t, Serials.t, Serials_2.t
- improvement of unit tests in t/db_dependent/Budgets.t
- adaptation of calls to the subroutines AddBudget, ModBudget, GetBudgets, AddBudgetPeriods, ModBudgetPeriod and GetBudgetPeriods in order to match with the use of DBIx::Class
Test plan:
1) Execute the UT of all of files wich uses AddBudget, ModBudget, GetBudgets, AddBudgetPeriods, ModBudgetPeriod or GetBudgetPeriods by launching the command :
prove t/Budgets/ t/Budgets.t t/db_dependent/Budgets.t t/db_dependent/Acquisition.t t/db_dependent/Acquisition/ t/db_dependent/Bookseller.t t/db_dependent/Serials.t t/db_dependent/Serials_2.t
2) The result has to be a success :
t/Budgets/CanUserModifyBudget.t ........................... ok
t/Budgets/CanUserUseBudget.t .............................. ok
t/Budgets.t ............................................... ok
t/db_dependent/Budgets.t .................................. ok
t/db_dependent/Acquisition.t .............................. ok
t/db_dependent/Acquisition/GetBasketsInfosByBookseller.t .. ok
t/db_dependent/Acquisition/GetOrdersByBiblionumber.t ...... ok
t/db_dependent/Acquisition/Invoices.t ..................... ok
t/db_dependent/Acquisition/OrderFromSubscription.t ........ ok
t/db_dependent/Acquisition/TransferOrder.t ................ 1/11 # Transfering order to basket2
t/db_dependent/Acquisition/TransferOrder.t ................ ok
t/db_dependent/Acquisition/close_reopen_basket.t .......... ok
t/db_dependent/Bookseller.t ............................... 16/72 WARNING: GetBooksellerWithLateOrders is called with a negative value at /home/yohann/koha/C4/Bookseller.pm line 135.
t/db_dependent/Bookseller.t ............................... ok
t/db_dependent/Serials.t .................................. ok
t/db_dependent/Serials_2.t ................................ ok
All tests successful.
Files=14, Tests=571, 22 wallclock secs ( 0.17 usr 0.03 sys + 20.26 cusr 1.10 csys = 21.56 CPU)
Result: PASS
3) Go on the page admin/aqbudgetperiods.pl : Koha Administration > Budgets
4) Click on the button "New Budget" and record a new budget with a "nonzero amount" and "make budget active"
5) Click on the button "New Budget" and record another budget without "make budget active"
6) Verify there is the firt budget displayed in "Active budgets" and the second budget in "Inactive budgets"
7) Edit a budget and verify the new values are updated
8) Click on the budget active name in order to go on the page admin/aqbudgets.pl
9) Click on the button "New fund for ..." and record a new fund
10) Click on the button "Edit" then "Duplicate budget ..." in order to duplicate the budget
11) Verify there are two budgets in "Active Budgets" and one in "Inactive Budgets"
12) Click on "Funds" in the menu and verify there are two identical funds and each is associated to a different budget.
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Kyle M Hall [Mon, 14 Apr 2014 17:45:22 +0000 (13:45 -0400)]
Bug 11703 [QA Followup]
* Bold record title, fix table width
* Change output_pref_due to output_pref
* Retain functionality of IssuesDefaultSortOrder system preferences
* Use datatables.inc in circulation.tt
* Fix up holds table details
* Add plugin to about
* fix relatives' checkouts
* add too_many string
* remove dead syspref from db
* Sort relatives' checkouts and holds tables client side
* Provide context for translation of strings
* Fix unterminated string literal, add missing paren
* Add replacement of _AUTHOR_ with title's author for holds
* Format prices correctly
* Format checkout dates correctly
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Christopher Brannon <cbrannon@cdalibrary.org>
Kyle M Hall [Tue, 4 Feb 2014 17:42:55 +0000 (12:42 -0500)]
Bug 11703 - Convert checkouts table to ajax datatable
When a patron has many checked out items, circulation.pl can take a very
long time to load ( on the order of minutes in some cases ). This is
primarily due to the processing of the previous checkouts list. If we
convert to this table to a datatable that fetches its data via ajax, we
can make circulation.pl far more responsive. The same should be done
with relative's checkouts as well.
Test Plan:
1) Apply this patch
2) Observe that the checkouts and relatives' checkouts tables
are now loaded asynchronously
3) Observe and verify the renew and return actions are now
ajax based and function in a manner equivilent to how they
used to.
This bug had quite a few followups, so I squashed all of them into one
change so that code is easier to follow. Original commit messages are below:
Bug 11703 - Use the ajax datatables on patron details page
Bug 11703 - Convert holds tables to ajax datatables
Bug 11703 [QA Followup 1] - Center bProcessing message over table
Bug 11703 [QA Followup 2] - Remove icons from checkout and clear buttons
Bug 11703 [QA Followup 3] - Remove references to UseTablesortForCirc
Bug 11703 [QA Followup 4] - Add back in Today's checkouts/Previous checkouts rows
Bug 11703 [QA Followup 5]
Bug 11703 [QA Followup 6] - Move strings to an include file for translation purposes
Signed-off-by: Dobrica Pavlinusic <dpavlin@rot13.org> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script.
Test plan on bug report:
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11703#c98
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Christopher Brannon <cbrannon@cdalibrary.org>
Fridolin Somers [Thu, 19 Jun 2014 08:17:53 +0000 (10:17 +0200)]
Bug 12451 - circulation rule cant be edited if itemtype contains a space character
When an itemtype description contains a space character like " Book"
(often used to set this itemtype as first in sorted lists), the edition
of an existing circulation rule does not work, it selects the default
itemtype. Same for patron category.
It's because the JavaScript code performs a trim on value existing in
table itm = itm.replace(/^\s*|\s*$/g,''); This patch adds trim on select
options in editing line.
Test plan :
- Create an itemtype with a leading or trailling space in description :
ie " Book"
- Go to cgi-bin/koha/admin/smart-rules.pl
- Create a rule with this itemtype, Unit=hours and Hard due date=Exactly
on 31/12/2015 (any date)
- Click on Edit on this rule line
=> Without this patch, the default itemtype is selected in edition
line
=> With this patch, the correct itemtype is selected in edition line
Check others selects are ok :
- Create a rule with Unit=hours and Hard due date=Exactly on
31/12/2015 (any date)
- Click on Edit on this rule line
=> The correct options are selected
Same tests with a patron category containing a leading or trailling space in description
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Reed Wade [Thu, 26 Jun 2014 20:38:58 +0000 (16:38 -0400)]
Bug 8567: Set output directory for fines.pl in cron config created by the packages
Modified debian/koha-common.cron.daily adding instance output dir option to
the fines.pl entry as described in the ticket.
Requires patch from Bug 8566 which provides the __instancename__ feature for
koha-foreach.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Robin Sheat <robin@catalyst.net.nz> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Owen Leonard [Wed, 25 Jun 2014 17:07:52 +0000 (13:07 -0400)]
Bug 12220 - bootstrap not responsive on all devices
The bootstrap theme includes a meta tag attribute which disables zooming
on some devices. This was unintentional and not desirable. This patch
removes the problematic attribute.
Julian Maurice [Tue, 13 May 2014 08:21:43 +0000 (10:21 +0200)]
Bug 12237: Remove the "horrible hack" in C4::Templates
Use C4::Languages::getlanguage() instead of
C4::Templates::_current_language()
Test plan:
1/ Set one of the 4 XSLT sysprefs to 'default'
2/ Go to the corresponding page
3/ Switch language and check that the right XSLT is used
4/ Set the same syspref to something with '{langcode}' in it. For
example:
"../koha-tmpl/opac-tmpl/bootstrap/{langcode}/xslt/UNIMARCslim2OPACDetail.xsl"
5/ Go back to the corresponding page
6/ Switch language and check that the right XSLT is used
7/ Change a compact.xsl for a language (for example
koha-tmpl/intranet-tmpl/prog/fr-FR/xslt/compact.xsl) to be able to see
differences
8/ Go to a biblio detail page in staff interface and click on "MARC
Preview: Show"
9/ Close the popup, switch language and click again on the same link
10/ Check that the correct XSLT is used.
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Works as described following test plan.
No koha-qa errors
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
No problems found, passes tests and QA script.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
David Cook [Mon, 29 Jul 2013 03:02:26 +0000 (13:02 +1000)]
Bug 10652 - Ajaxfileupload.js failing in IE9 for local image upload
This patch adds a try/catch to the Javascript for adding the iframe
element. The try will work for IE8 and older versions, while newer
versions and other browsers will be covered by the check.
Test Plan:
1) Try uploading a local cover image in IE9
2) Notice that your page is reloaded with no result (except the
pop-up of a Javascript error, if you have error reporting on in
your browser).
3) Apply the patch
4) Trying uploading a local cover image again
5) Notice that it uploads correctly
6) Repeat steps 4 and 5 for IE8, IE7, and/or other modern browsers.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Tested in IE10 in IE10 "browser mode" and IE9 mode as well as in
Firefox. Uploads work correctly with book cover images and in MARC
uploads.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Also verified as working in Chrome.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Doesn't break functionality and fixes a known problem. I'll push this for
stable branches to use it, but will fill a new bug for updating AjaxFileUpload.js
from upstream.
Juhani Seppälä [Thu, 26 Jun 2014 08:28:19 +0000 (11:28 +0300)]
Bug 12481: Staff client detail-view "next" link is greyed out when the last search result of any results page is clicked or navigated into
When doing a staff client catalog search with more than 1 page of results
and clicking the last result on any search result page, the top-left navigation
button for "next" is greyed out.
Tested on newest Firefox & Chromium. Attempts to restore originally planned checks for navigation
with the exception of not using results.length due to buggy behaviour where the results get concatenated
upon page reload & "return to results" navigation - a separate issue?
To test:
1) Do an intranet catalog search that has more than 1 page of results.
2) Click on the last result on a page that is not the last one & confirm that the navigation button "next" is greyed out.
4) Apply patch.
5) Do an intranet search with more than 1 but less results than fit on a single page.
6) Click on the last result on the page and confirm that the "Next" navigation button is greyed out.
6) Do an intranet search with more than 1 page of results.
7) Click on the last result of a page that's not the final page of the results & confirm that "Next" is not grey out.
8) Navigate to the last page of the results and click on the final result & confirm that "Next" is greyd out.
This patch prevents the "Next" button on detail view to be grayed out at the end of e result page. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Owen Leonard [Thu, 26 Jun 2014 19:03:37 +0000 (15:03 -0400)]
Bug 12485 - Show OPAC search history when opacuserlogin is OFF
In the boostrap OPAC the link to search history is missing if
opacuserlogin is turned off. OPAC search history should be available
whether or not users can log in. This patch removes this dependency.
To test, apply the patch and test with various combinations of
opacuserlogin and EnableOpacSearchHistory:
- opacuserlogin and EnableOpacSearchHistory both enabled
- opacuserlogin enabled and EnableOpacSearchHistory disabled
- opacuserlogin disabled and EnableOpacSearchHistory enabled
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>
Works as described, no problems found.
Passes QA script and tests.
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Owen Leonard [Thu, 26 Jun 2014 19:33:07 +0000 (15:33 -0400)]
Bug 12463 - Capitalization: Calendar tool, headings for different types of holidays
There are several instances of incorrect capitalization in the Calendar
tool. This patch corrects them.
To test, apply the patch and go to Tools -> Calendar. Headings and
labels on the page should have correct capitalization.
Signed-off-by: Juhani Seppälä <jseppal@student.uef.fi> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
String changes in the template, no problems found.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Owen Leonard [Mon, 30 Jun 2014 18:05:21 +0000 (14:05 -0400)]
Bug 12386 - 'Days in advance' pull down in bootstrap OPAC is huge
The "days in advance" form field on the "Your messaging settings" page
in the OPAC has a Bootstrap-default width which is too wide. This patch
adds a class to give it a more reasonable size.
To test you must have the EnhancedMessagingPreferences preference set to
"Allow." Log in to the OPAC and view the messaging settings page. The
dropdown menu of numbers should look correct.
Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Reed Wade [Thu, 26 Jun 2014 06:24:07 +0000 (02:24 -0400)]
Bug 8566: [SIGNED-OFF] Enable koha-foreach to insert the instancename into commands
koha-foreach has been modified to replace __instancename__ with $name
on each iteration using sed.
The docbook file for koha-foreach has also been updated to reflect the
new functionality.
To test:
koha-foreach ls -ld /etc/koha/sites/__instancename__
should list directories instead of giving an error message.
Signed-off-by: Magnus Enger <digitalutvikling@gmail.com>
The suggested example with ls works as expected, as does my
more complex example with fines.pl:
Fridolin Somers [Thu, 5 Jun 2014 15:21:28 +0000 (17:21 +0200)]
ug 11857 - Number of patrons on a patron list not accurate
When creating a patron list with only 1 patron, the patron
lists page says that the list contains 3 patrons.
When creating a patron list with only 1 patron, it works fine.
This is caused by the fact that access on "patron_list_patrons"
Koha::Schema::Result::PatronList object returns an hash if one
result and an array if more results.
See similar problem at
http://permalink.gmane.org/gmane.comp.lang.perl.modules.template-toolkit/7250
This patch replaces by the call on resultset and then the use of
"count" method.
Test plan :
- Go to patron lists : /cgi-bin/koha/patron_lists/lists.pl
- Create a new patron list LIO
- Add one patron
- Create a new patron list LIM
- Add 2 patrons
- Go to patron lists : /cgi-bin/koha/patron_lists/lists.pl
=> Without this patch you see :
Name Patrons in list
LIO 3
LIM 2
=> With this patch you see :
Name Patrons in list
LIO 1
LIM 2
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Work as described, no koha-qa errors.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script. Confirmed the problem and that
the patch fixes it.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Martin Renvoize [Wed, 21 May 2014 14:18:14 +0000 (14:18 +0000)]
BUG 12304: LDAP auto-provisioning set default messaging preferences
LDAP auto-provisioning should set default messaging preferences upon
creation of a user.
Signed-off-by: Ulrich Kleiber <ulrich.kleiber@bsz-bw.de>
Manually applied to 3.12.9 and it works beautifully in test and production.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Jonathan Druart [Wed, 11 Jun 2014 13:20:37 +0000 (15:20 +0200)]
Bug 9811: Fix wording branch vs library
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script.
1) Top search
- OK no regressions found
2) New filters
- OK Terminology
- OK Search fields, search types, category, library
- OK Clear button
3) Result list
- OK Cardnumber
- OK Name, address and email
- OK Fines, checkouts and overdues
- OK Adding patrons to patron lists
- OK Select all/unselect all
- OK Sorting on the various columns
- OK Paging
- OK PatronsPerPage system preference
4) Performance
Tested with a database containing 40.000 patrons.
Search results were displayed with a little delay,
overall performance seemed pretty good.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Jonathan Druart [Mon, 9 Jun 2014 15:35:43 +0000 (17:35 +0200)]
Bug 9811: Various fixes
This patch fixes the issues raised in bug 9811 comment 105, 106 and 107:
1/ Add missing space between category and type.
2/ Fix error on searching an empty string (caused by a previous rebase).
3/ Remove sort option on checkbox/borrowernumber column.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Jonathan Druart [Fri, 14 Mar 2014 10:03:34 +0000 (11:03 +0100)]
Bug 9811: FIX encoding issue on patron categories
The patron categories should use the html_entity filter (on the current
master).
Signed-off-by: Olli-Antti Kivilahti <olli-antti.kivilahti@jns.fi>
This fix solves the issue of double encoding some utf8-characters by html_encoding the
patron categories, which are not marked as utf8.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Issue:
When a patron has backslashes in his circulation notes, the JSON transportation
layer cannot send the message because it will fail JSON validation when trying to
validate backslashed non-literal characters (\s \d ...).
This causes the whole search to fail when even one Borrower has a non-literal
backslashed character in his notes.
Solution:
The Borrowers' circulation notes are filtered through a regexp which doubles all
backslashes to prepare them for the JSON validation routine.
Result:
Backslashes pass through unchanged.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Jonathan Druart [Tue, 19 Mar 2013 10:12:26 +0000 (11:12 +0100)]
Bug 9811: Patron search improvement
This patch add DataTables using server-side processing for the patrons
search.
It adds:
- 1 module C4/Utils/DataTables/Members.pm
- 2 services svc/members/search and svc/members/add_to_list
- 1 template members/tables/members_results.tt
- 1 new practice which is to add template for DataTables in a
subdirectory named 'tables'.
Impacted scripts: members/members-home.pl and members/members.pl
To go further: We can imagine that all patrons searches use the same
service with no big changes: 1 little template creates a JSON file and
to implement DataTables on the template page, that's all.
Amended patch: Since bug 10565 has been pushed, these patches don't
apply cleanly. I had to rewrite a part of the patron list feature.
I removed the choice to add all resultant patrons from a search. I think
this choice is useless with this patch: we are able to display the
number of patrons we want and to select all of them.
Test plan:
- Check that there is no regression on searching patrons.
- Try filters on the left of the screen.
- Try to sort each column.
- Try the "Browse by last name" links.
- Check that the "Clear" button clears yours filters.
- Try with IndependantBranches ON and OFF.
- Verify this feature does not break the patron list feature (cf bug
10565).
Signed-off-by: Cedric Vita <cedric.vita@dracenie.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script, couldn't find any regressions
or problems. Some notes left on the bug.
Bug 9811: Add unit tests for C4::Utils::DT::Members
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Bug 9811: QA followup
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Thx for fixing these!
Bug 9811 - multilines notes brakes JSON
In new patron search feature, the search results are fetched using Ajax and returned in JSON format.
The JSON is created by TT using koha-tmpl/intranet-tmpl/prog/en/modules/members/tables/members_results.tt.
One of the fields is the borrower notes. When this notes contains several lines, the JSON is broken.
This patch uses TT fileters to consert in notes linefeeds into HTML line break (html_line_break) and then remove linefeeds (collapse).
Test plan :
- perform a member search that does not return a borrower with a circ note
- edit one of the borrowers returned by this search
- enter serveral lines of text in "Circulation note" and save
- reperform the member search
=> circ note is well displayed on several lines
Bug 9811: use count(primary_key) instead of count(*)
Bug 9811: A limit clause should be always added.
By default, we want to retrieve 20 first results.
Bug 9811: Load the page without any data.
Displaying the first 20 patrons is not useful. With this patch, the
table is hidden and no record is retrieved by default.
On the same way, the existing side effect on redirect disappears.
Signed-off-by: Olli-Antti Kivilahti <olli-antti.kivilahti@jns.fi>
-------------
-TEST REPORT-
-------------
For the filter: Tested all the search fields, branches, search type.
Found a bug with "date of birth", followup provided.
Tested display limits and verified that AJAX-queries are
efficient (using LIMIT clause) to not stress DB needlessly.
Tested adding Patrons to a list.
A good feature, which seems to work quite well.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Adding my test plan to the last patch of this bug.
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Kyle M Hall [Fri, 30 May 2014 11:17:25 +0000 (07:17 -0400)]
Bug 12337 - Multi-clicking the renewal buttons on circulation.pl can trigger "renewal failed" message.
Each time the "renew all" or "renew or return" buttons are click, the
renewal process is triggered. If the patron only has one renewal left,
and the button is multi-clicked, the librarian may receive a
"renewal failed" message even though the renewal did occur. In
addition, this can just unwanted multiple consecutive renewals
as well.
Test Plan:
1) Check out an item to a patron that can have 1 renewal
2) Click the "renew all" button multiple times, fast and furiously
3) Note the "renewal failed" messaged
4) Apply this patch
5) Repeat steps 1 and 2
6) Note the item is now renewed without the failure message
Signed-off-by: Nick Clemens <nick@quecheelibrary.org> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Fridolin Somers [Thu, 19 Jun 2014 12:47:15 +0000 (14:47 +0200)]
Bug 11357 - biblioitems.size value not correctly displayed in list emails sent from OPAC and intranet
The size column in biblioitems is a bit problematic when used in TT, because instead of the size value from the biblio column it will give you the size of the variable.
It's currently used in the templates for sending shelves from OPAC and intranet and maybe also in other places:
[% END %]
[% IF BIBLIO_RESULT.size %]
, [% BIBLIO_RESULT.size %]
[% END %]
This patch corrects by using item() TT method.
See http://stackoverflow.com/questions/2311303/how-can-i-handle-hash-keys-containing-illegal-identifier-characters-in-template.
Test plan :
In each display :
=> Without this patch you see biblioitems.pages and then a number
=> With this patch you only see biblioitems.pages
- Create a record with biblioitems.pages defined (like "12p") but without biblioitems.size defined
Same for OPAC and intranet :
- Add it to the cart
- Open the cart
- Check the "Title" column
- Click on "More Details"
- Check the "Details" row
- Send the basket via email and check the result
- Add to a list
- Send the list via email and check the result
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Works well!!
Tested on staff & opac, cart & list.
No koha-qa errors
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes QA script and tests.
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>