Galen Charlton [Mon, 20 May 2013 15:38:46 +0000 (08:38 -0700)]
Bug 10170: expose more managed staged MARC strings to translation
This commit makes it possible to translated the 'staged'
and 'error' record statuses as well as the 'auto_match'
overlay status.
Also takes out a bit of HTML cruft in one string that is
not needed for translation.
Signed-off-by: Galen Charlton <gmc@esilibrary.com> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
All tests pass. New strings are parsed into the po files:
"%s Always add items %s Add items only if matching bib was found %s Add items only if no matching bib was found %s Ignore items %s %s %s %s "
"%s No match %s Match applied %s Match found %s %s %s " Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Adrien Saurat [Thu, 2 May 2013 14:56:54 +0000 (16:56 +0200)]
Bug 10170: strings in MARC import made translatable
Following bug 9215: non translatable strings are now
present in the template and translatable
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Not only does this make the strings translatable it makes the template
a lot easier to read Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
All tests pass. Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Jonathan Druart [Fri, 17 May 2013 13:27:45 +0000 (15:27 +0200)]
Bug 10275: UT: OrderFromSubscription.t needs to create its own data
Try before the patch:
prove t/db_dependent/Acquisition/OrderFromSubscription.t
And after, it should produce:
t/db_dependent/Acquisition/OrderFromSubscription.t .. ok
All tests successful.
Files=1, Tests=12, 2 wallclock secs ( 0.02 usr 0.00 sys + 0.46 cusr
0.02 csys = 0.50 CPU)
Result: PASS
And some warnings...
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes tests.
Assumes Dateformat is set to US dates as in the sample data. Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 10575 : GetOrdersByBiblionumber.t needs a database transaction
Before this patch, the queries in GetOrdersByBiblionumber.t were commited in the database and have to be removed at the end.
This patch wraps tests in a database transaction.
Test Plan :
prove t/db_dependent/Acquisition/GetOrdersByBiblionumber.t
t/db_dependent/Acquisition/GetOrdersByBiblionumber.t .. ok
All tests successful.
Files=1, Tests=3, 0 wallclock secs ( 0.02 usr 0.01 sys + 0.37 cusr 0.05 csys = 0.45 CPU)
Result: PASS
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Tests pass. Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Mathieu Saby [Fri, 3 May 2013 21:07:37 +0000 (23:07 +0200)]
Bug 10189: Translate values in UNIMARC 128b/c cataloguing plugins to English
Cataloguing plugins for UNIMARC 128b and 128c fields are only in Ffrench.
This patch translates them.
Source : http://blue.lins.fju.edu.tw/mao/marc/unicon.htm
Note : 128b and 128c are deprecated in last version of UNIMARC Manual (field 145 used instread).
But they are still used in French Sudoc network.
To test : in a UNIMARC english Koha, edit a record and use 128b and 128c
cataloguing plugins. Check everything is in english.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Thx for translating those!
Verified new strings get parsed into the po files.
Templates still contain lots of tabs, those can be fixed separately.
Galen Charlton [Mon, 17 Jun 2013 01:05:31 +0000 (18:05 -0700)]
Bug 10258: offer to create basket group only when staff user has correct permission
If the staff user does not have the group_manage acquisition permission,
do not offer to create a new basket group when closing an order basket.
This avoids a situation where if a staff member without that permission tries
to close a basket and chose the option to create a bakset group, they would
be redirected to the login page.
To test:
[1] Log in as a staff user that does not have
the acquisition/group_manage permission.
[2] Create a new order basket, attach at least one
order line to it, then close it.
[3] Verify that the confirmation page does not
offer to create a basket group with the
same name as the order basket.
[4] Log in as a staff user that has the
acquisition/group_manage permission.
[5] Create and close an order basket.
[6] Verify that this time, the confirmation page
*does* offer to create a basket group.
Galen Charlton [Thu, 13 Jun 2013 15:53:49 +0000 (08:53 -0700)]
Bug 10258: fix permissions check for setting basket group for order basket
Improve the code that displays and allows staff to
set the basket group from the basket details page
for a closed basket.
Prior to this patch, a staff member who did not
have the group_manage acquisition permission would
still see a control to change the group that the
basket belongs to; attempting to change the group
would present with with a login page.
This patch also does some tidying of how basket group
details are passed to the template.
To test:
[1] Create an order basket and close it. Do
not assign it to a basket group.
[2] View the basket details while logged in as
a staff user who has the order_manage acquisitions
permission but not the group_manage. The
displayed basket group should be "No group".
[3] Switch to a staff user who also has the
group_manage permission, then view the basket
details again. The basket group field should
now be a select input that allows you to change
the basket group.
[4] Change the basket group. Verify that the basket group
you selected is now displayed as the current group
for that order basket. The basket group delivery and
billing place fields should also now be displayed.
[5] Close the basket group set in the previous step, then
view the basket details again. This time, the basket
group name should be displayed with a suffix of " (closed)",
and no input to change the group should be displayed.
[6] Swith to a staff user who does not have the group_manage
permission, view the basket details, and verify that
the basket name is displayed with a suffix of " (closed)".
Jason Etheridge [Fri, 8 Mar 2013 15:41:06 +0000 (10:41 -0500)]
Bug 9770: fix sorting of Dewey call numbers that contain prefixes
C4::ClassSortRoutine::Dewey can pad the wrong part of a call number internally.
The subroutine get_class_sort_key tokenizes a call number string (splitting on
periods and whitespace) and counts the number of tokens that solely contain
digits. If there is only one such digit group, a comment in the code states
that it will pad said digit group. However, the bug is that the code assumes
said digit group is the first token, when this may not be the case.
In practice, this can cause poor sorting when used a call number is in the form
of PREFIX _space_ 3DIGITS.
To test:
[1] Create two item records whose class scheme is set to
'ddc' (Dewey) and whose call numbers contain prefixes, e.g.,
J DVD 700.1 ABC and J DVD 850 DEF.
[2] Use the inventory tool to produce a list of item items that include
the two created in step 1. Obsere that that items are sorted
in the incorrect order, with "J DVD 850 DEF" coming before
"J DVD 700.1 ABC". Alternatively, run the following SQL
to see the incorrect sort order:
SELECT cn_sort, itemcallnumber
FROM items
WHERE itemcallnumber LIKE 'J DVD%'
ORDER BY cn_sort;
[4] Apply this patch.
[5] Run misc/maintenance/touch_all_items.pl to force cn_sort to be
recalculated.
[6] Repeat step 2 and verify that the call numbers are now sorted
corrected.
Signed-off-by: Jason Etheridge <jason@esilibrary.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com> Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Jason Etheridge [Fri, 21 Jun 2013 19:31:32 +0000 (15:31 -0400)]
Bug 9770: test case for sorting of Dewey call numbers that contain prefixes
This adds a test for C4::ClassSortRoutine::Dewey to check that the
call number "JR DVD 800.1" sorts before "JR DVD 900"
To test:
[1] Apply just this patch.
[1] Run prove -v t/ClassSortRoutine_Dewey.t
[2] Test #7 should fail.
Signed-off-by: Jason Etheridge <jason@esilibrary.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com> Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes test plan and QA script. Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 10447: add 'ru' and 'uk' to Zebra indexing language list
This patch add the option to choose 'ru' and 'uk' during install for Zebra.
Should work for a tarball install, and make 'ru' and 'uk' available for using
with koha-create too.
Sponsored-by: Universidad Nacional de Córdoba Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Reran Makefile.pl and made sure the language options show up now.
Patch extends existing language code lists addings nb, ru and uk
where missing.
Robin Sheat [Mon, 15 Jul 2013 14:06:40 +0000 (02:06 +1200)]
Bug 10590 - parameterise the limit option
The limit option was previously substituted directly into the query. The
previous patch on bug 10590 filters it on input, but there's no reason
not to have it made to work properly in the query for added safety.
To test:
[1] Go to the top checkouts report (http://OPAC/cgi-bin/koha/opac-topissues.pl)
[2] Run the report several times, varying the filters on
number of results and item type.
[3] Verify the the list of top checkouts appears to be correct.
Signed-off-by: Galen Charlton <gmc@esilibrary.com> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 10590 - in opac-topissues limit param is not protected
In opac-topissues page, the limit URL argument is directly added to SQL query.
This patch adds protections : limit must only contain digits and must be lower than 100.
Test plan :
- Edit URL to : /cgi-bin/koha/opac-topissues.pl?limit=10&branch=&itemtype=&timeLimit=999&do_it=1
=> You get the results of 10 most cheched-out of all time
- Edit URL to : /cgi-bin/koha/opac-topissues.pl?limit=&branch=&itemtype=&timeLimit=999&do_it=1
=> You get the results of 10 most cheched-out of all time
- Edit URL to : /cgi-bin/koha/opac-topissues.pl?limit=9999&branch=&itemtype=&timeLimit=999&do_it=1
=> You get the results of 100 most cheched-out of all time
- Edit URL to : /cgi-bin/koha/opac-topissues.pl?limit=WHERE&branch=&itemtype=&timeLimit=999&do_it=1
=> You get the results of 10 most cheched-out of all time
Signed-off-by: Robin Sheat <robin@catalyst.net.nz> Signed-off-by: Galen Charlton <gmc@esilibrary.com> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Owen Leonard [Thu, 11 Jul 2013 14:28:55 +0000 (10:28 -0400)]
Bug 10514: improve visibility of Add item link on new order form
This patch converts the "Add" and "Clear" links
to the standard "submit/cancel" format inside a fieldset. This gives
them a little more visual weight.
Based on the changes made by Liz Rea and Jonathan Druart.
To test:
- create a basket
- add a record to it
- scroll down - the link to add item and cancel should both be more
prominent now.
- Click "Add item" - it should add an item.
Signed-off-by: Liz Rea <liz@catalyst.net.nz>
I still feel weird about the button, but as two people have said they'd rather have the button, I'm alright with it I guess.
Really what I want is people to notice it's there and click it at the appropriate time. I hope this will help that issue.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script.
Leaves the translation problems, but that needs more work and is
out of the scope of this bug.
Tested Add and Update functionality works correctly.
Colin Campbell [Tue, 9 Jul 2013 10:18:49 +0000 (11:18 +0100)]
Bug 10507: improve warning about duplicate patron attribute value
If a warning about a duplicated patron attribute is returned,
the value was being passed back for display in the warning
message with the same name as the variable in errors
As the message is displayed in the context of errors
the error value 1 was being displayed not the value
duplicated as intended.
Pass the value to the template with a unique name.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
I fixed another tiny typo while signing off: "is already in use" instead
of "is already is use."
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Passes koha-qa.pl, works as advertised.
Owen Leonard [Tue, 25 Jun 2013 16:46:04 +0000 (12:46 -0400)]
Bug 10475 - Item form in acquisition not hiding subfields properly
Subfields hidden in your ACQ framework leave a gap where they used to
be in the item entry form when adding an item to an order. This patch
makes the same change made by 7116 to services/itemrecorddisplay.tt to
correct the problem.
To test:
- Edit your ACQ framework and set some item subfields to hidden in the
editor.
- Set your AcqCreateItem system preference to "when placing an order."
- Add a title to an existing basket from an existing record.
The item entry form should display correctly with your hidden subfields
hidden. No whitespace should be left behind where the subfields were
hidden.
Also changed: Invalid "size" attributes on hidden form fields in
neworderempty.tt, stray </li>.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Works nicely, passes all tests and QA script.
Thx Owen!
Colin Campbell [Thu, 4 Jul 2013 11:21:45 +0000 (12:21 +0100)]
Bug 10529: Remove hardcoded dollar from patron message
The message fields which are returned in the SIP
Screen message field in a Patron Information response
had the dollar symbol hardcoded.
It would be possible to get the symbol from currency
but omitting any symbol would be consistent with the UI
and avoid problems with devices using weird encodings
for local currency symbols (e.g. the many variations
of UK Pound sign)
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This routine is not in used and does not make sense. It should not be
used later.
Signed-off-by: Srdjan <srdjan@catalyst.net.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Passes koha-qa.pl, not references to get_branch_code_from_name found.
Katrin Fischer [Mon, 1 Jul 2013 19:58:57 +0000 (21:58 +0200)]
Bug 10490: Overdue fines cap can't store decimal values
When overduefinescap was added to the issuingrules the datatype
given was decimal. This translates in MySQL to decimal(10,0).
This doesn't allow you to store decimal values and therefore
values like 4.5 are saved as 5 in the database.
To test:
On a current installation:
1) Try to enter 4.5 as Overdue fines cap. Verify that the value
is not correctly saved.
2) Apply patch and run database update.
3) Try adding/changing an issuing rule setting Overdue fines cap
to 4.5 again.
4) Verify the value is saved correctly.
Create a new Koha installation from scratch:
1) Verify that the issuingrules table has been created correctly
and that you can add/mofidy issuingrules correctly.
Because this bug can create data loss, the old database update
has also been changed to avoid this problem for people updating
at a later point in time. Checkout an older version of Koha
pre 3.09.00.027.
1) Run the database updates.
2) Verify again, that adding/modifying issuingrules works correctly.
Signed-off-by: Srdjan <srdjan@catalyst.net.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Owen Leonard [Tue, 2 Jul 2013 13:59:21 +0000 (09:59 -0400)]
Bug 10422 - Remove references to unused and non-existent wizard.css
doc-head-close.inc contains a reference to "wizard.css" which doesn't
exist. The option to include it never evaluates as true, and that
section can be removed from the template.
To test, apply the patch and view any page in the staff client.
Everything should be styled as before. A search of the Koha source
should return no references to "wizard.css" or a "wizard" variable.
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
No occurrence of "wizard" in pl/pm files.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Passes koha-qa.pl
Robin Sheat [Fri, 30 Nov 2012 02:48:50 +0000 (15:48 +1300)]
Bug 10560: make it possible for default interface language to not be English
If you enable another translation, and disable English, then if you dont
have a cookie set, or your browser is not set to that language, you will
get English. So you can not disable English in either the staff client
or the OPAC.
This patch fixes the language selection to do the right thing.
To test you must have at least one other language installed besides
English. Apply the patch and disable the en translation. Koha should
fall back to one of the enabled translations.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
I added a patch description and test plan, missing from the
original patch.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
I have tested with various combinations of activated languages
and have found no regression. If the cookie is set, the right
language is shown accordingly. Else the first language in the
list seems to be picked. It did never fall back to English
in my tests, when English was explicitly deactivated.
In parcels.pl, and other acquisition pages, the funds are not sorted
by name in combo-box. With a great number of funds, it is difficult
to find one.
This patch adds a default value to $orderby arg of C4::Budgets::GetBudgets.
Test plan :
- Create a new fund with a name beginning with 'z' and set you as owner.
- Create a new fund with a name beginning with 'a' and set you as owner.
- Go to a vendor and click "Receive shipments"
- Look at fund combobox
=> Funds are sorted by name
Signed-off-by: Silvia Simonetti <s.simonetti@cineca.it> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script.
When testing make sure your funds would sort the other way
around when sorting by code instead of description.
Fridolyn SOMERS [Wed, 5 Jun 2013 12:16:14 +0000 (14:16 +0200)]
Bug 6898: fix DB update that assigns the circulate/overdues_report permission
This patch fixes a bug that prevented the circulate/overdues_report
permission from being assigned to staff users during upgrade. This
patch will not affect databases that are already running 3.12.x
or later.
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
This will only fix the permissions for updates done
after the patch has been applied. But I agree with
Fridolyn, that we can not safely update permissions for
existing installations.
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Chris Hall [Fri, 22 Mar 2013 02:33:50 +0000 (15:33 +1300)]
bug 10356: improve display of serial issue dates in staff bib details page
This patch adds the date published to the subscriptions tab in the staff
interface bib display and renames the former "Date" column to
"Date arrived".
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Owen Leonard [Fri, 28 Jun 2013 18:11:48 +0000 (14:11 -0400)]
Bug 10496 - CCSR theme OPAC tabs to not show correct active state
When jQueryUI was updated in the CCSR theme the corresponding CSS
changes were not copied over at the same time, causing style problems
with jQueryUI widgets. This patch makes the necessary changes.
To test, apply the patch, clear your browser cache, and view any page
which uses jQueryUI tabs (advanced search, bibliographic detail page).
Tabs should look correct and correctly show which tab is active.
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
CSS changes only.
Confirmed problem in CCSR OPAC templates.
Tested advanced search and detail pages in CCSR and prog.
In order to fully test advanced search I added location and
collection to AdvancedSearchTypes.
Also tested the branch tooltip as I spotted some CSS added for that.
Owen Leonard [Fri, 26 Apr 2013 20:18:05 +0000 (16:18 -0400)]
Bug 5766 - Add configuration for excluding articles from DataTables sorting
Client-side table sorting should exclude articles like "a," "an," and
"the" when sorting by title. This patch adds a custom sorting plugin for
use by DataTables and a configuration line to the DataTables string
configuration file which can be translated for any language.
As an example, this patch modifies the patron checkout history template
to use the new sort on the title column.
To test, apply the patch and clear your browser cache to ensure the
revised JavaScript file is loaded. Sort the table by title. Titles
should be sorted regardless of the presences of "a," "an", or "the" at
the beginning of the title.
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and is a good improvement.
I have added German articles to the list for testing purposes
and it worked nicely.
David Cook [Wed, 12 Jun 2013 01:24:09 +0000 (11:24 +1000)]
Bug 10448: can now change framework after duplicating bib record
Changing the framework in the MARC editor immediately after duplicating
a bib record no longer clears the fields.
This patch changes the Changefwk Javascript function so that it passes
the "op" value and the "biblionumberdata" (as the biblionumber) from
addbiblio.pl back to itself, when submitting the form in order to
change the framework.
The reason we need to do this is because the form in addbiblio.tt
is hard-coded to always submit an "op" value of "addbiblio". Currently,
we need to have it hard-coded to "addbiblio", because all the magic
happens in addbiblio.pl when there is an "op" of "addbiblio". If we
always passed the "actual" "op" value, such as "duplicate", nothing
would ever happen when we clicked "save". It seems to me that this
is a flaw in the design of addbiblio.pl.
If we pass the "op" and "biblionumber" when changing frameworks, we're
able to tell addbiblio.pl that we're still wanting to "duplicate" this
"X" biblionumber. However, by having the form still hard-coded to
"addbiblio", when we hit save, the form will do the magic, check if
it's a duplicate, and save the record (or prompt for action if it
is a duplicate).
--
I also noticed that if you make changes to a record, then change
the framework before saving, your changes get cleared (since the
original record from the database is loaded when the page reloads).
It seems to me that this is a bug. Changing the framework should
change the layout while preserving the content. I think most users
would assume that when changing the framework.
This patch also introduces another hidden input into addbiblio.tt and
the Changefwk Javascript called "changed_framework". Basically, if
the Changefwk Javascript is run, it tells addbiblio.pl that the
framework is changed, and it uses the posted data from the form
(which we have been modifying) instead of reloading the record from
the database.
--
Test Plan:
A) Before Applying Patch:
To Show That Changing the Framework Erases All Fields When
Duplicating a Record:
1) Go to any bib record
2) Go to Edit > Edit as new (duplicate). You should see filled
in fields.
3) Change the framework to any other framework than the one
that is currently specified.
4) Note that every single field is now blank
To Show That Changing the Record then Changing the Framework
Ignores Changes, When Editing a Record
5) Go to any bib record
6) Go to Edit.
7) Change the title of the record to "I've changed the title".
8) Change the framework to any other framework than the one that is currently specified.
9) Look at the title. You'll notice it is the original title, and NOT "I've changed the title".
B) Apply the Patch
Also, clear your memcache and shift+refresh your screen. You don't want to use cached templates/javascript.
C) After Applying the Patch
Repeat Steps 1-3 and 5-8.
You should now notice that changing the framework when duplicating the item does not clear all the fields.
You should also notice that any changes you make prior to changing the framework will still exist after changing it.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Katrin Fischer [Mon, 1 Jul 2013 21:44:39 +0000 (23:44 +0200)]
Bug 4907: make 'Organize by' filter in suggestions reflect selected option
When using the 'Organize by' option to change the display of the
suggestions, the option is applied, but the pull down always jumps
back to the first entry 'Status'.
This patch fixes that.
To test:
- Try out all settings and verify that after the page reloads the selected
option is applied to your suggestions and the pull down shows
the option you selected.
Note: Until bug 10519 is properly fixed the tabs will not show
the correct descriptions, but the URL will show you the selected
option as parameter: displayby=acceptedby
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Owen Leonard [Fri, 28 Jun 2013 18:46:44 +0000 (14:46 -0400)]
Bug 10522: fix Javascript error on acquisition pages: YAHOO is not defined
acq.js includes an immediately invoked function expression, which means
that it runs whether or not it is called. Because this function tries to
reference the YAHOO object, it triggers an error on pages which don't
include the main YAHOO assets. Only the basketgroups page uses this
function and YAHOO assets.
It's probably possible to make this a regular function, but I propose
simply wrapping it in a check for the YAHOO object so that it only
executes on pages where YAHOO exists--the basketgroups page.
To test, apply the patch, clear your browser cache, and test on both the
basketgroups page and at least one page which also includes acq.js
(addorderiso2709.pl, neworderempty.pl, aqbudgets.pl, suggestion.pl,
etc.) and confirm that the browser reports no JavaScript errors.
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 5858: Followup for INSERT IGNOREs in marc21_framework_DEFAULT.sql
Changes 8 INSERTs into INSERT IGNOREs.
This allows current installs to benefit easier from the new tags/subfields.
Note that running with --force will not achieve the same! The multi-value
inserts will still be aborted, though execution continues.
Test plan:
Run the file or do a new install.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Ran the file on a current install manually.
Bug 5858: update default MARC21 framework to April 2013 revision
Applies to new installs, although with the follow-up
patch, users can run the installer/data/mysql/en/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql
script through the mysql client to add new tag and
subfield entries.
To test:
1) Delete MARC21 default framework
2) Apply patch
3) Test that new default framework loads without problem
Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Run this file with and without this patch.
This patch adds 24 tags (338 vs 314) and 323 subfields (3951 vs 3628).
Verified that last QA comments were incorporated.
Bug 10289: (follow-up) don't set cardnumber for test patron
Since the patron barcode is nullable, and since the tests using
the test patron don't care what the barcode is, don't set it. This
avoids the tests failing if the test database happens to already
have a patron record with the hard-coded barcode that used
to be supplied.
Jonathan Druart [Mon, 20 May 2013 14:37:10 +0000 (16:37 +0200)]
Bug 10289: UT: Reserves.t needs to create its own data
Try before the patch:
prove t/db_dependent/Reserves.t
And after, it should produce:
t/db_dependent/Reserves.t .. 1/4 #
# Creating biblio instance for testing.
# Creating item instance for testing.
# Deleting item testing instance.
# Deleting biblio testing instance.
# Deleting borrower.
t/db_dependent/Reserves.t .. ok
All tests successful.
Files=1, Tests=4, 1 wallclock secs ( 0.02 usr 0.01 sys + 0.39 cusr 0.02 csys = 0.44 CPU)
Result: PASS
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 9519: fix code for Italian language search limiter
'ind' rather than 'ita' was set as the ISO639-2 language
code for Italian in the fr-FR, it-IT, pl-PL, ru-RU, and uk-UA
installation SQL.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
I checked nb-NO and de-DE - language code there had already
been corrected.
Owen Leonard [Wed, 3 Jul 2013 18:34:31 +0000 (14:34 -0400)]
Bug 10125: Babeltheque star image must use sprite
When I removed images from the OPAC in favor of sprites I didn't take
into account the display of star ratings from Babeltheque. This patch
copies the star ratings display from Koha's own ratings display,
though it is not dependent on JavaScript.
I'm sure testing would be easy for someone with access to the
Babeltheque service, but I do not. I temporarily modified the template
to set some variables for testing purposes:
[% SET SEARCH_RESULT.score_int = 3 %]
[% SET SEARCH_RESULT.score_avg = 3 %
[% SET SEARCH_RESULT.num_scores = 87 %]
This enabled the display of the ratings, allowing me to confirm that
stars display correctly. Ratings should work with and without
OpacStarRatings enabled.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
I also fudged the template to test, so QA would need to be done with
someone with Babeltheque access
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 10366: Alert librarian if an invoice number is duplicated
Some vendors ship materials from the same invoice in multiple packages.
In those cases, it would be good to notify the librarian when they enter
a duplicate invoice number, so that they can continue receiving on the
previously-created invoice, rather than creating an invoice with a
duplicate number.
To test:
1) Apply patch and run database update.
2) Make sure that you have created at least one invoice on
acqui/parcels.pl and take note of the invoice number.
3) Try to create an invoice with the same invoice number.
4) Note that without changing your configuration this works exactly
the same as before.
5) Turn on the AcqWarnOnDuplicateInvoice system preference.
6) Try to create a new invoice with the same number as the one you
noted earlier.
7) Make sure you get a warning about a duplicate invoice.
8) Choose to receive on the existing invoice.
9) Confirm that you are receiving on said existing invoice.
10) Start the receiving process over, and this time choose "Create new
invoice anyway."
11) Confirm that you are now receiving on a new invoice.
Signed-off-by: Srdjan <srdjan@catalyst.net.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script.
I have followed the test plan, but also checked some more things:
- Checking the duplicate check works when you have the entered
invoice number in your database multiple times already.
- Checking that no duplicate message is shown if you enter the
invoice number and it's already been used for an invoice from
another vendor.
Looks all good. I think the only thing we could argue about here
is if this could be activated by default for new installations.
There is currently no way to delete unused invoices (for example,
invoices created by mistake), and there really should be, since errors
and absent-mindedness can result in numerous empty invoices over the
course of years.
To test:
1) Apply patch.
2) Create three invoices in the Acquisitions module. For one of them,
receive at least one item. For the other two, do not receive any
items.
3) View one of the invoices that does not have any items on it.
4) Try to delete it. This should succeed.
5) View the invoice that has an item. There should not be any option
to delete it.
6) Do an invoice search that brings up the other invoice with no items
on it. Try to delete it from the results page. This should succeed.
7) Run the unit test:
> prove t/Acquisition/Invoice.t
8) Sign off.
Signed-off-by: Srdjan <srdjan@catalyst.net.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
All tests and QA script pass. I also did another test:
I cancelled all receipts from an existing invoice and then could
successfully delete it in the last step.
Jonathan Druart [Thu, 23 May 2013 14:42:38 +0000 (16:42 +0200)]
Bug 10317: improve display when order receiving page is given an invalid invoiceid
This patch fixes some things on the order receiving/parcel page.
1/ Removes dead code
2/ Displays an error message if invoiceid is unset or does not refer to an
invoice
3/ Fixes a bug in the note ("change note" and "add note" links)
Test plan:
1/ Try to call the invoice page with an existing invoiceid and check
that order results are consistent.
2/ Try without invoiceid or a bad invoiceid and check that an error
message is displayed.
3/ Add and change notes.
Signed-off-by: Cedric Vita <cedric.vita@dracenie.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Works nicely for all tests done.
- parcel.pl with invalid invoicenumber gives a nice error message
- parcel.pl with a valid invoicenumber looks normal
- changing and editing order notes works well
Fridolyn SOMERS [Fri, 31 May 2013 08:17:08 +0000 (10:17 +0200)]
Bug 10384: fall back to normal authentication if LDAP server is not available
This fixes a bug where, assuming LDAP authentication is enabled, if a user
tries to log in while the LDAP server is down, the following fatal error
is displayed:
Can't call method "bind" on an undefined value at C4/Auth_with_ldap.pm line 134, <DATA> line 558.
This patch catches this error to allow normal authentication when LDAP connexion fails.
Test plan :
- Configure LDAP connexion with a host not having LDAP. ie :
<useldapserver>1</useldapserver>
<ldapserver id="ldapserver">
<hostname>localhost</hostname>
<base>dc=test,dc=com</base>
<user>cn=Manager,dc=test,dc=com</user>
<pass>passwd</pass>
<replicate>0</replicate>
<update>0</update>
<auth_by_bind>0</auth_by_bind>
<mapping>
<firstname is="givenname" ></firstname>
<surname is="sn" ></surname>
<branchcode is="branch" >MAIN</branchcode>
<userid is="uid" ></userid>
<password is="userpassword" ></password>
<email is="mail" ></email>
<categorycode is="employeetype" >PT</categorycode>
</mapping>
</ldapserver>
- Try to connect with mysql user (defined in koha-conf.xml)
- Try to connect with a user defined in borrowers
You may try to connect with working LDAP connexion
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Kyle M Hall [Wed, 17 Apr 2013 13:33:55 +0000 (09:33 -0400)]
Bug 9533: batch item modification form now shows default field values only by request
This patch makes the pre-population of the fields for the batch
item editor with the default values from the default framework
optional and off by default.
Test Plan:
1) Apply patch
2) Add default values for cost and replacement cost to the
default framework.
3) Browse to Tools / Batch item modification
4) Choose a file, or entire some barcodes in the text area
5) Ensure that the 'Populate fields with default values from default
framework' is *not* checked
6) Click 'Continue'
7) Observe that the fields for cost and replacement cost are blank
8) Click the 'back' button on your browser
9) Check the checkbox to enable the default value
10) Click 'Continue'
11) Observe that the fields for cost and replacement cost now contain
the default values you assigned them in the default MARC framework
Signed-off-by: David Cook <dcook@prosentient.com.au> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Switch works correctly, all tests and QA script pass.
Note: there is a bug with default values for all non text input
fields. Default values won't be applied for those fields as the
pull downs are not preselected correctly with the default values
defined in the framework.
Fridolyn SOMERS [Wed, 26 Jun 2013 15:52:40 +0000 (17:52 +0200)]
Bug 9113: fix handling of certain characters by item batch modification tool
If you're using the batch modification tool and entering a call number
like "E+ 123 ABC", the tool removes the + and puts a space in its place,
e.g., "E 123 ABC"
This is because the form is posted via Ajax by background-job-progressbar.js.
Values are URI-encoded using escape(), but this method does not escape some
characters: * @ - _ + . /
Also, "+" is considered as a space in a URI.
This patch replaces escape() by encodeURIComponent() which encodes every character.
Test plan :
Perform an items batch modification by setting '* @ - _ + . /' in a field
(notes for example) and see that all characters are saved correctly.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Marc Veron [Fri, 14 Jun 2013 14:37:23 +0000 (16:37 +0200)]
Bug 5894: Display all titles when confirming copy of items from cart to list
Adds missing code that splits biblios before calling template.
To test:
- Add some items to cart
- Open cart, select some or all items
- Add to list; with patch, following window shold show something
like "Add 3 items to a list:", followed by list of items
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Passes koha-qa.pl, works as advertised.
Katrin Fischer [Sun, 16 Jun 2013 07:09:33 +0000 (09:09 +0200)]
Bug 10474: Translate some English strings in German sample notices
This translates 2 strings missed doing the initial translation in
ISSUESLIP.
To test:
- Run the web installer in German.
Altnernatively:
- Truncate your letters table and run the SQL against the database.
Check that the notices were added correctly, especially ISSUESLIP.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
There were 5 redundant mappings left in the file. They are removed.
Its almost a QA followup as everything went fine anyway.
Sponsored-by: Universidad Nacional de Córdoba Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This patch provides a definition file for Spanish (es) character
sorting in Zebra. It is based on the ideas from Hugo Agud <hagud@orex.es>
and Pablo Bianchi <pablo.bianchi@gmail.com>.
Makefile.PL is fixed to notice the existence of the 'es' language. The
docs for koha-create are touched too.
To test:
Tarball
=======
- Go through the install process, choosing 'es' for the Zebra's language step
- Koha should work as usual.
- Running this should show the lang definition is properly set.
$ grep -R "lang_defs/es" /etc/koha/*
(stuff like zebradb/zebra-biblios-dom.cfg:profilePath:...etc/koha/zebra/lang_defs/es... should show)
- This file should be present:
/etc/koha/zebradb/lang_defs/es/sort-string-utf.chr
Packages
========
- Build your own package, it shouldn't break the packaging
- Try the new package, using koha-create to set an instance using --lang 'es'
Sponsored-by: Universidad Nacional de Córdoba Signed-off-by: Galen Charlton <gmc@esilibrary.com> Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Owen Leonard [Wed, 5 Jun 2013 18:03:51 +0000 (14:03 -0400)]
Bug 10346 - "Add multiple copies" should be labelled "Add multiple items"
The Koha interface standardizes on the term "item" instead of "copy," so
the "Add multiple copies" button would be more correctly labeled "Add
multiple items."
To test, view the add item screen for an existing or new record. You
should see a button labeled "Add multiple items."
Signed-off-by: Cedric Vita <cedric.vita@dracenie.com> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Fridolyn SOMERS [Fri, 7 Jun 2013 08:17:54 +0000 (10:17 +0200)]
Bug 10428: undefined check in add additem.pl
In additem.pl, in the code that generates item form you find:
@values = $itemrecord->field($tag)->subfield($subtag) if ($itemrecord && defined($itemrecord->field($tag)->subfield($subtag)));
This patch adds the check of $itemrecord->field($tag) undef.
I did not found a way to test it because item tag is always defined
when editing an item, but it would be safer/prettier to add this check.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Passed-QA-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 10488: Followup replacing DELETEs by more restricted INSERTs
Instead of inserting followed by deleting, this patch combines the two where
clauses of both sql statements, meanwhile leaving the separation intact.
As suggested by Galen, removed all 162's from the non-default types.
The 162 calls for a new authority type. We can add that later on.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Ran this .sql script after deleting all auth records.
The former version had 9 types, 1148 tags and 11621 subfields.
This one has 9 types, 1140 tags and 11597 subfields.
That is expected: 8 tags 162 less and 8x3 subfields less.
Bug 10488 - New MARC21 authority tags and subfields should be propagated to non-default frameworks
As proposed by the report creator, this patch
rewites authorities_normal_marc21.sql
using default authority framework to build all
current authtypes, then deleting irrelevant tags.
It also updates default authority framework
to last update (April 2013) adding new or
updated tags/subtags.
All new tags/subtags from Bug 9826 and this
one are included in all authtypes.
Deleted tags reflect current situation except
for 7XX tags thatl must be present for all authtypes.
Only for new installs
To test:
1) Apply patch
2) Delete all authtypes
exec in database
delete from auth_types;
delete from auth_tag_structure;
delete from auth_subfield_structure;
3) Insert new auth framework
4) Verify absent tags. This can be done running
select tagfield as from auth_tag_structure
where authtypecode ='' and tagfield not in
(select tagfield from auth_tag_structure
where authtypecode = 'AUTH_TYPE')
for each authtype ( UNIF_TITLE, TOPIC_TERM, etc.)
The attached PDF could be used as a reference,
all that is white or green for each authtype must be
in the list (except for white 7XX tags)
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Jonathan Druart [Thu, 4 Apr 2013 10:04:46 +0000 (12:04 +0200)]
Bug 9987: Remove DB field aqorders.biblioitemnunmber
The DB field aqorders.biblioitemnumber seems to be unused except to get
the itype on the spent.pl page.
This information can be retrieved uising another SQL join.
Test plan:
Try a complete workflow in the acquisition module: create an order,
receive it, play with the syspref AcqCreateItem.
Check that no regression is found and that the data for existing
orders don't change.
Signed-off-by: Mathieu Saby <mathieu.saby@univ-rennes2.fr> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 10029 - CAS authentication fails in OPAC reserve
If OPAC reserve page is accessed without being logged-in, login form is displayed as well as a CAS authentication link (if enabled). A click on this link will lead to CAS server but one comming back to Koha, page shows an error : "ERROR: No biblionumber received".
This is because CAS link only contains the query path "/cgi-bin/koha/opac-reserve.pl", not the query parameters.
This patch adds query parameters to URI sent to CAS.
Test plan :
- Enable CAS
- Go to opac without been logged-in
- Try to place hold on a record
=> You get to /cgi-bin/koha/opac-reserve.pl?biblionumber=XXX showing authentication page
=> Check that CAS link contains query param "biblionumber"
- Click on CAS link and log in
=> Check you return well logged-in to reserve page with biblionumber param
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
I have followed the test plan as far as I could and the links
contain the biblionumber now, which they didn't before.
I couldn't check the CAS login, but my normal login worked
as expected.
All tests and the QA script pass.
Marcel de Rooy [Wed, 8 May 2013 14:29:23 +0000 (16:29 +0200)]
Bug 9998: new tool to import/export and compare system preferences
This patch adds a new maintenance script: cmp_sysprefs.pl
Test plan:
1 Run with -cmd backup -file zz01. Check that file.
Run with -cmd test -file zz01. Check zz01.sav.
2 Run with -cmd compare -file zz01. No differences expected.
3 Edit zz01: delete two prefs, change two prefs and add two new prefs.
4 Run with -cmd compare -file zz01. Are all six changes reported?
5 Add local use preference zz02 in the staff client (no explanation, options).
6 Run with -cmd backup -file zz02.
7 Delete local use pref zz02 from the staff client.
8 Run with -cmd restore -file zz02. Check if local pref zz02 came back.
9 Delete local use pref zz02 again from the staff client.
10 Run with -cmd compare -file zz02 -add. Check if local pref zz02 came back.
11 Change the value of zz02 in the staff client.
12 Run with -cmd compare -file zz02 -add. Check the value: not updated?
13 Run with -cmd compare -file zz02 -upd. Check the value: updated now?
14 Edit file zz02. Add a comment line and delete the line for pref zz02.
15 Run with -cmd compare -file zz02 -del. Is pref zz02 deleted?
16 Add local use preference zz02 in the staff client (WITH explanation).
17 Run with -cmd compare -file zz02 -del. pref zz02 should not be deleted.
18 Run with -cmd compare -file zz02 -del -ign-opt. zz02 should be deleted now.
Do the next steps only on a restorable test db:
19 Create file zz03. Leave it empty.
Compare with: -cmd compare -file zz03 -del -ign-opt.
All prefs gone except Version?
20 Restore with: -cmd restore -file zz01.sav.
Compare with -cmd compare -file zz01.sav. Nothing reported?
Note: The explanation or options are not recovered. (See also BZ 10199.)
This affects local use preferences only.
If you need them, restore your test db. Remove the zz files.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Amended patch
Only cosmetic stuff:
Perltidied with xt/perltidyrc.
Replaced most double quotes by single quotes around SQL statements.
Moved the usage into POD for pod2usage.
Passing no file shows help screen too.
Counting the db updates more accurately with return value of do.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Owen Leonard [Wed, 26 Jun 2013 16:54:15 +0000 (12:54 -0400)]
Bug 10510 - OPAC's renew selected link has glitchy icon
The "renew selected" link on the list of a user's checkouts looks bad
because the next icon in the sprite shows through. This patch modifies
the sprite to give it proper spacing and corrects the CSS to accommodate
the change.
To test, apply the patch, clear your browser cache, and view the
following pages to confirm that the change works:
- With TagsEnabled and TagsInputOnList enabled, view a search results
page when logged in and when not logged in. Tag links should be
styled correctly.
- With OpacBrowseResults enabled, open the detail page for any record
and click the "browse shelf" link. The "forward" and "back" arrows
should be styled correctly.
- With OpacRenewalAllowed enabled, log in to the OPAC and view your
checked out items. The "renew selected" and "renew all" links should
look correct.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Note: this will fix only the prog theme, but not the ccsr theme.
And it works perfectly.
Liz Rea [Thu, 9 May 2013 21:32:17 +0000 (09:32 +1200)]
Bug 6553 - Parentheses in Corporate author break tracings
To test:
If an author's name includes parentheses or other escape-characters, the tracing links
produced in the OPAC fail in XSLT mode. This patch wraps the author names
in double-quotes, providing the necessary escapement.
Test plan:
- Create a new framework, delete Thesaurus from 100 and other fields
- Create a new record in this framework (or change an existing record to this framework)
- Add 100$a - use parentheses
- Check the search links in OPAC detail pages
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
XSLT change adding quotes. Search now matches search in the intranet.
Passes all tests.
Kyle M Hall [Mon, 17 Jun 2013 16:28:13 +0000 (12:28 -0400)]
Bug 10484: serials-edit.pl not checking for barcode field before checking for barcode subfield
The script serials-edit.pl is not checking for the existence of the
barcode field before checking for barcode subfield for autoBarcode =
incremental. If the barcode field doesn't exist, the script dies with
errors.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes tests and QA script.
Checked that adding items on serial receive still works.
Galen Charlton [Wed, 19 Jun 2013 15:52:56 +0000 (08:52 -0700)]
Bug 10494: remove spurious warnings from the KohaBranchName plugin
The KohaBranchName plugin now returns an empty string if
given a NULL (undefined) library code or a library code that
is not present in the database (e.g., the '__ANY__' placeholder
that purchase suggestions can use).
To test:
[1] Create a purchase suggestion, setting the library
to 'Any'. Create a second one setting the library to
a specific one.
[2] Go to the suggestions overview page in the staff interface.
When you do so, the Apache logs should contain a warning
that looks like this:
[Wed Jun 19 07:13:06 2013] [error] [client 192.168.1.10] [Wed Jun 19 07:13:06 2013] suggestion.pl: Use of uninitialized value in concatenation (.) or string at /home/koha/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt line 487., referer: http://koha-staff.metaquarry/cgi-bin/koha/acqui/acqui-home.pl
[3] Apply the patch.
[4] Refresh the suggestions overview page. This time, there should be
no new warning logged.
[5] Verify that the library names for the two pending suggestions
created in step 1 are displayed correctly.
Signed-off-by: Galen Charlton <gmc@esilibrary.com> Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script. Also adds new tests!
Note: For the test plan to work you have to add the suggestion
from the intranet, as Any is not an available option in OPAC.
Galen Charlton [Fri, 14 Jun 2013 22:55:02 +0000 (15:55 -0700)]
Bug 8884: (follow-up) rearrange placement of the top-bar div in CCSR
This patch makes it easier to avoid having the top bar
overlap other OPAC page content (particularly custom
header content set via the opacheader system preference).
This is done by moving the top-nav div outside of the
main doc3 div and adjusting the CSS accordingly. Yes,
this does end up having top-nav.inc be included from
opac-bottom.inc, but it would require touching rather
more templates to have it be included immediately after
the <body> tag.
This patch also removes a duplicate instance of the
cmspan span.
To test:
[1] Change to the CCSR OPAC theme.
[2] Before applying the patch, open a set of OPAC
pages (e.g., main page, user page, search results, bib
details) in your web browser.
[3] Apply the patch, and open the same OPAC pages in separate
tabs. Comparing the pre- and post- version of each page
to verify that the placement
[4] Add an OpAC header using the opacheader system preference.
[5] Verify that the header is displayed without overlapping
the top bar.
In CCSR the opacheader preference isn't really in the header it's to the
right of the search box (see attached). I'm okay with a customizable
region over there, but we should have a new preference for that and
header should be above the search box as it implies.
To test:
1) Put something in the OpacHeader syspref. Preferably something large
and header-like for maximum effect.
2) Select CCSR theme.
3) View OPAC. Notice placement of "header" content.
4) Apply patch.
5) View OPAC. Notice placement of "header" content.
6) Sign off.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Passes koha-qa.pl, works as advertised with one caveat; the content of
opacheader is by default underneath the div "top-bar". A couple breaks
in my OpacHeader test made it visible, so I'm going to assume this is a
styling issue and not a bug as such.
Marcel de Rooy [Mon, 3 Jun 2013 13:27:50 +0000 (15:27 +0200)]
Bug 10386: improvements to VirtualShelves.t
Most important: Does no longer delete all shelves!
Checks if there are ten borrowers for testing. But even works without them :)
When creating or modifying lists, takes name clashes into consideration.
Small change to _CheckShelfName in VirtualShelves module. Making it possible to
check a name for a list whose owner has been set to NULL. Note that a test
like field=? with undef for placeholder will not work in MySql.
Test plan:
How do you test a test? Well, you could run it on various databases..
But for real hacking, you could also add some debug lines.
I tested this by forcing 10 undefs in @borrowernumbers.
And by overwriting the return value of randomname with an existing name.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Marcel de Rooy [Mon, 24 Jun 2013 10:33:58 +0000 (12:33 +0200)]
Bug 7368: Followup for columns names in userflags.sql
An insert statement should contain the column names to avoid confusion and
future problems with table definition changes.
This patch updates the English userflags.sql.
Will send updates for the other languages in connection with replacing inserts
by updates for the additional languages (where possible). For userflags this
will be possible.
Test plan:
Do an install (English).
Or -- as a dangerous(!) alternative--:
Do this ONLY on a restorable database.
Delete all records in userflags. (Note: This cascades to permissions a.o.)
Run this file from command line.
Check if you have records again in userflags. (You also messed up your Koha.)
Restore your database.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Tested both ways myself :)
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Comment: Work as described. No errors.
Tested using second alternative
Just a note: if you update other lang files replacing INSERTs for UPDATEs
then you must install using EN and later apply lang files by hand.
If you do a translate first before webinstaller, and finish your install
in your lang, then that kind of file will fail.
Jonathan Druart [Fri, 24 May 2013 14:18:59 +0000 (16:18 +0200)]
Bug 10336: HoldsQueue.t needs to create its own data
After applying this patch and the patch submitted in bug 10495, you can
run prove t/db_dependent/HoldsQueue.t and admire that all tests pass.
This patch creates a borrower and uses Koha routines instead of directly
updating the database.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Galen Charlton [Wed, 19 Jun 2013 17:30:58 +0000 (10:30 -0700)]
bug 10495: set precondition for HoldsQueue test
t/db_dependent/HoldsQueue.t assumed, but did not check,
that the AutomaticItemReturns system preference was off
at the beginning of the test un. This patch makes sure
that that assumption is met.
To test:
[1] Make sure that at least one item is on loan (this is
another assumption that the test case makes, one
that should be corrected with the work proposed
for bug 10336.
[2] Turn the AutomaticItemReturn system preference on.
[3] Run the test:
prove -v t/db_dependent/HoldsQueue.t
[4] Tests 4 and 6 should fail.
[5] Apply the patch.
[6] Run the test case again; this time, all tests should pass.
Owen Leonard [Wed, 6 Mar 2013 01:23:56 +0000 (20:23 -0500)]
Bug 9757: Make staff client list contents view more like search results
This patch revises the staff client list contents view to better match
staff client search results, showing more information and offering more
ways to interact with the contents than before.
- List contents output has been modified so that the staff client can
use XSLT-formatted data just as the OPAC can. As in the OPAC it
depends on XSLTResultsDisplay being enabled.
- A "toolbar" has been added which is similar to that in search results,
offering the option to add items to a Cart, add them to a different
list, place multiple holds, remove items from the list, or merge
records.
- This toolbar has been made to float on scroll like the one on the
MARC edit page.
- Library and shelving location have been added to the display of call
numbers. Call numbers are linked to a search as they are in search
results.
- Edit links are included just as they are in search results.
- Automatic focus on the add by barcode form has been removed so that
the page doesn't jump to the bottom unnecessarily.
- basket.js's "addMultiple" function has been modified so that it
receives an array of checkboxes rather than looking for checkboxes in
a specific form. This helps abstract its functionality for use on both
search results and lists. results.tt is modified accordingly.
- The page layout has been widened to make room for the increased amount
of information on the page.
- A new "merge" icon has been added to the default Bootstrap sprite.
To test:
- View both public and private lists in the staff client.
- View lists with and without contents.
- Test the functionality of options in the toolbar: Add to cart, add to
lists, place multiple holds, remove items, merge items.
- Test with users with and without cataloging privileges to confirm that
catalog-related controls are correctly shown or hidden.
- Test with XSLTResultsDisplay set both to "default" and empty.
- Since the staff client and OPAC use some of the same code, test that
lists in the OPAC have not broken.
- Since JavaScript was modified which affects both lists and search
results, confirm that adding items to the Cart and Lists from search
results hasn't been broken by this patch.
Revision corrects conditional display of hold link, hiding it in cases
where there are no items or the record's itemtype is not for loan.
Also corrected is the behavior of the Cart/List "save" button in order
to prevent it from submitting the "remove items" action which is the
default for the form.
Signed-off-by: jmbroust <jean-manuel.broust@univ-lyon2.fr>
Edit: Patch rebased against current master and hard-coded paths to
/prog/ corrected.
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Magnus Enger [Tue, 25 Jun 2013 06:39:23 +0000 (08:39 +0200)]
Bug 10379 - Followup: add koha-rebuild-zebra -q to the man page
The first patch on this bug forgot to add the new -q option to
koha-rebuild-zebra to the man page for that command. This patch
fixes it.
To test, run something like these commands:
$ xsltproc /usr/share/xml/docbook/stylesheet/docbook-xsl/manpages/docbook.xsl \
debian/docs/koha-rebuild-zebra.xml
$ man -l koha-rebuild-zebra.8
This should display the man page. (Remember to remove koha-rebuild-zebra.8
when you are done :-)
$ prove xt/verify-debian-docbook.t
All tests should pass.
Signed-off-by: Robin Sheat <robin@catalyst.net.nz> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Robin Sheat [Thu, 30 May 2013 04:12:13 +0000 (16:12 +1200)]
Bug 10379: silence zebra rebuild cron when no instances are enabled
This adds a -q option to koha-rebuild-zebra that prevents it outputting
help if no instances are provided on the command line. This means that
if you've just installed the package, you won't get messages from cron
telling you how to use the script.
Test plan:
* install koha-common 3.12 or master onto a system with no enabled
instances.
* note that you or the sysadmin will start getting emails every 5
minutes.
* replace /etc/cron.d/koha-common and /usr/sbin/koha-rebuild-zebra with
the versions from this patch.
* note that the emails stop flowing.
Signed-off-by: Magnus Enger <magnus@enger.priv.no>
"sudo koha-rebuild-zebra -q" gives no output, as expected.
Followed the test plan, all looks good. Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 9890: fix plugin handling by koha-create and koha-create-dirs
1) koha-create: fill in __PLUGINS_DIR__
2) koha-create-dirs: create the directory, set permissions (writeable by the koha user)
Sponsored-by: Universidad Nacional de Córdoba Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Robin Sheat <robin@catalyst.net.nz> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
t/db_dependent/needs_user_input/Auth.t and
t/db_dependent/needs_user_input/Auth_with_ldap.t seem not really useful.
If I refer to the git history, it seems that they are antiquated tests.
The first one is not compilable:
perl -wc t/db_dependent/needs_user_input/Auth.t
Can't locate override_context_prefs.pm
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Owen Leonard [Tue, 9 Apr 2013 14:52:12 +0000 (10:52 -0400)]
Bug 10010 - Use jQueryUI Accordion to display constraints in MARC subfield editor
The jQueryUI Accordion widget, included by default in Koha, is
well-suited to handle the kind of show/hide actions which are used in
the MARC subfield editor. This patch replaces the custom-writted JS with
jQueryUI JS and markup.
To test, load the tag subfield editor: Admin -> MARC frameworks -> MARC
structure -> Subfields -> Edit. Confirm that basic, advanced, and other
contraints panels are show/hidden correctly. Confirm that tabs work, and
that edit operations are not disrupted.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Looks nice, passes all tests and QA script. Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Owen Leonard [Tue, 27 Nov 2012 16:16:14 +0000 (11:16 -0500)]
Bug 7110: Renewal messages no longer displays in OPAC if OpacRenewalAllowed is disabled
Prior to this patch, if a patron has fines which exceed the limit set by
OPACFineNoRenewals but OPAC renewals are disallowed by OpacRenewalAllowed,
a message was displayed in their OPAC summary like this:
"Please note: You currently owe XXX in fines. Please pay your fines if you wish
to renew your books."
Information about outstanding fines in this case has no bearing on
how the user sees his summary of checkouts; since the user cannot
renew the loans from the OPAC regardless of their fine balance if
OpacRenewalAllowed is not enabled, this patch removes the message.
To test, try various combinations of OpacRenewalAllowed and
OPACFineNoRenewals with a patron who has outstanding fines:
- OpacRenewalAllowed ON and OPACFineNoRenewals ON (set to be triggered
by the test patron's fines): Logging in to the OPAC the patron should
see a warning on opac-user.pl about not being able to renew items
because of fines.
- OpacRenewalAllowed ON and OPACFineNoRenewals OFF (threshold high
enough not to trigger a block): No warning appears.
- OpacRenewalAllowed OFF and OPACFineNoRenewals ON: No warning appears.
- OpacRenewalAllowed OFF and OPACFineNoRenewals OFF: No warning appears.
If OpacRenewalAllowed is diabled and a patron's fines exceed the limit
set by OPACFineNoRenewals they should see no message.
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Passes koha-ql.pl and perlcritic
Kyle M Hall [Thu, 20 Dec 2012 14:31:23 +0000 (09:31 -0500)]
Bug 9307 - Allow libraries to add/edit status for suggestion management.
This patch allows for the addition of new suggestion status by adding
authorised values of the category SUGGEST_STATUS
I sign it off. Details of my test plan :
1. Applying the patch
2. Checking existing suggestions, in staff view and opac : ok
3. Creating a new suggestion in staff and in opac : ok
4. Moving a suggestion into one of the old categories : ok
5. Adding a new authorized value category named SUGGEST_STATUS and fill it with 3 values :
value Description Description (OPAC) =)>
tata tatapro tataopac
titi titipro titiopac
toto totopro totoopac
For "tata", I defined a branch restriction on branche B.
6. Connecting in staff interface as a librarian of branch A : I could only use codes titipro and totopro. On OPAC, these codes were displayed as totoopac and titiopac
7. Connecting as librarian of branch B : I could use the 3 codes
8. Checking tabs visible : new tabs for tata, titi, toto, but also a new "Unknown" tab with 0 record.
Maybe point 8 could be fixed in a followup.
I sign off the patch.
Signed-off-by: Mathieu Saby <mathieu.saby@univ-rennes2.fr> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Galen Charlton [Tue, 18 Jun 2013 15:37:09 +0000 (08:37 -0700)]
Bug 10332: further improvements to course reserves tests
- Wrap tests in a database transaction; that
way, no special cleanup code is required
- Use AddItem rather than AddItemFromMarc to create
test items; there's no need to build in a
dependence on any particular MARC flavor or
framework in our test cases (except, of course,
for test cases that are explicitly exercising
code that involves the frameworks).
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Without correct data, test fails prior to patch, passes no matter what
after patch is applied.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Bug 9826 - Missing fields in MARC21 authority framework
This patch updates MARC21 authority framework adding
missing tags/subtags up to Update No. 15 (September 2012)
Missing tags and corresponding subtags only added to
default authority framework.
For present authtypes only missing subtags are added.
Also updates a few legends to match those from LOC.
No deletions except for a few not relevant tags in
present authtypes without subfields.
Only to new installs.
To test:
1) Delete present authority frameworks
2) Load new frameworks. On default there are
many new tags/subtags. On present authtypes
only a few new/renamed subtags.
Signed-off-by: Mason James <mtj@kohaaloha.com> Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz> Signed-off-by: Galen Charlton <gmc@esilibrary.com>
Kyle M Hall [Tue, 19 Feb 2013 16:41:59 +0000 (11:41 -0500)]
Bug 9541: make OPAC login page respect OPAC_CSS_OVERRIDE
When clicking the login link for opac-user.pl in a multiple branch
scenario the environment variable for OPAC_CSS_OVERRIDE was ignored from
the koha-conf.xml file. It seems like is is working on every page in
the opac except for the login page.
Test Plan:
1) Set up a Koha server with 2 separate catalog configurations
( e.g. opac1.kohatest, opac2.kohatest )
2) Set the OPAC_CSS_OVERRIDE directive for separate css files
in each opac
3) Browse to the opac login page, note the css is not applied
4) Apply this patch
5) Reload the page, note the css is now applied