Commit graph

9349 commits

Author SHA1 Message Date
Nahuel ANGELINETTI
0209a96db7 Unescape some double quotes, that make a validation error.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-12 16:29:34 -06:00
011fa47b9d Related to earlier patch: adding body id to add flexibility to CSS customizations.
This patch adds a different id to opac-shelves, opac-suggestions, and opac-tags based on whether or not the user is logged in, allowing for changes to style based on logged-in status.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-12 16:21:20 -06:00
Galen Charlton
b99e65ca76 bug 2908 followup - use "list", not "shelf"
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-12 16:18:03 -06:00
Nahuel ANGELINETTI
c49b3eb464 (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-12 15:52:08 -06:00
Nahuel ANGELINETTI
bfebda4ad9 (bug #2908) adding send shelf by e-mail feature
This patch add the form for sending shelf by e-mail, and add a button in shelves that allow the user to send a shelf.
It's an approximate copy of the send basket feature.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-12 15:51:59 -06:00
Galen Charlton
f35a9d5a27 bump DB rev 010 -> 011 2009-01-12 15:16:58 -06:00
Andrew Moore
38d0b4078e Bug 2578: remove unwanted intranetuserjs syspref - Database revision 3.01.00.011
The default syspref setting for intranetuserjs should be empty. At one
time, an unwanted value accidently got put in there. This removes the
syspref only if it equals the unwanted value.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-12 15:15:47 -06:00
Danny Bouman
277049ada5 bug 2687 followup: Increase maxlength attribute to support 64 characters
Modified the borrower attribute and borrower password fields to support a maxlength of 64 characters.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-12 15:05:25 -06:00
Danny Bouman
f198b3f5cf bug 2687: Increased length of borrower attribute fields
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-12 15:02:12 -06:00
Nahuel ANGELINETTI
796f626b5b (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-09 13:22:01 -06:00
Allen Reinmeyer
7ca82ab5d2 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-09 12:28:45 -06:00
Joe Atzberger
54f5ee3332 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>
2009-01-09 12:22:30 -06:00
Galen Charlton
e7aff14ba2 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-09 12:17:49 -06:00
stan
5ce47ac580 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-09 10:42:57 -06:00
Marc Chantreux
38360d470a WEBSERVER_HOST and WEBSERVER_HOST added
comments added too

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-08 14:57:40 -06:00
Galen Charlton
3a7ae97440 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-08 14:19:09 -06:00
Joe Atzberger
c70cd87d54 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-08 11:08:27 -06:00
Galen Charlton
d97ba8cecc bug 2747: avoid warning if items.itype is NULL
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-07 15:33:21 -06:00
Joe Atzberger
cdb4b60d93 Bug 2747 for staff interface itemtype display.
Prefer accuracy over graphical icon.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-07 15:13:43 -06:00
Joe Atzberger
458b0ed510 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-07 15:11:17 -06:00
Galen Charlton
2dcca73ae0 fix permission error introduced in a previous patch
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-06 21:04:42 -06:00
Joe Atzberger
5f1d461df9 Bug 2752 - comment out problematic DELETE op.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-06 20:47:42 -06:00
Michael Hafen
0506218f8b 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-06 20:42:47 -06:00
Michael Hafen
1c6fb50648 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-06 20:40:45 -06:00
ac196cddcc Hiding SMS messaging preferences if there is no SMSSendDriver defined in system preferences.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-06 20:29:53 -06:00
3686361d3e Hiding SMS settings in OPAC if SMSSendDriver is not defined. Fixes Bug 2455, remove SMS column from patron messaging preferences if SMSSendDriver is not defined
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-06 20:29:43 -06:00
Joe Atzberger
a581f7203c Bug 2842: ->regexp('syspref') failed for users of iso dateformat.
Sticky due date and patron import were the two areas affected.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-06 20:24:46 -06:00
Joe Atzberger
4e50585926 Dates expanding to expose some time (HH:MM:SS) granularity.
t/Dates.t is essentially restored from its previous state with
the revision that it now does not use C4::Context or check syspref
for the default date format.  Instead it sets the C4::Dates default
directly, taking cue from command line argument or ENV.  ISO format
revised to accept "T" separator and "Z" (zulu) terminator. POD
expanded and corrected.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-06 20:24:40 -06:00
Nahuel Angelinetti
e5adbdcbd1 a more readable way to test an array size.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-06 19:59:12 -06:00
Galen Charlton
f17e1117df bug 2505: enable warnings for admin/authorized_values.pl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-06 19:44:33 -06:00
Joe Atzberger
c05d5fb40d 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-06 19:36:53 -06:00
Andrew Moore
17d0f7d4ec REFACTOR: correcting indirect object method syntax
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-06 19:26:41 -06:00
Andrew Moore
a5ca358d04 Bug 2505: turning on "warnings" in catalogue/detail.pl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-06 19:26:39 -06:00
20a609b587 A few more tweaks to the OPAC detail view menu
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-06 19:12:30 -06:00
ef612e5667 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-06 19:09:29 -06:00
Galen Charlton
db59418c2c 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-06 18:55:01 -06:00
Galen Charlton
dfa0f6ea24 bug 2505: more warnings fixes to C4/Biblio.pm
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-06 18:54:55 -06:00
f4fcd9e35a 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-05 16:37:07 -06:00
Galen Charlton
4d4e96d667 bug 2505: enable warnings for labels/label-print-pdf.pl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-05 16:34:19 -06:00
Joe Atzberger
e37f8c2b27 Labels Cleanup (Part 2 of Many)
CalcNextLabelPos pulled out of each subblock.
Print of header and initial structure deferred until later to allow fatals_to_browser to
display any fatal errors encountered in data preparation.  This does not fix Unicode "wide character" crashes.
Created subroutine for debug dump lines.
Comparisons corrected (numerical not string compare).

Note: this script is still insecure with NO AUTH CHECK.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-05 16:24:00 -06:00
Andrew Moore
0b1c856e4b 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-05 16:16:38 -06:00
Henri-Damien LAURENT
80781eedeb Using Warns would cause problems with NoZebra
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-05 16:04:52 -06:00
Joe Atzberger
9dbd65da27 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-05 15:55:14 -06:00
Joe Atzberger (siptest
76309ae328 Allow AddIssue to log SIP transactions distinct from others.
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2009-01-05 15:43:12 -06:00
Joe Atzberger
55c2320a23 Labels Cleanup (Part 1 of Many)
Consolidated error catching after evals.
Removed unnecessary $sth->finish calls and some unused variables.
Pulled query for itemtype mappings outside DrawSpineText and added
a class level caching variable to eliminate repeated queries for
*each piece of text* on *each label*!  This was a major performance
downside.

Note: this does not fix Unicode problems, but it does add some notes
on unsuccessful attempted workaround using utf8::encode.

C4::Labels should likely be broken up to separate out the pieces that
do not touch the database (wrappers of PDF::Reuse) and those that are
CRUD API for table data.

Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-12-31 15:56:11 -06:00
Galen Charlton
ca7ae0ab41 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>
2008-12-31 15:53:07 -06:00
Galen Charlton
e4cbee8454 perltidy lables/label-item-search.pl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-12-31 15:35:25 -06:00
Galen Charlton
d958db03a2 bug 2505: turn on warnings in labels/label-item-search.pl
Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
2008-12-31 15:35:17 -06:00
Galen Charlton
330edb157f 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>
2008-12-31 15:35:08 -06:00
Mason James
990e315471 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>
2008-12-31 11:15:44 -06:00