Commit Graph

9321 Commits

Author SHA1 Message Date
Henri-Damien LAURENT cd66ffcbc3 Reverting from MARC::File::XML parser forcing 2009-01-27 12:19:49 +01:00
Nahuel ANGELINETTI 4b022f2bda Authtypecode return an warning even if subfield is ignored
this patch just add a condition to the sql request to return a warning
only if authtypecode is not in an ignored subfield.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:49 +01:00
Frederic Demians a52ef2cd44 Bugfix #2921 OPACAmazonContent syspref not used
In opac-results.tmpl and opac-detail.tmpl, AmazonContent is used
rather than OPACAmazonContent to enable/disable Amazon book jacket.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:49 +01:00
Joe Atzberger e01039f94d Minor rework of template js.
Lines explicitly ended with semicolons.  Allow some better behavior if TMPL_VAR's
are undefined or zero.

Note FIXME added.  I believe this is part of the fragmentary integration of
Katipo code for GST.  Would be obliged if someone with access there can confirm.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:48 +01:00
Joe Atzberger b4beb0b84c Trivial comment typos corrected.
Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:48 +01:00
Joe Atzberger 351d67dd07 Basic cleanup of fixup_cardnumber
Avoid warning on syspref "checkdigit" undefined.
Functionality essentially unchanged.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:48 +01:00
Joe Atzberger 0af920167e Prevent js failure if syspref "gist" is undefined.
The javascript is malformed and therefore fails the onsubmit check if
gist does not receive a value.  This patch allows failover to default 0.
Also removed an unused dbh.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:48 +01:00
Joe Atzberger 4a55018ff6 Block warning on detail.pl.
If Amazon doesn't have an avg. rating number defined, then we cannot multiply it
by 20 without the following warning:

    detail.pl: Use of uninitialized value in multiplication (*)
    at /home/user/kohaclone/catalogue/detail.pl line 228.

So the important part of this patch is || 0 on the $average_rating assignment.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:48 +01:00
Nahuel ANGELINETTI 3cf3a2e1bd (bug #2917) editing authority marc field structure doesn't workl
This patch add a field in the ->execute() statement which was missing.
The sql request have 8 args, and only 7 was passed.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:47 +01:00
Nahuel ANGELINETTI c835cc1ca7 Autoselect marcflavour in marc import
This patch is writted by Paul Poulain.
It auto-select the marcflavour from syspref in the stage marc import.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:47 +01:00
Joe Atzberger 04c3d85941 Correct capitalization on CGI::Session::Serialize::yaml
Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:47 +01:00
Mason James 43caf28474 Fixes command-line 'number' arg in bulkauthimport.pl.
for HEAD and 3.0.x

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:47 +01:00
Mason James ca9ba8b803 fix to remove blank newlines from labels
Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:47 +01:00
Marc Chantreux 71ae69780d _set_defaults_for_add easier to read
Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:47 +01:00
Marc Chantreux 5a74b4fa0c more readable version of the init and new sub
Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:47 +01:00
Nahuel ANGELINETTI b9b2804fbc (bug #2914) improve the deletion
this patch disable the button to delete all of items if there is no item attached to the marc record.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:47 +01:00
Nahuel ANGELINETTI 021ceccee9 (bug #2914) delete all items of a notice
This patch allow the librarian to delete all items attached to a notice in one click.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:47 +01:00
Nahuel ANGELINETTI b22cda6be7 (bug #2913) show "--" on repeated fields
This patch just transform the script to set the field title as "--" if it was already shown.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:47 +01:00
Nahuel ANGELINETTI e5ac4b52e7 Format marc notes
this patch add a filter to notes, it transform \n in <br />

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:47 +01:00
Owen Leonard 518d521cf0 Correction: Greybox js should be loaded only if XSLTDetailsDisplay is on (not only if GoogleJackets is on).
Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:47 +01:00
Joe Atzberger 79cd91dfe4 Basic reformat of section in Search.pm
In for loops, replace all-inclusive conditional blocks like:
    for (@foo) {
        if (test) {
            block;
        }
    }

with conditional use of "next":
    for (@foo) {
        test or next;
        block;
    }

This reduces the number of unnecessarily nested blocks, and the
overall number of lines.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:46 +01:00
Nahuel ANGELINETTI ea40ff382f (bug #1578) change the shelf COinS support
this change the old COinS support, and now use C4::Biblio::GetCOinSBiblio().

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:46 +01:00
Ryan Higgins 6c1c73cebf Add mc-loc definition for ccl.properties.
Advances search limit by shelving location doesn't work due to
missing ccl definition in default installation.  Once updated,
the zebradb will need to be reindexed.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:46 +01:00
Galen Charlton a6c9b0f666 bug 2505: enable warnings for labels/label-print-pdf.pl
Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:46 +01:00
Nahuel ANGELINETTI ada7677996 (bug #2893) Allow loan forcing if a syspref is set
If the syspref 'AllowNotForLoanForcing'(YESNO) is set to YES, the librarian is able to force a loan on an item set as "not for
loan".
If the item is not for loan and the syspref is set to YES, koha will ask to the librarian if he really want to check-out it,
else do nothing.

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:46 +01:00
Nahuel ANGELINETTI a4fecfbefa (bug #1578) Add the (quasi)full COinS(Zotero) support
this patch do a lot of things :
 * Add the function GetCOinSBiblio in C4::Biblio, return the COinS value that must be put in a span title
   This will be usefull for OpenURL support.

 * Replace the span in opac-detail, and put the var get from GetCOinSBiblio
 * Fix an <img> tag that wasn't autoclosed
 * Add the COinS in search result
 * Full COinS support of UNIMARC, the MARC21 support should be improved to provide all kind of document types

Signed-off-by: Henri-Damien LAURENT <henridamien@koha-fr.org>
2009-01-27 12:19:46 +01:00
Henri-Damien LAURENT bb038e19d9 Updating updatedatabse in order to work in any installs 2009-01-27 12:19:46 +01:00
Nahuel ANGELINETTI e9bc18e850 (bug #2909) fix the attachment base64 encoding
this patch change the attachment encoding, else if the file is too large, koha throws an error.
This solution was found on koha list in a Joshua's e-mail

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:46 +01:00
Nahuel ANGELINETTI fa40bbb57d Unescape some double quotes, that make a validation error.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:45 +01:00
Nahuel ANGELINETTI 30d2cb06f2 (bug #2904) support of 856$u and 856$z in UNIMARC
This patch change the linktext as the label of the link(in 856$z), and set the url from the 856$u.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:45 +01:00
Allen Reinmeyer 9d13713f09 Bug 2902 Public shelves do not display when user not logged in.
An ending </div> was not placed correctly and encompassed both
privateshelves and publicshelves

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:45 +01:00
Henri-Damien LAURENT 3cc561543b Prevent multiple warnings per notice filling cron logs.
If a value being substituted in was NULL, then warnings like this
would be emailed to the crontab owner (or MAILTO):

Use of uninitialized value in substitution (s///) at /home/user/kohaclone/C4/Letters.pm line 508.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>

Conflicts:

	C4/Letters.pm
2009-01-27 12:19:45 +01:00
Galen Charlton 9a618896c5 bug 2505: more warnings fixes in C4/Context.pm
* more portable way to determine uname for
  crash messages
* C4::Context->userenv now returns undef instead
  of 0 if no userenv has been set yet; returning
  undef when necessary is almost always better
  than returning a scalar when a hashref is
  normally expected.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:45 +01:00
stan 6a2a916b75 Enable use warnings;, clean up complainy functions, fix a few tab/space formatting issues.
Refactoring KOHAVERSION to be less crufty, enabling use warnings, change formatting slightly in places.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:45 +01:00
Marc Chantreux b9092dfdc5 WEBSERVER_HOST and WEBSERVER_HOST added
comments added too

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:45 +01:00
Galen Charlton 0ce35bcf21 followup to patch for bug 2900
Previous patch broke date comparison that sets
overdue flag - now that ISO-formatted date
strings are being compared, must use "it"
instead of "<".

"2009-01-02" lt "2009-01-08" is true
"2009-01-02" <  "2009-01-08" is *false*

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:45 +01:00
Joe Atzberger 267fe06f0a Bug 2900: fix GetPendingIssues.
GetPendingIssues did several bad things:
~ select * on a 4 table join,
~ including multiple namespace collisions,
~ including large fields marc and marcxml from biblioitems,
~ return ($count, \@array_being_counted).

Not everything is fixed here (see FIXMEs), but the situation is
improved considerably, with bug 2900 resolved.  The "timestamp"
namespace collision in query should be resolved by separate patch.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:45 +01:00
Galen Charlton c1d3b08049 bug 2747: avoid warning if items.itype is NULL
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:45 +01:00
Joe Atzberger 31277c3dcd Bug 2747 for staff interface itemtype display.
Prefer accuracy over graphical icon.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:44 +01:00
Joe Atzberger e17fa34ac5 GetAuthValCode calls were positioned inside the loop,
despite the same values being supplied each time.  Then
the conditional assignments would repeat the same calls again!
That means execution was liable to query the DB at least once
and as many as four times per item.  With a large number of items
this is an unnecessary burden.  By moving the calls outside
the loop, we can guarantee that we never have to call the DB for
that info more than twice (once for lost, once for damaged).

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:44 +01:00
Michael Hafen 9276e1cdd2 javascript redirect when selecting a patron on circulation.pl Patron Selection Screen
This adds a little javascript to the Patron Selection form input after searching for a patron to check out to.
On click it redirects to checking out to the clicked patron.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:44 +01:00
Michael Hafen 981b682b29 Put patron Privilege 'updatecharges' to use on fines pages
This changes the flags required for the fines pages to include the
updatecharges flag.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:44 +01:00
Nahuel Angelinetti e279c0afe8 a more readable way to test an array size.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:44 +01:00
Galen Charlton b01eca70a0 bug 2505: enable warnings for admin/authorized_values.pl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:44 +01:00
Joe Atzberger 16e39c65f1 authorized_values cleanup
Moving towards being able to enable warnings.  Use one dbh, and stop
redeclaring it in each conditional chunk.  ($sth still need to be cleaned.)
Toggle in script removed (tmpl should use loop context var __odd__).
$sth->finish calls removed where unnecessary.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:44 +01:00
Andrew Moore 0953c661bd REFACTOR: correcting indirect object method syntax
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:44 +01:00
Andrew Moore 074d90f1b9 Bug 2505: turning on "warnings" in catalogue/detail.pl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:44 +01:00
Owen Leonard 12ab7b257b Providing options for adding to order when existing record search has failed.
I've duplicated the "Add to Order" block on the search results page to display after a user has searched for an existing record to add to an order. This block is displayed whether or not results were found on the assumption that a non-empty result set may not contain the desired result. Changes to neworderbiblio.pl allow supplier name to appear in breadcrumb nav.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:44 +01:00
Galen Charlton 6976c2ef99 patch followup: restore test in GetMarcItem
Change made to GetMarcItem to quell a warning
changed sense of a test; defined($foo) is *not*
the same as $foo ne ''.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:44 +01:00
Galen Charlton 4d095e145e bug 2505: more warnings fixes to C4/Biblio.pm
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:43 +01:00