koha.git
12 years agoBug 7271 - change sort in items.pm to sort by home library instead of holding branch
Liz Rea [Mon, 28 Nov 2011 17:39:33 +0000 (11:39 -0600)]
Bug 7271 - change sort in items.pm to sort by home library instead of holding branch

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7517: Revised Patch. Patron category types not displaying <optgroup> in dropdown.
Garry Collum [Sat, 25 Feb 2012 20:09:45 +0000 (15:09 -0500)]
Bug 7517: Revised Patch. Patron category types not displaying <optgroup> in dropdown.

The patron category drop-down box does not display the general category groups as it once did.  This patch fixes the display of the optgroups.

To test. Before applying the patch, go to a patron record.  Edit the patron. Select the category drop-down in Library Management to see if the general categories appear. After the patch is applied the dropdown will show the categories.  'Child' - child categories, 'Adult' - adult categories, etc.

Fixes XHTML errors.
1. Invalid end tag for cardnumber input.
2. Extra quote in textarea.
3. The label for debarredcomment did not have a corresponding id.  There are two instances of this id field because of an 'IF' statement, this patch failed QA in the prior patch because only one of these ids was changed.

Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7493 follow-up DBRev number
Paul Poulain [Thu, 8 Mar 2012 16:02:00 +0000 (17:02 +0100)]
Bug 7493 follow-up DBRev number

12 years agoBug 7493 [REVISED] Deleting a record with comments breaks "Recent Comments"
Owen Leonard [Mon, 6 Feb 2012 14:05:18 +0000 (09:05 -0500)]
Bug 7493 [REVISED] Deleting a record with comments breaks "Recent Comments"

Adding foreign key constraint on biblio and borrowers:

- delete reviews when bibliographic records are deleted
- set set reviews.borrowernumber to NULL when patron records are deleted.

Before these constraints are set the database update script will
clean up existing instances of these problems by deleting reviews of
deleted biblios and setting to NULL reviews.borrowernumber for deleted
patrons.

In comments moderation, the list of comments will indicate "(deleted patron")
if the review was submitted by a patron who has since been deleted.

In the OPAC display of comments will omit the patron name altogether
if the patron has since been deleted.

To test:

1. CONFIRM THAT THE DATABASE UPDATE RUNS CORRECTLY

Before applying the patch:

 - delete the record for a title which has a review
 - delete a patron who has submitted a review (on a different title).

Viewing /cgi-bin/koha/opac-showreviews.pl should result in an error.

Apply the patch and make sure the database update runs. Viewing
the recent comments page in the OPAC should no longer result in an
error. The title with the comment from a deleted patron should
show no patron name on these pages:

 - Recent comments (opac-showreviews.pl)
 - Recent comments RSS (opac-showreviews.pl?format=rss)
 - Detail page (opac-detail.pl)

Comments from other patrons should show correctly.

2. CONFIRM THAT NEW DELETIONS PERFORM CORRECTLY

After applying the patch:

 - delete the record for a title which has a review
 - delete a patron who has submitted a review (on a different title).

Viewing /cgi-bin/koha/opac-showreviews.pl should NOT result in an error.
The review of the title which you deleted should no longer appear in the
list of recent comments.

The title with the comment from a deleted patron should
show no patron name on these pages:

 - Recent comments (opac-showreviews.pl)
 - Recent comments RSS (opac-showreviews.pl?format=rss)
 - Detail page (opac-detail.pl)

Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7615 - Give option to use description for homebranch/holding branch in label...
Chris Nighswonger [Wed, 29 Feb 2012 00:21:11 +0000 (19:21 -0500)]
Bug 7615 - Give option to use description for homebranch/holding branch in label creator instead of the branchcode

This patch adds the ability to print the name of the item's homebranch on labels

Thanks to Shane Sammons <ssammons-at-npelem.com> for the modified SQL SELECT statement.

Document Manager: The documentation will need to be updated to reflect the added field 'branchname' to the list
of available fields for label printing.

To test:

1. Create a new label layout or modify an existing one to include 'branchname'
2. Create a new label batch or using an existing one, export the batch.
3. Verify that the resulting labels contain the home branch name for the respective items.

Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Tested with the plan - works

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7616 - Remove unused template markup for css_libs, css_module, js_libs, etc.
Owen Leonard [Tue, 28 Feb 2012 20:23:02 +0000 (15:23 -0500)]
Bug 7616 - Remove unused template markup for css_libs, css_module, js_libs, etc.

Removing references to unused template variables and markup.

Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7584 - Update cart and lists buttons style using CSS3 features
Owen Leonard [Wed, 22 Feb 2012 20:23:12 +0000 (15:23 -0500)]
Bug 7584 - Update cart and lists buttons style using CSS3 features

Replacing styling of cart and lists buttons with CSS3 features:
border-radius, background-gradient, multiple backgrounds. While
the CSS is a little more complicated, the markup is much simpler
which should make customization simpler.

Browsers tested:

Firefox 10 on Windows 7
Chrome 17 on Windows 7
Opera 11 on Windows 7
Internet Explorer 8 on Windows 7 (no rounded corners or background images)

Firefox 9 on Ubuntu 11.10
Chrome 16 on Ubuntu 11.10
Opera 11 on Ubuntu 11.10

Internet Explorer 6 on Windows XP (looks acceptably bad)

Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Also tested in:

Safari on Mac OS X
Firefox 10 on Mac OS X
Chrome on Mac OS X

All the above tests passed

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7284: Fix unit test broken by erroneous POD
Jared Camins-Esakov [Wed, 7 Mar 2012 23:55:52 +0000 (18:55 -0500)]
Bug 7284: Fix unit test broken by erroneous POD

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agobug 7284 follow-up: removing html tags <b> and <a href=> as they're displayed not...
Paul Poulain [Thu, 8 Mar 2012 14:23:29 +0000 (15:23 +0100)]
bug 7284 follow-up: removing html tags <b> and <a href=> as they're displayed not as HTML

12 years agobug 7284 2nd follow-up, fixing perl mistake
Paul Poulain [Wed, 7 Mar 2012 22:37:02 +0000 (23:37 +0100)]
bug 7284 2nd follow-up, fixing perl mistake

12 years agoBug 7284 follow-up, DBrev number
Paul Poulain [Wed, 7 Mar 2012 22:35:31 +0000 (23:35 +0100)]
Bug 7284 follow-up, DBrev number

12 years agoBug 7284: Improve UNIMARC Zebra configuration
Jared Camins-Esakov [Wed, 7 Mar 2012 17:18:25 +0000 (12:18 -0500)]
Bug 7284: Improve UNIMARC Zebra configuration

Add the Match-heading and Match-heading-see-from indexes to the UNIMARC Zebra
configuration.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Tested with an UNIMARC setup that things work fine. They do

12 years agosigned off Bug 7284: Authority matching improvements
Jared Camins-Esakov [Sat, 31 Dec 2011 17:17:41 +0000 (12:17 -0500)]
signed off Bug 7284: Authority matching improvements

Squashed patch incorporating all previous patches (there is no functional
change compared to the previous version of this patch, this patch merely
squashes the original patch and follow-up, and rebases on latest master).

=== TL;DR VERSION ===
*** Installation ***
1. Run installer/data/mysql/atomicupdate/bug_7284_authority_linking_pt1
and installer/data/mysql/atomicupdate/bug_7284_authority_linking_pt2
2. Make sure you copy the following files from kohaclone to koha-dev:
etc/zeradb/authorities/etc/bib1.att,
etc/zebradb/marc_defs/marc21/authorities/authority-koha-indexdefs.xml,
etc/zebradb/marc_defs/marc21/authorities/authority-zebra-indexdefs.xsl,
etc/zebradb/marc_defs/marc21/authorities/koha-indexdefs-to-zebra.xsl, and
etc/zebradb/marc_defs/unimarc/authorities/record.abs
3. Run misc/migration_tools/rebuild_zebra.pl -a -r

*** New sysprefs ***
* AutoCreateAuthorities
* CatalogModuleRelink
* LinkerModule
* LinkerOptions
* LinkerRelink
* LinkerKeepStale

*** Important notes ***
You must have rebuild_zebra processing the zebraqueue for bibs when testing this
patch.

=== DESCRIPTION ===

*** Cataloging module ***
* Added an additional box to the authority finder plugin for "Heading match,"
  which consults not just the main entry but also See-from and See-also-from
  headings.

* With this patch, the automatic authority linking will actually work properly
  in the cataloging module. As Owen pointed out while testing the patch,
  though, longtime users of Koha will not be expecting that. In keeping with
  the principles of least surprise and maximum configurability, a new syspref,
  CatalogModuleRelink makes it possible to disable authority relinking in the
  cataloging module only (i.e. leaving it enabled for future runs of
  link_bibs_to_authorities.pl).  Note that though the default behavior matches
  the current behavior of Koha, it does not match the intended behavior.
  Libraries that want the intended behavior rather than the current behavior
  will need to adjust the CatalogModuleRelink syspref.

*** misc/link_bibs_to_authorities.pl ***
Added the following options to the misc/link_bibs_to_authorities.pl script:
--auth-limit        Only process those headings that match the authorities
                    matching the user-specified WHERE clause.
--bib-limit         Only process those bib records that match the
                    user-specified WHERE clause.
--commit            Commit the results to the database after every N records
                    are processed.
--link-report       Display a report of all the headings that were processed.

Converted misc/link_bibs_to_authorities.pl to use POD.

Added a detailed report of headings that linked, did not link, and linked
in a "fuzzy" fashion (the exact semantics of fuzzy are up to the individual
linker modules) during the run.

*** C4::Linker ***
Implemented new C4::Linker functionality to make it possible to easily add
custom authority linker algorithms. Currently available linker options are:
* Default: retains the current behavior of only creating links when there is
  an exact match to one and only one authority record; if the 'broader_headings'
  option is enabled, it will try to link to headings to authority records for
  broader headings by removing subfields from the end of the heading (NOTE:
  test the results before enabling broader_headings in a production system
  because its usefulness is very much dependent on individual sites' authority
  files)
* First Match: based on Default, creates a link to the *first* authority
  record that matches a given heading, even if there is more than one
  authority record that matches
* Last Match: based on Default, creates a link to the *last* authority
  record that matches a given heading, even if there is more than one record
  that matches

The API for linker modules is very simple. All modules should implement the
following two functions:
<get_link ($field)> - return the authid for the authority that should be
linked to the provided MARC::Field object, and a boolean to indicate whether
the match is "fuzzy" (the semantics of "fuzzy" are up to the individual plugin).
In order to handle authority limits, get_link should always end with:
    return $self->SUPER::_handle_auth_limit($authid), $fuzzy;

<flip_heading ($field)> - return a MARC::Field object with the heading flipped
to the preferred form. At present this routine is not used, and can be a stub.

Made the linking functionality use the SearchAuthorities in C4::AuthoritiesMarc
rather than SimpleSearch in C4::Search. Once C4::Search has been refactored,
SearchAuthorities should be rewritten to simply call into C4::Search. However,
at this time C4::Search cannot handle authority searching. Also fixed numerous
performance issues in SearchAuthorities and the Linker script:
* Correctly destroy ZOOM recordsets in SearchAuthorities when finished. If left
  undestroyed, efficiency appears to approach O(log n^n)
* Add an optional $skipmetadata flag to SearchAuthorities that can be used to
  avoid additional calls into Zebra when all that is wanted are authority
  records and not statistics about their use

*** New sysprefs ***
* AutoCreateAuthorities - When this and BiblioAddsAuthorities are both turned
  on, automatically create authority records for headings that don't have
  any authority link when cataloging. When BiblioAddsAuthorities is on and
  AutoCreateAuthorities is turned off, do not automatically generate authority
  records, but allow the user to enter headings that don't match an existing
  authority. When BiblioAddsAuthorities is off, this has no effect.
* CatalogModuleRelink - when turned on, the automatic linker will relink
  headings when a record is saved in the cataloging module when LinkerRelink
  is turned on, even if the headings were manually linked to a different
  authority by the cataloger. When turned off (the default), the automatic
  linker will not relink any headings that have already been linked when a
  record is saved.
* LinkerModule - Chooses which linker module to use for matching headings
  (current options are as described above in the section on linker options:
  "Default," "FirstMatch," and "LastMatch")
* LinkerOptions - A pipe-separated list of options to set for the authority
  linker (at the moment, the only option available is "broader_headings," which
  is described below)
* LinkerRelink - When turned on, the linker will confirm the links for headings
  that have previously been linked to an authority record when it runs. When
  turned off, any heading with an existing link will be ignored.
* LinkerKeepStale - When turned on, the linker will never *delete* a link to an
  authority record, though, depending on the value of LinkerRelink, it may
  change the link.

*** Other changes ***
* Cleaned up authorities code by removing unused functions and adding
  unimplemented functions and added some unit tests.

* This patch also modifies the authority indexing to remove trailing punctuation
  from Match indexes.

* Replace the old BiblioAddAuthorities subroutines with calls into the new
  C4::Linker routines.

* Add a simple implementation for C4::Heading::UNIMARC. (With thanks to F.
  Demians, 2011.01.09) Correct C4::Heading::UNIMARC class loading. Create
  biblio tag to authority types data structure at initialization rather than
  querying DB.

* Ran perltidy on all changed code.

*** Linker Options ***
Enter "broader_headings" in LinkerOptions. With this option, the linker will
try to match the following heading as follows:
=600  10$aCamins-Esakov, Jared$xCoin collections$vCatalogs$vEarly works to
1800.

First: Camins-Esakov, Jared--Coin collections--Catalogs--Early works to 1800
Next: Camins-Esakov, Jared--Coin collections--Catalogs
Next: Camins-Esakov, Jared--Coin collections
Next: Camins-Esakov, Jared (matches! if a previous attempt had matched, it
would not have tried this)

This is probably relevant only to MARC21 and LCSH, but could potentially be of
great use to libraries that make heavy use of floating subdivisions.

=== TESTING PLAN ===

Note: all of these tests require that you have some authority records,
preferably for headings that actually appear in your bibliographic data. At
least one authority record must contain a "see from" reference (remember which
one contains this, as you'll need it for some of the tests). The number shown
in the "Used in" column in the authority module is populated using Zebra
searches of the bibliographic database, so you *must* have
rebuild_zebra.pl -b -z [-x] running in cron, or manually run it after running
the linker.

*** Testing the Heading match in the cataloging plugin ***
1.  Create a new record, and open the cataloging plugin for an
    authority-controlled field.
2.  Search for an authority by entering the "see from" term in the Heading Match
    box
3.  Confirm that the appropriate heading shows up
4.  Search for an authority by entering the preferred heading into the Main
    entry or Main entry ($a only) box (i.e., repeat the procedure you usually
    use for cataloging, whatever that may be)
5.  Confirm that the appropriate heading shows up

*** Testing the cataloging interface ***
6.  Turn off BiblioAddsAuthorities
7.  Confirm that you cannot enter text directly in an authority-controlled field
8.  Confirm that if you search for a heading using the authority control plugin
    the heading is inserted (note, however, that this patch does not AND IS NOT
    INTENDED TO fix the bugs in the authority plugin with duplicate subfields;
    those are wholly out of scope- this check is for regressions)
9.  Turn on BiblioAddsAuthorities and AutoCreateAuthorities
10. Confirm that you can enter text directly into an authority-controlled field,
    and if you enter a heading that doesn't currently have an authority record,
    an authority record stub is automatically created, and the heading you
    entered linked
11. Confirm that if you enter a heading with only a subfield $a that fully
    *matches* an existing heading (i.e. the existing heading has only
    subfield $a populated), the authid for that heading is inserted into
    subfield $9
12. Confirm that if you enter a heading with multiple subfields that *matches*
    an existing heading, the authid for that heading is inserted into
    subfield $9
13. Turn on BiblioAddsAuthorities and turn off AutoCreateAuthorities
14. Confirm that you can enter text directly into an authority-controlled field,
    and if you enter a heading that doesn't currently have an authority record,
    an authority record stub is *not* created
15. Confirm that if you enter a heading with only a subfield $a that *matches*
    an existing heading, the authid for that heading is inserted into
    subfield $9
16. Confirm that if you enter a heading with multiple subfields that *matches*
    an existing heading, the authid for that heading is inserted into
    subfield $9
17. Create a record and link an authority record to an authorized field using
    the authority plugin.
18. Save the record. Ensure that the heading is linked to the appropriate
    authority.
19. Open the record. Change the heading manually to something else, leaving
    the link. Save the record.
20. Ensure that the heading remains linked to that same authority.
21. Change CatalogModuleRelink to "on."
22. Open the record. Use the authority plugin to link that heading to the
    same authority record you did earlier.
23. Save the record. Ensure that the heading is linked to the appropriate
    authority.
24. Open the record. Change the heading manually to something else, leaving
    the link. Save the record.
25. Ensure that the heading is no longer linked to the old authority record.

*** Testing link_bibs_to_authorities.pl ***
26. Set LinkerModule to "Default," turn on LinkerRelink and
    BiblioAddsAuthorities, and turn AutoCreateAuthorities and
    LinkerKeepStale off
27. Edit one bib record so that an authority controlled field that has already
    been linked (i.e. has data in $9) has a heading that does not match any
    authority record in your database
28. Run misc/link_bibs_to_authorities.pl --link-report --verbose --test (you may
    want to pipe the output into less or a file, as the result is quite a lot of
    information)
29. Look over the report to see if the headings that you have authority records
    for report being matched, that the heading you modified in step 2 is
    reported as "unlinked," and confirm that no changes were actually made to
    the database (to check this, look at the bib record you edited earlier, and
    check that the authid in the field you edited hasn't changed)
30. Run misc/link_bibs_to_authorities.pl --link-report --verbose (you may want
    to pipe the output into less or a file, as the result is quite a lot of
    information)
31. Check that the heading you modified has been unlinked
32. Change the modified heading back to whatever it was, but don't use the
    authority control plugin to populate $9
33. Run misc/link_bibs_to_authorities.pl --link-report --verbose
    --bib-limit="biblionumber=${BIB}" (replacing ${BIB} with the biblionumber
    of the record you've been editing)
34. Confirm that the heading has been linked to the correct authority record
35. Turn LinkerKeepStale on
36. Change that heading to something else
37. Run misc/link_bibs_to_authorities.pl --link-report --verbose
    --bib-limit="biblionumber=${BIB}" (replacing ${BIB} with the biblionumber
    of the record you've been editing)
38. Confirm that the $9 has not changed
39. Turn LinkerKeepStale off
40. Create two authorities with the same heading
41. Run misc/migration_tools/rebuild_zebra.pl -a -z
42. Enter that heading into the bibliographic record you are working with
43. Run misc/link_bibs_to_authorities.pl --link-report --verbose
    --bib-limit="biblionumber=${BIB}" (replacing ${BIB} with the biblionumber
    of the record you've been editing)
44. Confirm that the heading has not been linked
45. Change LinkerModule to "FirstMatch"
46. Run misc/link_bibs_to_authorities.pl --link-report --verbose
    --bib-limit="biblionumber=${BIB}" (replacing ${BIB} with the biblionumber
    of the record you've been editing)
47. Confirm that the heading has been linked to the first authority record it
    matches
48. Change LinkerModule to "LastMatch"
49. Run misc/link_bibs_to_authorities.pl --link-report --verbose
    --bib-limit="biblionumber=${BIB}" (replacing ${BIB} with the biblionumber
    of the record you've been editing)
50. Confirm that the heading has been linked to the second authority record it
    matches
51. Run misc/link_bibs_to_authorities.pl --link-report --verbose
    --auth-limit="authid=${AUTH}" (replacing ${AUTH} with an authid)
52. Confirm that only that heading is displayed in the report, and only those
    bibs with that heading have been changed

If all those things worked, good news! You're ready to sign off on the patch
for bug 7284.

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Rebased on latest master and squashed follow-up, 16 February 2012
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Rebased on latest master, 21 February 2012

Signed-off-by: schuster <dschust1@gmail.com>
12 years agoBug 3516 follow-up - DBRev number
Paul Poulain [Wed, 7 Mar 2012 16:30:49 +0000 (17:30 +0100)]
Bug 3516 follow-up - DBRev number

12 years agoBug 3516 [FOLLOW-UP] Display picture of patrons in OPAC
Owen Leonard [Thu, 1 Mar 2012 16:31:15 +0000 (11:31 -0500)]
Bug 3516 [FOLLOW-UP] Display picture of patrons in OPAC

This patch moves inline CSS to opac.css following QA comments.
Doing so improves users ability to customize the affected
markup with custom CSS.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 3516 [REVISED] Display picture of patrons in OPAC
Owen Leonard [Thu, 16 Feb 2012 20:25:39 +0000 (15:25 -0500)]
Bug 3516 [REVISED] Display picture of patrons in OPAC

This patch adapts the patron image display script from the
self-checkout module to optionally display the image of the
logged-in user on their personal information page (opac-userupdate.pl).
The script changes the method choosing which image to display
from using a passed cardnumber to using the borrowernumber of
the logged-in user.

A system preference is added, OPACpatronimages, to control
whether these images are displayed.

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Verified that patron image shows only when system preference is turned on
and that there are no display problems for patrons without patron image.

12 years agobug 5503 follow-up DBrev number + added "upgrade to $DBversion" string
Paul Poulain [Fri, 2 Mar 2012 17:37:41 +0000 (18:37 +0100)]
bug 5503 follow-up DBrev number + added "upgrade to $DBversion" string

12 years agoBug 5503 [REVISED] comments shouldn't show patron's full name
Owen Leonard [Fri, 16 Dec 2011 21:32:40 +0000 (16:32 -0500)]
Bug 5503 [REVISED] comments shouldn't show patron's full name

Adding a few choices for what information can be displayed
alongside comments in the OPAC:

- nothing
- full name
- first name
- last name
- first name and last name first initial
- username

Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Tested by choosing each choice and previewing an individual title
with a comment and confirming the name was displayed properly. Then
choosing each option and prevewing the recent comments page.

All tests passed.

Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Ran all tests again and it works as explained.

12 years agoBug 4912 [REVISED] After editing private list, user should be redirect to private...
Owen Leonard [Mon, 13 Feb 2012 17:12:25 +0000 (12:12 -0500)]
Bug 4912 [REVISED] After editing private list, user should be redirect to private lists

As far as I can tell there isn't a redirect in the code which is
triggered in the wake of a ModShelf() action. This patch adds a
redirect which is reflects the context of the original "edit" link.

To test, edit the details of a list in the OPAC from:

- the list of private lists
- the list of public lists
- the contents view of public or private list

After each of these actions you should be redirected back to
the page where you clicked the "edit" link.

Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 5877 DBrev numbering
Paul Poulain [Fri, 2 Mar 2012 17:05:38 +0000 (18:05 +0100)]
Bug 5877 DBrev numbering

12 years agoBug 5877 QA follow-up
Paul Poulain [Wed, 22 Feb 2012 17:12:04 +0000 (18:12 +0100)]
Bug 5877 QA follow-up

* removing tabs as indenter
* adding fieldnames in INSERT clause
* updating FSF address
* removing ` in SQL table creation (mysql-ism)
* use strict & use warning added & no error in logs checked

Note that process_koc.pl and updatedatabase are not related to this bug, but the FSF address was wrong, I fixed it as well

12 years agoBug 5877 Follow-up for Offline circulation improvements
Owen Leonard [Wed, 18 Jan 2012 19:53:37 +0000 (14:53 -0500)]
Bug 5877 Follow-up for Offline circulation improvements

Internationalization fix: Offline circulation operations in
Circulation.pm return English strings for display in the
template. These strings can't be translated, so we must check
their values in the JavaScript and return a translatable
string based on their values.

Interface change: Switching to text links for checking/unchecking
checkboxes since that is more consistent with other areas in
Koha.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 5877 : Offline circulation improvements : upload all files, apply at once
Paul Poulain [Fri, 2 Mar 2012 16:49:35 +0000 (17:49 +0100)]
Bug 5877 : Offline circulation improvements : upload all files, apply at once

Offline circ : You now can upload all offline files from the Firefox extension.
Once all circ desks have uploaded the file, the librarian can apply all of them, sorted by date.
This avoid the problem of someone issuing an item on desk A, returning it on desk B.
Before this improvement, if desk B uploaded the file before A, the return was applied before the issue,
resulting in the items reamining issued.

Signed-off-by: Sophie Meynieux <sophie.meynieux@biblibre.com>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
12 years agoBug 6919 - Follow up - call to XSLTParse4Display is now made twice in Search.pm
Alex Arnaud [Mon, 27 Feb 2012 10:48:21 +0000 (11:48 +0100)]
Bug 6919 - Follow up - call to XSLTParse4Display is now made twice in Search.pm

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signing off on this one with the following note: You have moved the call to XSLTParse4Display from around line 1775 to around 1842, as compared to the situation before the three 6919 patches. I probably would have left it at its original location, but while examining the code between these two spots, I do not see any real problems with this move. Tested it, works okay. Futher QA comments made on the report itself.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 6919 - Follow-up - Implementing XSLTResultsDisplay
Owen Leonard [Wed, 8 Feb 2012 15:57:01 +0000 (10:57 -0500)]
Bug 6919 - Follow-up - Implementing XSLTResultsDisplay

- Adding search result numbering to match non-XSLT
  results display.
- Copying author handling (with link to author search) from
  OPAC detail XSL.
- Copying physical description output from OPAC detail XSL.
- Copying ISBN output from OPAC detail XSL.
- Removing availability output (which had been copied from
  the OPAC) because it is redundant in the staff client.
- Removing duplicate inclusion of JS highlight plugin on
  results page.
- Updating highlight JS to make it compatible with XSLT
  results.

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
12 years agobug 6919 - implements XSLTResultsDisplay and adding both unimarc and marc21 xslt
Alex Arnaud [Fri, 7 Oct 2011 14:59:52 +0000 (16:59 +0200)]
bug 6919 - implements XSLTResultsDisplay and adding both unimarc and marc21 xslt

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
12 years agoBug 7143 some cleaning
Paul Poulain [Tue, 28 Feb 2012 17:06:30 +0000 (18:06 +0100)]
Bug 7143 some cleaning

* removing useless <strong> everywhere
* updating ENSMP => Mines ParisTech
* lowering cases

12 years agoBug 7143 missing contributors
Paul Poulain [Tue, 28 Feb 2012 17:02:54 +0000 (18:02 +0100)]
Bug 7143 missing contributors

This patch add some contributors that are in docs/history.txt but were forgotten in about.tt

12 years agoBug 7143 about.tt indentation fixes
Paul Poulain [Tue, 28 Feb 2012 17:02:06 +0000 (18:02 +0100)]
Bug 7143 about.tt indentation fixes

This patch is just about s/tab/4spaces/ & indentation fixes

12 years agobug 7143 fixing history, there were 2 #58 and no #59
Paul Poulain [Fri, 27 Jan 2012 09:50:26 +0000 (10:50 +0100)]
bug 7143 fixing history, there were 2 #58 and no #59

12 years agoBug 7582 - When adding a Z39.50 server the "checked" option should use a checkbox
Owen Leonard [Wed, 22 Feb 2012 17:24:54 +0000 (12:24 -0500)]
Bug 7582 - When adding a Z39.50 server the "checked" option should use a checkbox

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7579 - Icons for authorized values/item types not showing in OPAC
Kyle M Hall [Wed, 22 Feb 2012 15:08:24 +0000 (10:08 -0500)]
Bug 7579 - Icons for authorized values/item types not showing in OPAC

The functions getitemtypeimagedir and getitemtypeimagesrc
in Koha.pm were using the system preference 'template'
when they should be using 'opacthemes' instead.

Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7575 Opac search results print alignment
Chris Hall [Wed, 22 Feb 2012 03:47:47 +0000 (16:47 +1300)]
Bug 7575 Opac search results print alignment

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7544 - Add ability search borrowers only on email / phone
Kyle M Hall [Wed, 15 Feb 2012 15:44:20 +0000 (10:44 -0500)]
Bug 7544 - Add ability search borrowers only on email / phone

This commit adds a new pulldown field to the patron quick search.
This pulldown "Search Fields" can have any number of field combinations
to search on. The combinations added in this commit are:

Standard: Default, searches on original fields
Email: Searches on email, emailpro, and B_email
Borrower Number: Searches on borrowernumber
Phone Number: Searches on phone, phonepro, B_phone, altcontactphone, and mobile

Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Tested by running searches on all the new fields, and the old fields
with limits on branch and category. The seach on phone number could be
a bit more inclusive, but it works with and without symbols so I
give my sign off on this patch.

Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Documentation should note that phone numbers should be searched only on the
numbers of a phone number, and separate the area code and exchange with spaces,
regardless of how the number is entered in the database.

So no dashes or parentheses in the phone search, and the last 7 search works with spaces, i.e. xxx xxxx.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7523: Improve checks for routing permissions
Katrin Fischer [Sun, 19 Feb 2012 08:37:14 +0000 (09:37 +0100)]
Bug 7523: Improve checks for routing permissions

- system preference RoutingSerials and user permission routing
  should be taken into account
- print routing list should be independent from routing permission

To test, compare to master and check:

1) If system preference RoutingSerials is OFF, routing list functionality is
not visible in the templates.

2) If system preference RoutingSerials is ON, but user doesn't have routing
permission, routing list functionality is not visible in templates,
with exception of 'print list' on the serial collection page.

3) If system preference RoutingSerials is ON and user has routing permissions,
all routing links are visible (serial collection, serials navigation,
result list of serial search)

Additional changes:
Changed labels on templates to match HTML4 rule from coding guidelines.
http://wiki.koha-community.org/wiki/Coding_Guidelines#Upper_and_Lower_cases_in_strings

Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7318: Fixes category display in patroncards Patron Search results.
Garry Collum [Sat, 21 Jan 2012 18:37:19 +0000 (13:37 -0500)]
Bug 7318: Fixes category display in patroncards Patron Search results.

Category description and type were not being sent to the template.  This patch fixes that issue, which also fixes the display.  The display was showing 'Category Description (category type)'.  It now displays 'Category Description (category code) to be consistent with the search label.

This patch also assigns an empty string to $member to get rid of some 'uninitialized' errors in the logs.

Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Confirm this patch fixes the display issue.
Passes prove xt

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 6039 follow-up, DBrev number
Paul Poulain [Mon, 27 Feb 2012 15:17:42 +0000 (16:17 +0100)]
Bug 6039 follow-up, DBrev number

12 years agobug 6039: Cancel All waiting holds button - Addendum: Add redirect to refresh list...
Kyle M Hall [Mon, 20 Feb 2012 17:20:19 +0000 (12:20 -0500)]
bug 6039: Cancel All waiting holds button - Addendum: Add redirect to refresh list after canceling all holds.

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agobug 6039: Cancel All waiting holds button
Srdjan Jankovic [Fri, 10 Feb 2012 01:02:03 +0000 (14:02 +1300)]
bug 6039: Cancel All waiting holds button

TransferWhenCancelAllWaitingHolds syspref

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
12 years agoBug 6008 - Locating mysql/psql commands on Installer.pm
Salvador Zaragoza Rubio [Wed, 30 Mar 2011 15:40:43 +0000 (17:40 +0200)]
Bug 6008 - Locating mysql/psql commands on Installer.pm

In Installer.pm when is looking for the system command to dump a file into the database
it might fail if the web user doesn't have it in its path. So we add before a search with
"which" and "whereis" commands, if they fail the command is itself without path.

E.g.: with OpenBSD 4.8 the web user "www" doesn't have the path to the installed mysql bin:
/usr/local/bin/mysql and fails in the web installer.

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Seems to work fine, has a good default for if it fails to find that
path

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
tested on my linux box, no visible change, worked before, work after. Will hopefully improve behaviour for OpenBSD

12 years agoBug 3901: Rollover on serials summary showing 9999999
Katrin Fischer [Sun, 19 Feb 2012 14:36:02 +0000 (15:36 +0100)]
Bug 3901: Rollover on serials summary showing 9999999

For Rollover 9999999 the planning tab on the subscription will now show 'Never'.

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agobug_7467: Printing Transfer Slips for transfers that do not have holds - Addendum...
Kyle M Hall [Mon, 20 Feb 2012 14:48:05 +0000 (09:48 -0500)]
bug_7467: Printing Transfer Slips for transfers that do not have holds - Addendum: Use for automatic transfers as well.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agobug_7467: Printing Transfer Slips for transfers that do not have holds
Srdjan Jankovic [Wed, 25 Jan 2012 05:58:58 +0000 (18:58 +1300)]
bug_7467: Printing Transfer Slips for transfers that do not have holds

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
12 years agoMerge remote-tracking branch 'origin/new/bug_3215'
Paul Poulain [Mon, 27 Feb 2012 11:12:59 +0000 (12:12 +0100)]
Merge remote-tracking branch 'origin/new/bug_3215'

12 years agoBug 3215 [REBASED] It would be nice if "Add to Cart" changed to "Remove from Cart"
Owen Leonard [Fri, 20 Jan 2012 20:28:09 +0000 (15:28 -0500)]
Bug 3215 [REBASED] It would be nice if "Add to Cart" changed to "Remove from Cart"

"Add to Cart" links in the OPAC should reflect whether a title
is already in the Cart. On the results, list, and detail pages
the "Add to Cart" link will say "In your cart (remove)" if the
title is in your cart. The "(remove)" link will remove the title.

This patch adds a check of the biblionumbers in the cart to the
relevant scripts and sets a variable for the template governing
whether to show "Add to cart" or "In your cart."

Pages to test:

  - the search results page
  - any detail page (normal, MARC, ISBD)
  - any list contents page (/cgi-bin/koha/opac-shelves.pl?viewshelf=XX)

Situations to test:

- Add a single item to the Cart from the above pages

The link should change from "Add to cart" to "In your cart (remove)"
The count of items in your cart should reflect the addition, and the
notification box should appear.

- Remove a single item from the Cart from the above pages

The link should change from "In your cart (remove)" to "Add to cart."
The count of items in your cart should reflect the removal, and the
notification box should appear.

- View an item which is already in the cart from the above pages

The cart links should reflect whether the title is already in the cart.

- Remove one or more items from the Cart via the cart pop-up window

View the above pages as you do so to verify that the operation is
reflected immediately by the state of the "in your cart" links.

- Empty the Cart from the cart pop-up window

View the above pages as you do so to verify that the operation is
reflected immediately by the state of the "in your cart" links.

Tested in Firefox 9, Chrome 16, IE 7, and Opera 11.6 on Win 7

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7576: Add ISSN to SearchForTitleIn preference
Katrin Fischer [Thu, 23 Feb 2012 07:21:10 +0000 (08:21 +0100)]
Bug 7576: Add ISSN to SearchForTitleIn preference

Adds a new placeholder {ISSN} to the system preference SearchForTitleIn.
For a record with multiple ISSNs only the first ISSN will be used.

Addition: Makes a small change to GetMarcControlnumber so that it checks for
NORMARC too. If you set your system preference to NORMARC, it should output
{CONTROLNUMBER} correctly now.

For testing add following code to the system preference and check output
of SearchForTitleIn for different records in your OPAC and all 3 available
views (normal, MARC and ISBD):
<li>ISSN: {ISSN}</li>
<li>ISBN: {ISBN}</li>
<li>001: {CONTROLNUMBER}</li>

Patch also includes some unit tests:
perl t/db_dependent/Biblio.t

Signed-off-by: Magnus Enger <magnus@enger.priv.no>
Tested with marcflavour = NORMARC, on one book and one periodical record.

* Book

- Before the patch:
ISSN: {ISSN}
ISBN: 0375726446
001:

- After the patch:
ISSN:
ISBN: 0375726446
001: 022976914

* Journal

- Before the patch:
ISSN: {ISSN}
ISBN:
001:

- After the patch:
ISSN: 1890-6931
ISBN:
001: 080721370

Looks good in all 3 views! Thanks for fixing the 001 thing for NORMARC!

Also tested with marcflavour = MARC21, on the same records with the same good
results. Signing off!

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Tested marcflavour= UNIMARC, works fine too

12 years agoBug 7585 - Correct MARC 008 Value Builder Char 06 Default
Chris Nighswonger [Thu, 23 Feb 2012 15:25:13 +0000 (10:25 -0500)]
Bug 7585 - Correct MARC 008 Value Builder Char 06 Default

This patch changes the default value of the 06 char in 008
from 't' to 'b.' This change allows for a valid 008 field
if no dates are entered in 07-14.

To test:

1. Create a new MARC record (prior to patch application).
2. Click on the 008 field to auto-populate.
3. Note that the 06 char is 't'.
4. Apply patch.
5. Create a new MARC record.
6. Click on the 008 field to auto-populate.
7. Note that the 06 char is now 'b'.

Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Confirm fix works per test plan.

12 years agoMerge remote-tracking branch 'origin/new/bug_7453'
Paul Poulain [Mon, 27 Feb 2012 10:35:12 +0000 (11:35 +0100)]
Merge remote-tracking branch 'origin/new/bug_7453'

12 years ago7453 Followup for borrower without expiry date
Marcel de Rooy [Thu, 23 Feb 2012 08:46:32 +0000 (09:46 +0100)]
7453 Followup for borrower without expiry date

While it should be impossible now to have a patron without expiry date, I still had one. It does not hurt to add a simple check on expiry date defined before calling delta days on null values and breaking the opac login.
Trivial change.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Tested by deleting the expirydate from my own patron record.
Missing expiry date now no longer breaks the summary page
in the patron account on OPAC.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7110 - Renewal messages still displays in OPAC if OpacRenewalAllowed is disabled.
Liz Rea [Fri, 17 Feb 2012 13:56:26 +0000 (08:56 -0500)]
Bug 7110 - Renewal messages still displays in OPAC if OpacRenewalAllowed is disabled.

To test:
Set a patron with fines over the stated limit in OPACFineNoRenewals.

With OpacRenewalAllowed set to ALLOW
- log into the OPAC and verify the message that renewals are disallowed is displayed
- verify that renewals are disallowed in the interface.
- remove or pay the fines, verify the message goes away and that OPAC renewals are re-allowed for your patron.

With OPACFineNoRenewals set to Don't Allow
- verify the message is not shown, even with the patron's fines over the threshold in OPACFineNoRenewals.
- remove or pay the fines, verify that renewals are still disallowed

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Stepped through the test plan and found no problems.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7558: Serial issue note doubled up in full history
Katrin Fischer [Sun, 19 Feb 2012 17:01:04 +0000 (18:01 +0100)]
Bug 7558: Serial issue note doubled up in full history

Removes the note behind the status, because there is a separate column.

To test:
- Add a subscription
- Receive an issue, add a note for it
- Search record in OPAC and check the full history tab for the note

Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7559: Edit links for patron attributes and message preferences broken
Katrin Fischer [Sun, 19 Feb 2012 16:48:49 +0000 (17:48 +0100)]
Bug 7559: Edit links for patron attributes and message preferences broken

Edit links below sections for patron attributes and enhanced messaging
preferences are broken and the page is empty except for the heading.

To test:
1) Verify all edit links on the page lead to the correct sections of the patron
empty record.
2) Verify the edit link from the toolbar still works correctly.

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
This fixes a bug caused by bug 6190 (removal of unwanted fields)

12 years agoBug 3916 [follow-up] : Adding a default choice in every dropdown list, not only branc...
Sophie Meynieux [Tue, 14 Feb 2012 13:38:25 +0000 (14:38 +0100)]
Bug 3916 [follow-up] : Adding a default choice in every dropdown list, not only branches, to let the corresponding value unchanged

Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Patch works as advertised

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 6895 Diacritics in Pootle/po files are broken in source text
Frédéric Demians [Fri, 24 Feb 2012 12:04:05 +0000 (13:04 +0100)]
Bug 6895 Diacritics in Pootle/po files are broken in source text

To test:

  git checkout 3.6.x
  cd misc/translator
  ./tmpl_process3.pl update -i ../../koha-tmpl/opac-tmpl/prog/en/ \
    -s ./po/fr-FR-i-opac-t-prog-v-3006000.po -r

  po/fr-FR-i-opac-t-prog-v-3006000.po contains broken diacritics for NORMARC
  strings for example

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
fixes regression caused by bug 6752

12 years agoBug 7606: Editing a vendor in acq creates a new vendor
Katrin Fischer [Sun, 26 Feb 2012 14:14:27 +0000 (15:14 +0100)]
Bug 7606: Editing a vendor in acq creates a new vendor

To test:

Before patch:
- editing a new vendor will create a new vendor

After patch:
- editing a vendor saves changes correctly, no new vendor is created

Also:
- after saving or cancelling an edit page redirects correctly
- adding new vendors works correctly

Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Followed test plan and all tests pass.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
This is a follow-up for 7113

12 years agoBug 6875 follow-up for Items/Biblio de-nesting
Paul Poulain [Wed, 22 Feb 2012 15:58:36 +0000 (16:58 +0100)]
Bug 6875 follow-up for Items/Biblio de-nesting

the sub _find_value is used only in PrepareItemRecord sub, that has been moved to Items package

This patch moves the _find_value in Items as well.

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Editing an already arrived serial issue with an attached item
resulted in an error. After applying the patch it's fixed.

12 years agoMerge remote-tracking branch 'origin/new/bug_7460'
Paul Poulain [Wed, 22 Feb 2012 14:27:00 +0000 (15:27 +0100)]
Merge remote-tracking branch 'origin/new/bug_7460'

12 years agoBug 7460: followup : Add template toolkit's FILTER html_line_break on staff details...
Stéphane Delaune [Thu, 9 Feb 2012 10:01:33 +0000 (11:01 +0100)]
Bug 7460: followup : Add template toolkit's FILTER html_line_break on staff details description's tab

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
12 years agoBug 7552 - Remove wrong line endings in NORMARC record.abs
Magnus Enger [Fri, 17 Feb 2012 14:03:52 +0000 (15:03 +0100)]
Bug 7552 - Remove wrong line endings in NORMARC record.abs

Line endings contain erroneous \r 's.

Also remove a useless comment at the top of the file.

This patch was produced by doing the following operations:

git config --global core.autocrlf true
git rm --cached -r etc/zebradb/marc_defs/normarc/biblios/record.abs
git diff --cached --name-only -z | xargs -0 git add

as recommended here:
http://help.github.com/line-endings/

First version of this file resulted in whitespaceerrors. Trying to fix that now.

To test:

- Open etc/zebradb/marc_defs/normarc/biblios/record.abs in a file editor
  that will let you search for \r - gedit seems to work nicely for this.
  Check that there are occurences of \r in the file
- Apply the patch
- Open etc/zebradb/marc_defs/normarc/biblios/record.abs in the editor and
  check that it can not find any \r

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Still a few \r

But only on comments, safe to push

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7454 Initialize return arrays in ILS/Transaction/RenewAll
Colin Campbell [Tue, 17 Jan 2012 14:46:09 +0000 (14:46 +0000)]
Bug 7454 Initialize return arrays in ILS/Transaction/RenewAll

Explicitly clear these arrays and update them directly.
In practice item numbers were already in them when called
so that more items were being returned than were actually
renewed (or failed)

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Functionally sound patch, and tested in production

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 5373 - allow 'cardnumber' to appear on the patron import field list
Robin Sheat [Thu, 24 Nov 2011 00:35:27 +0000 (13:35 +1300)]
Bug 5373 - allow 'cardnumber' to appear on the patron import field list

For some reason, it was explicitly removed, however you need it if you
want to match up on cardnumber.

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Easy to test and works nicely.
Before patch cardnumber is not shown in the list of fields on the
patron import page. After applying the patch it is.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7513 Marc Import Hangs
BibLibre [Thu, 9 Feb 2012 09:11:36 +0000 (10:11 +0100)]
Bug 7513 Marc Import Hangs

On some record, the commit_biblio_file is creating wide
character
because as_xml is not used with correct parameter.
This patch fixes that.
To test on a UNIMARC Koha, stage attachment 7510 and
then import.
It hangs before the patch, it passes after.

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7496 - Personally identifying information sent in opac user TITLE
Owen Leonard [Fri, 17 Feb 2012 15:52:31 +0000 (10:52 -0500)]
Bug 7496 - Personally identifying information sent in opac user TITLE

Removing patron name from OPAC page <title> tags. Making
some other minor changes to improve <title> clarity and consistency.

Signed-off-by: Liz Rea <wizzyrea@gmail.com>
titles appear to be consistent
passes prove xt

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7535: ampersands not showing properly in non-XSLT OPAC
D Ruth Bavousett [Mon, 13 Feb 2012 15:25:40 +0000 (10:25 -0500)]
Bug 7535: ampersands not showing properly in non-XSLT OPAC

Jared's fix for Bug 3326 fixed this in the staff client, but not the OPAC; moving this one line fixes it
both places.

Signed-off-by: Liz Rea <wizzyrea@gmail.com>
This can be replicated by indexing with -x
OPACXSLTResults must be set to "normally"
Reproduced original bug with rebuild-zebra.pl -x -b -w -r -v -v
Patch corrects the issue, does not change intranet behavior.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 6193 follow-up of the follow-up = reindentation only
Paul Poulain [Tue, 21 Feb 2012 12:16:11 +0000 (13:16 +0100)]
Bug 6193 follow-up of the follow-up = reindentation only

12 years agoBug 6193 - Follow up: use SetEnv and remove memcached from koha-conf.xml
Tomas Cohen Arazi [Fri, 30 Dec 2011 12:10:36 +0000 (09:10 -0300)]
Bug 6193 - Follow up: use SetEnv and remove memcached from koha-conf.xml

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Confirmed that memcached is still being used after the memcached configuration
in koha-conf.xml was removed, and the following two lines were added to
both virtual hosts in koha-httpd.conf:
SetEnv MEMCACHED_SERVERS "127.0.0.1:11211"
SetEnv MEMCACHED_NAMESPACE "KOHA"

12 years agobug_7231: Call GetMarcPrice() in acqui/neworderempty.pl for staged imports
Srdjan Jankovic [Fri, 27 Jan 2012 02:19:25 +0000 (15:19 +1300)]
bug_7231: Call GetMarcPrice() in acqui/neworderempty.pl for staged imports

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
12 years agoMerge remote-tracking branch 'origin/new/bug_6875'
Paul Poulain [Mon, 20 Feb 2012 15:45:42 +0000 (16:45 +0100)]
Merge remote-tracking branch 'origin/new/bug_6875'

12 years agoBug 6875 de-nesting C4::Items
Paul Poulain [Fri, 16 Sep 2011 18:20:37 +0000 (20:20 +0200)]
Bug 6875 de-nesting C4::Items

C4::Branch is used only in CheckItemPresave, moving from a use to a require in the sub
C4::Reserve:
    This package is loaded just for C4::Reserves::CheckReserves called in C4::Items::GetItemsInfo
    The GetItemsInfo stores the result of CheckReserves in a hash entry, count_reserve, that is used only in opac_detail to display the status of a hold. We could remove the reserve_count hash entry and inline C4::Reserves::CheckReserves directly from opac-detail.pl page
    in opac-detail.pl, instead of
    if( $itm->{'count_reserves'} eq "Waiting"){ $itm->{'waiting'} = 1; }
    write :
    if ( C4::Reserves::CheckReserves(<<parameters>>) eq "Waiting"){ $itm->{'waiting'} = 1; }
C4::Acquisition is used only in MoveItemFromBiblio, a sub that is rarely called. Moving from a use to a require in the sub
C4::Charset is used only in _parse_unlinked_item_subfields_from_xml. Moving from a use to require in the sub

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Checked opac-detail and cataloging. Code looks good.

12 years agoBug 6875 de nesting C4::Biblio
Paul Poulain [Fri, 16 Sep 2011 17:37:15 +0000 (19:37 +0200)]
Bug 6875 de nesting C4::Biblio

C4::Biblio is used in many many places. The goal of this cleaning is to do from C4::Biblio a package with as many dependancies as possible.

* C4::Heading is called only in 1 place, highly rarely used (only in 1 misc/link_bibs_to_authorities.pl), moving to require
* PrepareItemrecordDisplay is a sub that is more related to Items, moving it here. It means some scripts that used this sub must be checked against use C4::Items
* C4::Items is needed in EmbedItemsInMarcBiblio, moving it only in this sub, and switching to require
* 2 subs are totally useless z3950_extended_services and set_service_options, removing them

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
No test plan included, but tested some opac and cataloging functions.
Code looks good. Marked as Passed QA.

12 years agoBug 7554: Clean newlines in browse script
Jared Camins-Esakov [Fri, 17 Feb 2012 17:50:47 +0000 (12:50 -0500)]
Bug 7554: Clean newlines in browse script

Records with a newline in the title will break the Javascript search pagination
on the OPAC without this patch.

To test:
1. Import a record with a newline in the title (an example is attached to this
   bug)
2. Do a search that turns up the record and at least one other
3. View the detail page for one of the other records
4. Observe that there is a javascript error
5. Apply patch
6. Repeat search
7. Observe that there is no javascript error

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Simple template change, works well

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoMerge remote-tracking branch 'origin/new/bug_6488'
Paul Poulain [Mon, 20 Feb 2012 15:28:14 +0000 (16:28 +0100)]
Merge remote-tracking branch 'origin/new/bug_6488'

12 years agoBug 6488 - followup - fixes issue with bibs with no items and serials being suppressed
Liz Rea [Fri, 17 Feb 2012 20:00:53 +0000 (14:00 -0600)]
Bug 6488 - followup - fixes issue with bibs with no items and serials being suppressed

To test:

* create a bib with no items
* update your index
serial records and your new bib with no items should be displayed.
* add something to the OPACHiddenItems syspref (I like itype: [BK] from the test data)
*** test both ways, with something in there and with the syspref empty.
* add an item to your new bib that would be suppressed
* update your index
* search for the bib
The item should not show
* change the item into a state where it would no longer be suppressed
* update your index
* search for the bib
The item should show in the opac
* just for fun, delete your item
* update your index
* Search for the bib - it should still display.

I tested on MARC21 - please test UNIMARC as well.

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
12 years agoBug 4054 - Double-clicking the 'place hold' button can result in duplicate holds...
Kyle M Hall [Tue, 14 Feb 2012 18:49:54 +0000 (13:49 -0500)]
Bug 4054 - Double-clicking the 'place hold' button can result in duplicate holds - Part 2: OPAC

This commit adds a new jquery function to functions.js, preventDoubleFormSubmit().
When used thusly: $('#form-id').preventDoubleFormSubmit();
It will prevent a submitted form from being submitted a second time.
This commit uses said function to prevent double processing a hold
request from the opac.

Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Rapid clicking on the place hold button no longer causes duplicate holds!
Passes prove t xt t/db_dependent in line with current master.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 4054 - Double-clicking the 'place hold' button can result in duplicate holds
Kyle M Hall [Tue, 14 Feb 2012 15:53:19 +0000 (10:53 -0500)]
Bug 4054 - Double-clicking the 'place hold' button can result in duplicate holds

This commit adds a new jquery function to staff-global.js, preventDoubleFormSubmit().
When used thusly: $('#form-id').preventDoubleFormSubmit();
It will prevent a submitted form from being submitted a second time.
It is currently only added to the Place Hold form in reserve/request.pl

http://bugs.koha-community.org/show_bug.cgi?id=4045
Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Tested:
Double clicking no longer causes identical double holds to be placed.
passes prove t xt t/db_dependent in line with current master.

Reminder: this will need to be added to the OPAC as well.

12 years agoBug 7133: Late orders don't allow to select more than one order
Katrin Fischer [Fri, 27 Jan 2012 07:29:46 +0000 (08:29 +0100)]
Bug 7133: Late orders don't allow to select more than one order

To test:

Fix selection of orders from vendors
1) Make sure you have at least 2 late orders each for 2 different vendors
2) Filter list to show only late orders of one vendor
3) Use Check all/Uncheck all
4) Select more than 1 order manually
5) Remove filter on vendor, show all late orders
6) When checking an order from one vendor, checkboxes for other vendors get blocked
7) Check you can select all late orders for one vendor

Display fix: show vendor id in first column instead of ()
1) Veryfy first column of table looks something like: (2) 19/01/2012 (8 days) and has no empty ()

http://bugs.koha-community.org/show_bug.cgi?id=7113
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7113: Fix 'Edit vendor' link on basketgroup page
Katrin Fischer [Fri, 27 Jan 2012 07:16:55 +0000 (08:16 +0100)]
Bug 7113: Fix 'Edit vendor' link on basketgroup page

'Edit vendor' didn't open the vendor page for editing.

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
12 years agoBug 7113: Standardize vendor id name in templates and scripts
Owen Leonard [Fri, 28 Oct 2011 18:43:43 +0000 (14:43 -0400)]
Bug 7113: Standardize vendor id name in templates and scripts

New revision updates for current master and cleans up new
instances introduced by recent commits.

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
2 problems found, fixing those in follo up patches:
- late orders don't allow more than 1 order to be selected
- basketgroups: 'Edit vendor' does the same as 'Manage orders'

12 years agoBug 6496 - correct the order of the author display in the OPAC
Robin Sheat [Thu, 2 Feb 2012 05:21:44 +0000 (18:21 +1300)]
Bug 6496 - correct the order of the author display in the OPAC

This sets the order the fields are displayed in to be as it is in the
MARC (typically numerical order), rather than 100,700,110,710,... like
it was.

Basically, it's a port of the way it's done in the staff client. As
such, it should be able to handle a lot more than it could previously,
including relator codes.

(replaces the previous commit, just removing an erronious comment and
making the commit message more accurate)

Conflicts:

koha-tmpl/opac-tmpl/prog/en/xslt/MARC21slim2OPACDetail.xsl

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 6496 - tidy the display of 710 fields on XSLT
Robin Sheat [Wed, 31 Aug 2011 07:59:44 +0000 (19:59 +1200)]
Bug 6496 - tidy the display of 710 fields on XSLT

This puts '--' between 710$b fields, and replaces the '.' with a '; ' if
there are additional authors.

Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
12 years agoBug 6137 follow-up, moving new test to db_dependent directory
Paul Poulain [Fri, 17 Feb 2012 17:40:33 +0000 (18:40 +0100)]
Bug 6137 follow-up, moving new test to db_dependent directory

12 years agoBug 6137: unit tests for C4::Circulation::_GetCircControlBranch
Julian Maurice [Fri, 27 Jan 2012 14:59:36 +0000 (15:59 +0100)]
Bug 6137: unit tests for C4::Circulation::_GetCircControlBranch

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 6137: fix a Circulation bug. userenv null
biblibre [Tue, 8 Mar 2011 09:28:38 +0000 (10:28 +0100)]
Bug 6137: fix a Circulation bug. userenv null

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
12 years agoBug 7540 - add id values to the legends in the patron entry form
Robin Sheat [Tue, 14 Feb 2012 23:34:30 +0000 (12:34 +1300)]
Bug 7540 - add id values to the legends in the patron entry form

This adds the following IDs to the legends in the patron entry form:
 main_address_lgd contact_lgd alt_address_lgd alt_contact_lgd
 library_management_lgd library_setup_lgd opac_staff_login_lgd
 patron_messaging_prefs_lgd

With these in place, then jquery like:
$(document).ready(function(){
        $('#main_address_lgd').text('Postal Address');
        $('#alt_address_lgd').text('Residential Address');
});
in intranetuserjs can be used to rename things to taste.

Signed-off-by: Liz Rea <wizzyrea@gmail.com>
I see the id's in there, they appear consistent and complete.

12 years agoBug 7532 - remove dependency on Date::ICal
Robin Sheat [Sun, 12 Feb 2012 03:36:34 +0000 (16:36 +1300)]
Bug 7532 - remove dependency on Date::ICal

This removes the dependency on Date::ICal (which is largely
unmaintained) and replaces it with DateTime::Format::ICal which can do
the same job. It also updates all the docs and installation scripts to
handle this change.

Note that this causes a minor behaviour change: previously the generated
times were converted to UTC, now they are left "floating" (that is, have
no timezone attached) and so will appear as the local time when imported
into a calendar. I don't anticipate this'll cause any issues however.

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
12 years agoBug 7514 Choose OPAC language with URL parameter
Frédéric Demians [Thu, 9 Feb 2012 10:03:34 +0000 (11:03 +0100)]
Bug 7514 Choose OPAC language with URL parameter

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Tested:
- with and without cookie set
- different language codes

http://.../cgi-bin/koha/opac-changelanguage.pl?language=de-DE
will directly open the German OPAC.

http://.../cgi-bin/koha/opac-changelanguage.pl?language=en
will directly open the English OPAC.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agobug 7509 follow-up, DBRev number
Paul Poulain [Fri, 17 Feb 2012 10:35:06 +0000 (11:35 +0100)]
bug 7509 follow-up, DBRev number

12 years agoBug 7509: Added index on items itemcallnumber
Ian Walls [Wed, 8 Feb 2012 02:23:39 +0000 (15:23 +1300)]
Bug 7509: Added index on items itemcallnumber

Comment from Liz:
I couldn't get this update to fire - I found a small syntax error in the
updatedatabase.pl for this, which I corrected with this patch.

Functionally, all of this works as tested (once the typos were fixed), but
this probably requires another sign-off.

QA notes: rebased on latest master.  Also added index name `itemcallnumber`
to maintain consistency with all other indexes on items table.

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Ian Walls <koha.sekjal@gmail.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agobug_7458: A call number plugin
Srdjan Jankovic [Wed, 8 Feb 2012 02:12:05 +0000 (15:12 +1300)]
bug_7458: A call number plugin

Signed-off-by: Melia Meggs <melia@test.bywatersolutions.com>
A library using an inhouse callnumbering system wants to be able to generate the next available call number not already in use.  This custom call number plugin returns the next callnumber not already in use once a correct prefix has been entered.  The prefixes are four to six letters, space, then one or two numbers.

12 years agoBug 7409 - add unzip and perl-doc dependencies to package
Robin Sheat [Fri, 10 Feb 2012 03:10:28 +0000 (16:10 +1300)]
Bug 7409 - add unzip and perl-doc dependencies to package

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7312: Adds ISSN to serials/subscription-bib-search.pl results
Matthias Meusburger [Thu, 12 May 2011 09:29:01 +0000 (11:29 +0200)]
Bug 7312: Adds ISSN to serials/subscription-bib-search.pl results

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7289: Add biblioitems.editionstatement to missing sql files
Katrin Fischer [Sun, 12 Feb 2012 18:27:57 +0000 (19:27 +0100)]
Bug 7289: Add biblioitems.editionstatement to missing sql files

Follow-up for 7289 adding the new mapping to translated frameworks.

http://bugs.koha-community.org/show_bug.cgi?id=7280

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
12 years agoBug 7289 follow-up setting DBrev number
Paul Poulain [Fri, 17 Feb 2012 10:14:21 +0000 (11:14 +0100)]
Bug 7289 follow-up setting DBrev number

12 years agoBug 7289: Adds editionstatement field in neworderempty
Jonathan Druart [Wed, 18 Jan 2012 10:26:53 +0000 (11:26 +0100)]
Bug 7289: Adds editionstatement field in neworderempty

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

Database update
- existing mapping
- no pre existing mapping

Frameworks
PROBLEM: some languages are still missing, I think only untranslated
frameworks are included in this patch.

Acquisition
- created a new order with edition filled out
- checked edition was saved to the correct field in cataloguing
- modified edition and checked display in acquisition
- edition also displays on basket summary page

http://bugs.koha-community.org/show_bug.cgi?id=7280

12 years agoBug 7246 add offset/length and where options to rebuild_zebra
Paul Poulain [Wed, 1 Feb 2012 14:15:02 +0000 (15:15 +0100)]
Bug 7246 add offset/length and where options to rebuild_zebra

This patch reimplement a feature that is on biblibre/master for Koha-community/master

It adds 4 parameters:
* offset = the offset of record. Say 1000 to start rebuilding at the 1000th record of your database
* length = how many records to export. Say 400 to export only 400 records
* where = add a where clause to rebuild only a given itemtype, or anything you want to filter on

Another improvement resulting from offset & length limit is the rebuild_zebra_sliced.zsh
that will be submitted in another patch.
rebuild_zebra_sliced will slice your all database in small chunks, and, if something went wrong for a given slice, will slice the slice, and repeat, until you reach a slice size of 1, showing which record is wrong in your database.

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Removed mention of -l option for limiting number of items exported, as requested
by QA manager. This can be re-added in a later patch.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 7201 follow-up, fixing some indentation mistakes
Paul Poulain [Fri, 17 Feb 2012 09:58:01 +0000 (10:58 +0100)]
Bug 7201 follow-up, fixing some indentation mistakes

12 years agobug_7201: Holds reports: add copynumber and enumchron
Srdjan Jankovic [Thu, 9 Feb 2012 00:24:35 +0000 (13:24 +1300)]
bug_7201: Holds reports: add copynumber and enumchron

Signed-off-by: Liz Rea <wizzyrea@gmail.com>
Data is there and correct - very helpful patch, thanks!
passes prove t xt t/db_dependent in line with current master failures.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 6985 - remove kw,wrdl from the search results
Liz Rea [Wed, 25 Jan 2012 20:41:03 +0000 (14:41 -0600)]
Bug 6985 - remove kw,wrdl from the search results

To test:

* Apply patch
* Do a search in the OPAC, the result page should now say
  "Your search returned X results" instead of
  "Your search for "kw,wrdl:yyy" returned x results"
* Do a search that will have no results, kw,wrdl should not appear in the text.

Signed-off-by: Jared Camins-Esakov <jcamins@cpbibliography.com>
Signed-off-by: Adrien Saurat <adrien.saurat@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 5346: Small display changes
Katrin Fischer [Mon, 23 Jan 2012 06:43:11 +0000 (07:43 +0100)]
Bug 5346: Small display changes

Changing display from:
Suggested by Admin, Koha (from suggestion #2)

To:
Suggested by: Admin, Koha (suggestion #2)

Adding some missing parentheses and deleting some additional spaces.

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
12 years agoBug 5346: Linking suggestions and orders.
Jonathan Druart [Wed, 18 Jan 2012 13:16:16 +0000 (14:16 +0100)]
Bug 5346: Linking suggestions and orders.

Display suggestion info in acquisition module:
  basket.pl
  neworderempty.pl
  orderreceive.pl
  parcel.pl

To Test:
Create a suggestion and accept it.
Create a new order from this suggestion
Receive this order

For each step, check if suggestion info are visible.

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Test provides more unit tests, all complete successfully.
perl t/db_dependent/Suggestions.t
Note: test case should be cleaned up after running tests.

Display changes are consistent and information about the suggestion
is shown on every important screen now.

I created an order from a suggestion and one from an existing record.

No problems found.