Commit Graph

9293 Commits

Author SHA1 Message Date
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
Owen Leonard 04417c2b73 Fix for Bug 2700, Keeping Data When Adding Multiple Items
When cloning the set of inputs, the new js
increments the IDs of each form field (to keep them unique) and automatically
selects the option that was selected in the cloned group.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:43 +01:00
Andrew Moore f1f78e5475 Bug 2505: adding warnings to C4/Biblio.pm
I added 'use warnings' to C4::Biblio and made a handful of changes to
reduce the number of warnings emitted.

One notable spot is the change in the regex in
C4::Biblio::GetNoZebraIndexes. I have replaced the parens with a character
class. The parens change the way 'split' works, making it return elements
for each delimiter. We did not want those elements returned, and they
only resulted in "'' => undef" being added to the final hash. They also
resulted in two "undefined" warnings for each pass through the loop. I've
included a simple test for this function.

There may be a few warnings still emitted in spots, but either I haven't
seen them yet, or I have chosen to not fix them yet because they require
too much change.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:43 +01:00
Joe Atzberger d7a0dcc55b barcodedecode() did not always return barcode
This patch amends the function to return barcode, in particular when
filter is not defined.  It also adds an optional 2nd argument to
allow the filter to be specified by caller, enabling testing.

Non-DB-dependent test script included.  Note: T-prefix style
barcode filter is not documented, and drops the first nonzero
digit after the T.  This seems mistaken, but is not corrected here
to avoid any surprises.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:42 +01:00
Joe Atzberger (siptest 1503a9099e Allow AddIssue to log SIP transactions distinct from others.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:42 +01:00
Galen Charlton 57f0fc0dce remove TMPL_IF EXPR in member.tmpl
Quells following error message in Apache log:

EXPR:at pos 8: non-initialized variable overdues,
referer: http://example.edu/cgi-bin/koha/members/members-home.pl

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:42 +01:00
Galen Charlton 11160e2169 perltidy lables/label-item-search.pl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:42 +01:00
Galen Charlton 57260f580f bug 2505: turn on warnings in labels/label-item-search.pl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:42 +01:00
Galen Charlton 9d2957bdbe followup to Mason's labels patch
* fix XHTML errors
* fix problems with paging through results list

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:42 +01:00
Mason James 426260de1a The current searching in labels is a bit minimal, and current only does keyword searching.
there is some old 2.2 code for more complete labels-searching, thats been commented out

ive logged a 'bug' for this - 2777

http://bugs.koha.org/cgi-bin/bugzilla/show_bug.cgi?id=2777

this fix...
  - enables the index-searching functionality
  - adds date-ranges
  - uses the numSearchResults syspref, not a hardcoded '20'
  - rewrote old 2.2 page-num code, (didnt work for 3.x)
  - some indent and whitepages tidys.
  - unused 2.2 search-code removed.

Mason

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:42 +01:00
Nahuel ANGELINETTI 632e155c18 (bug #2887) Change the "Cart" box from js to tmpl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:42 +01:00
Joshua Ferraro 60b91f65c9 Adds the ability to reference itemcallnumber within XSLT
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:42 +01:00
Frederic Demians babf36ec9c Fixes bug #2875
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:42 +01:00
Joe Atzberger 3df28a3aa5 Minor updates to minor cronjob script.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:41 +01:00
Galen Charlton b85a642d40 crontab.example - add back some useful comments
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:41 +01:00
Joe Atzberger c086341315 Expand crontab.example
Default overdues to "triggered" mode (-t).

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:41 +01:00
Joe Atzberger c1c0f36704 Revert "Updates to the example crontab"
This reverts commit def09f5a21.

As I emailed to the patches list Oct 06, 2008:

I suggest we need to revert Josh' commit def09f5a21.

The effect on the crontab example is to invalidate the lines being executed.  The lines were apparently copied in from a cron source, not crontab, despite the header describing it NOT being an example for cron.  It also runs longoverdue twice, instead of fines.pl.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:41 +01:00
Frederic Demians e292c5b116 Fixes bugs #2875-2879
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:41 +01:00
Stan Brinkerhoff dc370aeeee Add 'use warnings' and correct uninitialized value warnings.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:41 +01:00
Galen Charlton 2b1b9446f9 bug 2505: further warnings fixes to memberentry.pl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:41 +01:00
stan f6d7dca4b3 Added 'warnings' support, fixed bug 2870.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:41 +01:00
Allen Reinmeyer 6f4cf9febc Test suite: C4::Members::GetMemberDetails
Tests for C4::Members::GetMemberDetails.  Validates both calls
using either borrowernumber or cardnumber.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:41 +01:00
Frederic Demians 00feac61f5 A script generating keyword clouds from Zebra Indexes
See embedded perldoc to see how it works.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:41 +01:00
Andrew Moore 2b73ba2581 test suite: C4::ImportBatch
Here are some tests for functions in C4::ImportBatch.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:41 +01:00
Andrew Moore 8d39972974 bug 2824: improving error messages from test suite errors
This patch adds two warning messages to places in the test suite that
may fail. I don't think it changes any functionality, but it sure makes
it easier to figure out what has gone wrong.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:41 +01:00
Marc Chantreux 8155f039e6 fixed "too many opened files" error during translation
The problem was that the TmplTokenizer create global symbols to store file
handlers so the objects aren't destroyed by the garbage collector.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:40 +01:00
Galen Charlton 015e2c03fe bug 2864 [2/2]: move rss/* to misc/cronjobs/rss/*
As rss.pl is not a CGI script, moved it to join the
other cronjobs.  Full documentation of the script
is in misc/cronjobs/rss/rss.pl, but to summarize:

[1] rss.pl is run on the command line to produce
    an RSS XML document.  The output should be
    placed in a directory accessible to the OPAC
    (or staff) web interface so that users can download
    the RSS feed.  An example of usage:

    misc/cronjobs/rss.pl lastAcquired.conf

    Normally rss.pl should be run periodically (e.g., daily)
    to keep the feed up-to-date.

[2] The configuration file (e.g., lastAcquired.conf) lists

    * name of the template file to use
    * path of output file
    * SQL query

    rss.pl runs the SQL query, then feeds the output of the
    query through the template to produce the output file.

[3] The template file (e.g., lastAcquired.tmpl) uses
    HTML::Template syntax like any of the HTML
    templates for the web interface.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:40 +01:00
Galen Charlton 1e8b9c1abf bug 2864 [1/2]: restore rss/rss.pl
Restored basic functionality of rss/rss.pl:

[1] Reverted "Add support for itemtypes. Still need to hardcode 'reservable'"
    Revert commit e7575b00ed, which had
    replace the script with one of its templates.

[2] Minor fixes to update it, including using HTML::Template::Pro instead
    of HTML::Template, perltidy, and turning on warnings.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:40 +01:00
Frederic Demians b6b3251858 Add default classification sources and filing rules to fr-FR
fr-FR install wasn't populating classication rules tables:

  * class_sort_rules
  * class_sources

This patch add default values for those tables
mandatory during installation process.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-27 12:19:40 +01:00