Merge remote branch 'kc/new/bug2567' into kcmaster
authorChris Cormack <chrisc@catalyst.net.nz>
Wed, 3 Nov 2010 08:21:02 +0000 (21:21 +1300)
committerChris Cormack <chrisc@catalyst.net.nz>
Wed, 3 Nov 2010 08:21:36 +0000 (21:21 +1300)
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
139 files changed:
C4/AuthoritiesMarc.pm
C4/Calendar.pm
C4/Koha.pm
C4/XSLT.pm
acqui/z3950_search.pl
admin/fieldmapping.pl
authorities/authorities-home.pl
cataloguing/z3950_search.pl
docs/history.txt
etc/zebradb/biblios/etc/bib1.att
etc/zebradb/ccl.properties
etc/zebradb/marc_defs/marc21/biblios/record.abs
installer/data/mysql/en/marcflavour/marc21/mandatory/marc21_framework_DEFAULT.sql
installer/data/mysql/en/marcflavour/marc21/optional/marc21_simple_bib_frameworks.sql
installer/data/mysql/kohastructure.sql
installer/data/mysql/updatedatabase.pl
koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css
koha-tmpl/intranet-tmpl/prog/en/includes/auth-finder-search.inc
koha-tmpl/intranet-tmpl/prog/en/includes/authorities-search.inc
koha-tmpl/intranet-tmpl/prog/en/includes/background-job.inc
koha-tmpl/intranet-tmpl/prog/en/includes/error-messages.inc
koha-tmpl/intranet-tmpl/prog/en/includes/label-status.inc [deleted file]
koha-tmpl/intranet-tmpl/prog/en/includes/labels-batches-toolbar.inc
koha-tmpl/intranet-tmpl/prog/en/includes/search_indexes.inc
koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/acqui/newordersuggestion.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/acqui/parcel.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/acqui/z3950_search.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/admin/authorised_values.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/admin/categorie.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/admin/checkmarc.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/admin/currency.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/admin/fieldmapping.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/admin/itemtypes.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/i18n-l10n.pref
koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref
koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/staff-client.pref
koha-tmpl/intranet-tmpl/prog/en/modules/basket/sendbasket.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/unimarc_field_100.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/z3950_search.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/circ/branchtransfers.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/circ/pendingreserves.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/circ/waitingreserves.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/acqui/histsearch.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/acqui/neworderempty.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/cataloguing/addbooks.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/cataloguing/merge.tmpl [new file with mode: 0644]
koha-tmpl/intranet-tmpl/prog/en/modules/help/mainpage.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/members/member-password.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/patroncards/edit-template.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/reports/borrowers_stats.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/reports/catalogue_stats.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/reports/reports-home.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/serials/serials-home.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/serials/subscription-add.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/suggestion/suggestion.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/tools/holidays.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/tools/manage-marc-import.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/help/tools/overduerules.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-bib-search.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-edit-batch.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/maint/catmaintain.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-receipt.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/reports/guided_reports_start.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/rotating_collections/addItems.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/rotating_collections/editCollections.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/rotating_collections/transferCollection.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/test/README [new file with mode: 0644]
koha-tmpl/intranet-tmpl/prog/en/modules/test/progressbar.tmpl [new file with mode: 0644]
koha-tmpl/intranet-tmpl/prog/en/modules/tools/holidays.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/tools/import_borrowers.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/tools/picture-upload.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/sendshelf.tmpl
koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tmpl
koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl
koha-tmpl/opac-tmpl/prog/en/modules/opac-advsearch.tmpl
koha-tmpl/opac-tmpl/prog/en/modules/opac-authorities-home.tmpl
koha-tmpl/opac-tmpl/prog/en/modules/opac-results.tmpl
koha-tmpl/opac-tmpl/prog/en/modules/opac-sendbasket.tmpl
koha-tmpl/opac-tmpl/prog/en/modules/opac-sendshelf.tmpl
koha-tmpl/opac-tmpl/prog/en/modules/opac-tags.tmpl
koha-tmpl/opac-tmpl/prog/en/xslt/MARC21slim2OPACDetail.xsl
koha-tmpl/opac-tmpl/prog/en/xslt/MARC21slim2OPACResults.xsl
labels/label-edit-batch.pl
misc/cronjobs/cleanup_database.pl
misc/migration_tools/bulkmarcimport.pl
reserve/renewscript.pl
t/AuthoritiesMarc_MARC21.t [new file with mode: 0755]
t/AuthoritiesMarc_UNIMARC.t [new file with mode: 0755]
t/Barcodes_annual.t [new file with mode: 0755]
t/Barcodes_hbyymmincr.t [new file with mode: 0755]
t/Barcodes_incremental.t [new file with mode: 0755]
t/Cache_FastMemcached.t [new file with mode: 0755]
t/Cache_Memcached.t [new file with mode: 0755]
t/Cache_Memoize_Memcached.t [new file with mode: 0755]
t/ClassSortRoutine_Dewey.t [new file with mode: 0755]
t/ClassSortRoutine_Generic.t [new file with mode: 0755]
t/ClassSortRoutine_LCC.t [new file with mode: 0755]
t/External_BakerTaylor.t [new file with mode: 0755]
t/External_Syndetics.t [new file with mode: 0755]
t/Form_MessagingPreferences.t [new file with mode: 0755]
t/Heading_MARC21.t [new file with mode: 0755]
t/ILSDI_Services.t [new file with mode: 0755]
t/ILSDI_Utility.t [new file with mode: 0755]
t/ImportBatch.t [new file with mode: 0644]
t/Installer_PerlDependencies.t [new file with mode: 0755]
t/Installer_PerlModules.t [new file with mode: 0755]
t/ItemType.t [new file with mode: 0755]
t/Koha.t
t/Members_AttributeTypes.t [new file with mode: 0755]
t/Members_Messaging.t [new file with mode: 0755]
t/Output_JSONStream.t [new file with mode: 0755]
t/Patroncards_Batch.t [new file with mode: 0755]
t/Patroncards_Layout.t [new file with mode: 0755]
t/Patroncards_Lib.t [new file with mode: 0755]
t/Patroncards_Patroncard.t [new file with mode: 0755]
t/Patroncards_Profile.t [new file with mode: 0755]
t/Patroncards_Template.t [new file with mode: 0755]
t/Reports_Guided.t [new file with mode: 0755]
t/SIP_ILS.t [new file with mode: 0755]
t/SIP_Sip.t [new file with mode: 0755]
t/Search_PazPar2.t [new file with mode: 0755]
t/VirtualShelves_Merge.t [new file with mode: 0755]
t/VirtualShelves_Page.t [new file with mode: 0755]
t/Z3950.t [new file with mode: 0644]
test/README [new file with mode: 0644]
test/progressbar.pl [new file with mode: 0755]
test/progressbarsubmit.pl [new file with mode: 0755]
test/search.pl [new file with mode: 0755]
tools/holidays.pl

index b4a0d78..d07cca4 100644 (file)
@@ -901,7 +901,7 @@ sub FindDuplicateAuthority {
         $_->[1]=~s/$filtervalues/ /g; $query.= " and he,wrdl=\"".$_->[1]."\"" if ($_->[0]=~/[A-z]/);
       }
     }
-    my ($error, $results, $total_hits)=SimpleSearch( $query, 0, 1, [ "authorityserver" ] );
+    my ($error, $results, $total_hits) = C4::Search::SimpleSearch( $query, 0, 1, [ "authorityserver" ] );
     # there is at least 1 result => return the 1st one
     if (@$results>0) {
       my $marcrecord = MARC::File::USMARC::decode($results->[0]);
index b5a3436..dc9037b 100644 (file)
@@ -37,7 +37,7 @@ BEGIN {
         &insert_day_month_holiday
         &insert_single_holiday
         &insert_exception_holiday
-       &ModWeekdayholiday
+        &ModWeekdayholiday
         &ModDaymonthholiday
         &ModSingleholiday
         &ModExceptionholiday
index dc2bcfa..e746f83 100644 (file)
@@ -1,6 +1,7 @@
 package C4::Koha;
 
 # Copyright 2000-2002 Katipo Communications
+# Parts Copyright 2010 Nelsonville Public Library
 #
 # This file is part of Koha.
 #
@@ -61,6 +62,7 @@ BEGIN {
                &GetNormalizedISBN
                &GetNormalizedEAN
                &GetNormalizedOCLCNumber
+        &xml_escape
 
                $DEBUG
        );
@@ -672,6 +674,7 @@ sub getImageSets {
     foreach my $imagesubdir ( @subdirectories ) {
         my @imagelist     = (); # hashrefs of image info
         my @imagenames = _getImagesFromDirectory( File::Spec->catfile( $paths->{'staff'}{'filesystem'}, $imagesubdir ) );
+        my $imagesetactive = 0;
         foreach my $thisimage ( @imagenames ) {
             push( @imagelist,
                   { KohaImage     => "$imagesubdir/$thisimage",
@@ -680,8 +683,10 @@ sub getImageSets {
                     checked       => "$imagesubdir/$thisimage" eq $checked ? 1 : 0,
                }
              );
+             $imagesetactive = 1 if "$imagesubdir/$thisimage" eq $checked;
         }
         push @imagesets, { imagesetname => $imagesubdir,
+                           imagesetactive => $imagesetactive,
                            images       => \@imagelist };
         
     }
@@ -1190,6 +1195,25 @@ sub GetKohaAuthorisedValuesFromField {
   }
 }
 
+=head2 xml_escape
+
+  my $escaped_string = C4::Koha::xml_escape($string);
+
+Convert &, <, >, ', and " in a string to XML entities
+
+=cut
+
+sub xml_escape {
+    my $str = shift;
+    return '' unless defined $str;
+    $str =~ s/&/&amp;/g;
+    $str =~ s/</&lt;/g;
+    $str =~ s/>/&gt;/g;
+    $str =~ s/'/&apos;/g;
+    $str =~ s/"/&quot;/g;
+    return $str;
+}
+
 =head2 display_marc_indicators
 
   my $display_form = C4::Koha::display_marc_indicators($field);
index 1c45e44..ddc9077 100644 (file)
@@ -210,9 +210,8 @@ sub buildKohaItemsNamespace {
         } else {
             $status = "available";
         }
-        my $homebranch = $branches->{$item->{homebranch}}->{'branchname'};
-        my $itemcallnumber = $item->{itemcallnumber} || '';
-        $itemcallnumber =~ s/\&/\&amp\;/g;
+        my $homebranch = xml_escape($branches->{$item->{homebranch}}->{'branchname'});
+           my $itemcallnumber = xml_escape($item->{itemcallnumber});
         $xml.= "<item><homebranch>$homebranch</homebranch>".
                "<status>$status</status>".
                "<itemcallnumber>".$itemcallnumber."</itemcallnumber>"
index 0215873..182e121 100755 (executable)
@@ -254,7 +254,14 @@ sub displayresults {
 ##Add necessary encoding changes to here -TG
                         my $oldbiblio = TransformMarcToKoha( $dbh, $marcrecord, "" );
                         $oldbiblio->{isbn}   =~ s/ |-|\.//g if $oldbiblio->{isbn};
-                         $oldbiblio->{issn} =~ s/ |-|\.//g if $oldbiblio->{issn};
+                        # pad | and ( with spaces to allow line breaks in the HTML
+                        $oldbiblio->{isbn} =~ s/\|/ \| /g if $oldbiblio->{isbn};
+                        $oldbiblio->{isbn} =~ s/\(/ \(/g if $oldbiblio->{isbn};
+
+                        $oldbiblio->{issn} =~ s/ |-|\.//g if $oldbiblio->{issn};
+                        # pad | and ( with spaces to allow line breaks in the HTML
+                        $oldbiblio->{issn} =~ s/\|/ \| /g if $oldbiblio->{issn};
+                        $oldbiblio->{issn} =~ s/\(/ \(/g if $oldbiblio->{issn};
                           my (
                             $notmarcrecord, $alreadyindb, $alreadyinfarm,
                             $imported,      $breedingid
index b7122b0..f7eca3c 100755 (executable)
@@ -46,8 +46,15 @@ my ($template, $loggedinuser, $cookie)
 # get framework list
 my $frameworks = getframeworks();
 my @frameworkloop;
+my $selected;
+my $frameworktext;
 foreach my $thisframeworkcode (keys %$frameworks) {
-       my $selected = 1 if $thisframeworkcode eq $framework;
+        if ($thisframeworkcode eq $framework){
+                $selected = 1;
+                $frameworktext = $frameworks->{$thisframeworkcode}->{'frameworktext'};
+     } else {
+               $selected = 0;
+     }
        my %row =(value => $thisframeworkcode,
                                selected => $selected,
                                frameworktext => $frameworks->{$thisframeworkcode}->{'frameworktext'},
@@ -70,6 +77,7 @@ my $fieldloop = GetFieldMapping($framework);
 
 $template->param( frameworkloop => \@frameworkloop, 
                   framework     => $framework,
+                  frameworktext => $frameworktext,
                   fields        => $fieldloop,
                 );
 
index fbaa1ba..edf02a5 100755 (executable)
@@ -161,8 +161,6 @@ elsif ( $op eq "delete" ) {
         }
     );
 
-    #  $template->param("statements" => \@statements,
-    #                                          "nbstatements" => $nbstatements);
 }
 else {
     ( $template, $loggedinuser, $cookie ) = get_template_and_user(
index 9b6c8f1..6311c0b 100755 (executable)
@@ -237,8 +237,15 @@ warn "query ".$query  if $DEBUG;
 # In rel2_2 i am not sure what encoding is so no character conversion is done here
 ##Add necessary encoding changes to here -TG
                         my $oldbiblio = TransformMarcToKoha( $dbh, $marcrecord, "" );
-                        $oldbiblio->{isbn}   =~ s/ |-|\.//g,
-                          $oldbiblio->{issn} =~ s/ |-|\.//g,
+                        $oldbiblio->{isbn}   =~ s/ |-|\.//g if $oldbiblio->{isbn};
+                        # pad | and ( with spaces to allow line breaks in the HTML
+                        $oldbiblio->{isbn} =~ s/\|/ \| /g if $oldbiblio->{isbn};
+                        $oldbiblio->{isbn} =~ s/\(/ \(/g if $oldbiblio->{isbn};
+
+                        $oldbiblio->{issn} =~ s/ |-|\.//g if $oldbiblio->{issn};
+                        # pad | and ( with spaces to allow line breaks in the HTML
+                        $oldbiblio->{issn} =~ s/\|/ \| /g if $oldbiblio->{issn};
+                        $oldbiblio->{issn} =~ s/\(/ \(/g if $oldbiblio->{issn};
                           my (
                             $notmarcrecord, $alreadyindb, $alreadyinfarm,
                             $imported,      $breedingid
index 7750fe6..2dd63e0 100644 (file)
@@ -492,6 +492,7 @@ May 4 2010  Koustubha Kale becomes the 112th committer to have a patch accepted
 May 4 2010     Community Handover meeting http://wiki.koha-community.org/wiki/Community_Handover_IRC_Meeting,_4_May_2010
 May 5 2010     General IRC meeting http://wiki.koha-community.org/wiki/General_Meeting,_May_5_2010
 May 5 2010     Matthew Hunt becomes the 113th committer to have a patch accepted
+May 17 2010    Koha 3.0.6 released
 May 19 2010    Marcel de Rooy becomes the 114th committer to have a patch accepted
 July 19 2010   Andrew Chilton becomes the 115th committer to have a patch accepted
 June 2 2010    General IRC meeting http://wiki.koha-community.org/wiki/General_IRC_Meeting,_2_June_2010
@@ -501,3 +502,8 @@ July 13 2010        License meeting http://wiki.koha-community.org/wiki/License_Upgrade
 August 11 2010 General IRC meeting http://wiki.koha-community.org/wiki/General_IRC_Meeting,_11_August_2010
 September 1 2010       General IRC meeting http://wiki.koha-community.org/wiki/General_IRC_Meeting,_1_September_2010
 September 29 2010      Eric Olsen becomes the 116th committer to have a patch accepted
+October 22 2010        Koha 3.2.0 released
+October 25-31 2010     Kohacon10 in Wellington
+October 30 2010        Brian Engard becomes the 117th committer to have a patch accepted
+October 30 2010 Daniel Grobani becomes the 118th committer to have a patch accepted
+October 31 2010        Nate Curulla becomes the 119th committer to have patch accepted
index d47b2a3..97c3d68 100644 (file)
@@ -189,3 +189,6 @@ att 9903    lex
 att 9904    arl
 att 9013    arp
 att 9520    Item
+# Curriculum
+att 9658    curriculum
+
index 231c420..4bca55e 100644 (file)
@@ -1052,6 +1052,8 @@ arl 1=9904 r=r
 
 #Accelerated Reader Point
 arp 1=9013 r=r
+# Curriculum
+curriculum 1=9658
 
 ## Statuses
 popularity 1=issues
@@ -1067,7 +1069,7 @@ dt-map 1=8700
 r1 9=32
 r2 9=28
 r3 9=26
-r4 9=10
+r4 9=24
 r5 9=22
 r6 9=20
 r7 9=18
index 6cf37ba..4874bfd 100644 (file)
@@ -188,6 +188,9 @@ melm 656$9      Koha-Auth-Number
 melm 656        Subject
 melm 657$9      Koha-Auth-Number    
 melm 657        Subject
+melm 658$a     curriculum:w,curriculum:p
+melm 658$b     curriculum:w,curriculum:p
+melm 658$c     curriculum:w,curriculum:p
 melm 690$9      Koha-Auth-Number    
 melm 690        Subject,Subject:p
 
index a5e7d77..3cbc997 100644 (file)
@@ -1895,9 +1895,9 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian`
                ('658', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -6, '', '', '', NULL),
                ('658', '6', 'Linkage', 'Linkage', 0, 0, '', 6, '', '', '', NULL, -6, '', '', '', NULL),
                ('658', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 6, '', '', '', NULL, -6, '', '', '', NULL),
-               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, -6, '', '', '', NULL),
-               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, -6, '', '', '', NULL),
-               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, -6, '', '', '', NULL),
+               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, 0, '', '', '', NULL),
+               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, 0, '', '', '', NULL),
+               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, 0, '', '', '', NULL),
                ('658', 'd', 'Correlation factor', 'Correlation factor', 0, 0, '', 6, '', '', '', NULL, -6, '', '', '', NULL),
                ('662', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, 0, '', '', '', NULL),
                ('662', '3', 'Materials specified', 'Materials specified', 0, 0, '', 6, '', '', '', NULL, -6, '', '', '', NULL),
index 8821aa2..78a18d6 100644 (file)
@@ -1920,9 +1920,9 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian`
                ('658', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -1, 'BKS', '', '', NULL),
                ('658', '6', 'Linkage', 'Linkage', 0, 0, '', 6, '', '', '', NULL, -6, 'BKS', '', '', NULL),
                ('658', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 6, '', '', '', NULL, -6, 'BKS', '', '', NULL),
-               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, -1, 'BKS', '', '', NULL),
-               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, -1, 'BKS', '', '', NULL),
-               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, -1, 'BKS', '', '', NULL),
+               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, 0, 'BKS', '', '', NULL),
+               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, 0, 'BKS', '', '', NULL),
+               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, 0, 'BKS', '', '', NULL),
                ('658', 'd', 'Correlation factor', 'Correlation factor', 0, 0, '', 6, '', '', '', NULL, -1, 'BKS', '', '', NULL),
                ('662', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -6, 'BKS', '', '', NULL),
                ('662', '3', 'Materials specified', 'Materials specified', 0, 0, '', 6, '', '', '', NULL, -6, 'BKS', '', '', NULL),
@@ -5841,9 +5841,9 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian`
                ('658', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -1, 'CF', '', '', NULL),
                ('658', '6', 'Linkage', 'Linkage', 0, 0, '', 6, '', '', '', NULL, -6, 'CF', '', '', NULL),
                ('658', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 6, '', '', '', NULL, -6, 'CF', '', '', NULL),
-               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, -1, 'CF', '', '', NULL),
-               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, -1, 'CF', '', '', NULL),
-               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, -1, 'CF', '', '', NULL),
+               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, 0, 'CF', '', '', NULL),
+               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, 0, 'CF', '', '', NULL),
+               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, 0, 'CF', '', '', NULL),
                ('658', 'd', 'Correlation factor', 'Correlation factor', 0, 0, '', 6, '', '', '', NULL, -1, 'CF', '', '', NULL),
                ('662', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -6, 'CF', '', '', NULL),
                ('662', '3', 'Materials specified', 'Materials specified', 0, 0, '', 6, '', '', '', NULL, -6, 'CF', '', '', NULL),
@@ -9761,9 +9761,9 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian`
                ('658', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -1, 'SR', '', '', NULL),
                ('658', '6', 'Linkage', 'Linkage', 0, 0, '', 6, '', '', '', NULL, -6, 'SR', '', '', NULL),
                ('658', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 6, '', '', '', NULL, -6, 'SR', '', '', NULL),
-               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, -1, 'SR', '', '', NULL),
-               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, -1, 'SR', '', '', NULL),
-               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, -1, 'SR', '', '', NULL),
+               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, 0, 'SR', '', '', NULL),
+               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, 0, 'SR', '', '', NULL),
+               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, 0, 'SR', '', '', NULL),
                ('658', 'd', 'Correlation factor', 'Correlation factor', 0, 0, '', 6, '', '', '', NULL, -1, 'SR', '', '', NULL),
                ('662', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -6, 'SR', '', '', NULL),
                ('662', '3', 'Materials specified', 'Materials specified', 0, 0, '', 6, '', '', '', NULL, -6, 'SR', '', '', NULL),
@@ -13681,9 +13681,9 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian`
                ('658', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -1, 'VR', '', '', NULL),
                ('658', '6', 'Linkage', 'Linkage', 0, 0, '', 6, '', '', '', NULL, -6, 'VR', '', '', NULL),
                ('658', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 6, '', '', '', NULL, -6, 'VR', '', '', NULL),
-               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, -1, 'VR', '', '', NULL),
-               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, -1, 'VR', '', '', NULL),
-               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, -1, 'VR', '', '', NULL),
+               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, 0, 'VR', '', '', NULL),
+               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, 0, 'VR', '', '', NULL),
+               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, 0, 'VR', '', '', NULL),
                ('658', 'd', 'Correlation factor', 'Correlation factor', 0, 0, '', 6, '', '', '', NULL, -1, 'VR', '', '', NULL),
                ('662', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -6, 'VR', '', '', NULL),
                ('662', '3', 'Materials specified', 'Materials specified', 0, 0, '', 6, '', '', '', NULL, -6, 'VR', '', '', NULL),
@@ -17599,9 +17599,9 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian`
                ('658', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -1, 'AR', '', '', NULL),
                ('658', '6', 'Linkage', 'Linkage', 0, 0, '', 6, '', '', '', NULL, -6, 'AR', '', '', NULL),
                ('658', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 6, '', '', '', NULL, -6, 'AR', '', '', NULL),
-               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, -1, 'AR', '', '', NULL),
-               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, -1, 'AR', '', '', NULL),
-               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, -1, 'AR', '', '', NULL),
+               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, 0, 'AR', '', '', NULL),
+               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, 0, 'AR', '', '', NULL),
+               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, 0, 'AR', '', '', NULL),
                ('658', 'd', 'Correlation factor', 'Correlation factor', 0, 0, '', 6, '', '', '', NULL, -1, 'AR', '', '', NULL),
                ('662', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -6, 'AR', '', '', NULL),
                ('662', '3', 'Materials specified', 'Materials specified', 0, 0, '', 6, '', '', '', NULL, -6, 'AR', '', '', NULL),
@@ -21517,9 +21517,9 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian`
                ('658', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -1, 'KT', '', '', NULL),
                ('658', '6', 'Linkage', 'Linkage', 0, 0, '', 6, '', '', '', NULL, -6, 'KT', '', '', NULL),
                ('658', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 6, '', '', '', NULL, -6, 'KT', '', '', NULL),
-               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, -1, 'KT', '', '', NULL),
-               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, -1, 'KT', '', '', NULL),
-               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, -1, 'KT', '', '', NULL),
+               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, 0, 'KT', '', '', NULL),
+               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, 0, 'KT', '', '', NULL),
+               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, 0, 'KT', '', '', NULL),
                ('658', 'd', 'Correlation factor', 'Correlation factor', 0, 0, '', 6, '', '', '', NULL, -1, 'KT', '', '', NULL),
                ('662', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -6, 'KT', '', '', NULL),
                ('662', '3', 'Materials specified', 'Materials specified', 0, 0, '', 6, '', '', '', NULL, -6, 'KT', '', '', NULL),
@@ -25436,9 +25436,9 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian`
                ('658', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -1, 'IR', '', '', NULL),
                ('658', '6', 'Linkage', 'Linkage', 0, 0, '', 6, '', '', '', NULL, -6, 'IR', '', '', NULL),
                ('658', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 6, '', '', '', NULL, -6, 'IR', '', '', NULL),
-               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, -1, 'IR', '', '', NULL),
-               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, -1, 'IR', '', '', NULL),
-               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, -1, 'IR', '', '', NULL),
+               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, 0, 'IR', '', '', NULL),
+               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, 0, 'IR', '', '', NULL),
+               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, 0, 'IR', '', '', NULL),
                ('658', 'd', 'Correlation factor', 'Correlation factor', 0, 0, '', 6, '', '', '', NULL, -1, 'IR', '', '', NULL),
                ('662', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -6, 'IR', '', '', NULL),
                ('662', '3', 'Materials specified', 'Materials specified', 0, 0, '', 6, '', '', '', NULL, -6, 'IR', '', '', NULL),
@@ -29351,9 +29351,9 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian`
                ('658', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -1, 'SER', '', '', NULL),
                ('658', '6', 'Linkage', 'Linkage', 0, 0, '', 6, '', '', '', NULL, -6, 'SER', '', '', NULL),
                ('658', '8', 'Field link and sequence number', 'Field link and sequence number', 1, 0, '', 6, '', '', '', NULL, -6, 'SER', '', '', NULL),
-               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, -1, 'SER', '', '', NULL),
-               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, -1, 'SER', '', '', NULL),
-               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, -1, 'SER', '', '', NULL),
+               ('658', 'a', 'Main curriculum objective', 'Main curriculum objective', 0, 0, '', 6, '', 'TOPIC_TERM', '', NULL, 0, 'SER', '', '', NULL),
+               ('658', 'b', 'Subordinate curriculum objective', 'Subordinate curriculum objective', 1, 0, '', 6, '', '', '', NULL, 0, 'SER', '', '', NULL),
+               ('658', 'c', 'Curriculum code', 'Curriculum code', 0, 0, '', 6, '', '', '', NULL, 0, 'SER', '', '', NULL),
                ('658', 'd', 'Correlation factor', 'Correlation factor', 0, 0, '', 6, '', '', '', NULL, -1, 'SER', '', '', NULL),
                ('662', '2', 'Source of term', 'Source of term', 0, 0, '', 6, '', '', '', NULL, -6, 'SER', '', '', NULL),
                ('662', '3', 'Materials specified', 'Materials specified', 0, 0, '', 6, '', '', '', NULL, -6, 'SER', '', '', NULL),
index e42652c..9148970 100644 (file)
@@ -1791,10 +1791,15 @@ CREATE TABLE `subscriptionhistory` (
 DROP TABLE IF EXISTS `subscriptionroutinglist`;
 CREATE TABLE `subscriptionroutinglist` (
   `routingid` int(11) NOT NULL auto_increment,
-  `borrowernumber` int(11) default NULL,
+  `borrowernumber` int(11) NOT NULL,
   `ranking` int(11) default NULL,
-  `subscriptionid` int(11) default NULL,
-  PRIMARY KEY  (`routingid`)
+  `subscriptionid` int(11) NOT NULL,
+  PRIMARY KEY  (`routingid`),
+  UNIQUE (`subscriptionid`, `borrowernumber`),
+  CONSTRAINT `subscriptionroutinglist_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`)
+    ON DELETE CASCADE ON UPDATE CASCADE,
+  CONSTRAINT `subscriptionroutinglist_ibfk_2` FOREIGN KEY (`subscriptionid`) REFERENCES `subscription` (`subscriptionid`)
+    ON DELETE CASCADE ON UPDATE CASCADE
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
 
 --
index 523c533..6443c67 100755 (executable)
@@ -3799,6 +3799,33 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
     SetVersion ($DBversion);
 }
 
+$DBversion = "3.01.00.XXX";
+if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
+    $dbh->do("DELETE FROM subscriptionroutinglist WHERE borrowernumber IS NULL;");
+    $dbh->do("ALTER TABLE subscriptionroutinglist MODIFY COLUMN `borrowernumber` int(11) NOT NULL;");
+    $dbh->do("DELETE FROM subscriptionroutinglist WHERE subscriptionid IS NULL;");
+    $dbh->do("ALTER TABLE subscriptionroutinglist MODIFY COLUMN `subscriptionid` int(11) NOT NULL;");
+    $dbh->do("CREATE TEMPORARY TABLE del_subscriptionroutinglist 
+              SELECT s1.routingid FROM subscriptionroutinglist s1
+              WHERE EXISTS (SELECT * FROM subscriptionroutinglist s2
+                            WHERE s2.borrowernumber = s1.borrowernumber
+                            AND   s2.subscriptionid = s1.subscriptionid 
+                            AND   s2.routingid < s1.routingid);");
+    $dbh->do("DELETE FROM subscriptionroutinglist
+              WHERE routingid IN (SELECT routingid FROM del_subscriptionroutinglist);");
+    $dbh->do("ALTER TABLE subscriptionroutinglist ADD UNIQUE (subscriptionid, borrowernumber);");
+    $dbh->do("ALTER TABLE subscriptionroutinglist 
+                ADD CONSTRAINT `subscriptionroutinglist_ibfk_1` FOREIGN KEY (`borrowernumber`) 
+                REFERENCES `borrowers` (`borrowernumber`)
+                ON DELETE CASCADE ON UPDATE CASCADE");
+    $dbh->do("ALTER TABLE subscriptionroutinglist 
+                ADD CONSTRAINT `subscriptionroutinglist_ibfk_2` FOREIGN KEY (`subscriptionid`) 
+                REFERENCES `subscription` (`subscriptionid`)
+                ON DELETE CASCADE ON UPDATE CASCADE");
+    print "Upgrade to $DBversion done (Make subscriptionroutinglist more strict)\n";
+    SetVersion ($DBversion);
+}
+
 =item DropAllForeignKeys($table)
 
   Drop all foreign keys of the table $table
index 13ac2c7..7803604 100644 (file)
@@ -499,7 +499,8 @@ fieldset.brief {
        border : 1px solid #E8E8E8;
 }
 
-fieldset.brief label {
+fieldset.brief label,
+fieldset.brief span.label {
        display : block;
        font-weight : bold;
        padding : .3em 0;
@@ -535,7 +536,8 @@ div.yui-b fieldset.brief select {
 div.yui-b fieldset.brief li.radio {
        padding : .7em 0;
 }
-div.yui-b fieldset.brief li.radio label {
+div.yui-b fieldset.brief li.radio label,
+div.yui-b fieldset.brief li.radio span.label {
        display : inline;
 }
 
index 8a725f0..437b313 100644 (file)
@@ -1,7 +1,6 @@
 <form name="f" method="get" action="auth_finder.pl">
             <input type="hidden" name="op" value="do_search" />
             <input type="hidden" name="type" value="intranet" />
-            <input type="hidden" name="nbstatements" value="<!-- TMPL_VAR NAME="nbstatements" -->" />
             <input type="hidden" name="index" value="<!-- TMPL_VAR NAME="index" -->" />
                 <fieldset class="rows"><ol><li>
                     <span class="label">Authority type</span>
index 9a7b2e3..0a1548f 100644 (file)
@@ -6,7 +6,6 @@
     <form action="/cgi-bin/koha/authorities/authorities-home.pl" method="get">
         <input type="hidden" name="op" value="do_search" />
         <input type="hidden" name="type" value="intranet" />
-        <input type="hidden" name="nbstatements" value="<!-- TMPL_VAR NAME="nbstatements" -->" />
         <select name="authtypecode">
         <!-- TMPL_LOOP NAME="authtypesloop" -->
             <!-- TMPL_IF name="selected" -->
@@ -36,7 +35,6 @@
     <form action="/cgi-bin/koha/authorities/authorities-home.pl" method="get">
         <input type="hidden" name="op" value="do_search" />
         <input type="hidden" name="type" value="intranet" />
-        <input type="hidden" name="nbstatements" value="<!-- TMPL_VAR NAME="nbstatements" -->" />
         <select  name="authtypecode">
         <!-- TMPL_LOOP NAME="authtypesloop" -->
             <!-- TMPL_IF name="selected" -->
@@ -68,7 +66,6 @@
     <form action="/cgi-bin/koha/authorities/authorities-home.pl" method="get">
         <input type="hidden" name="op" value="do_search" />
         <input type="hidden" name="type" value="intranet" />
-        <input type="hidden" name="nbstatements" value="<!-- TMPL_VAR NAME="nbstatements" -->" />
         <select name="authtypecode">
         <!-- TMPL_LOOP NAME="authtypesloop" -->
             <!-- TMPL_IF name="selected" -->
index 9d257f4..7d65d4d 100644 (file)
@@ -15,7 +15,7 @@
             if (json.job_status == 'completed') {
                 percentage = 100;
             }
-                               var bgproperty = (parseInt(percentage)*2-300)+"px 0px";
+                               var bgproperty = (parseInt(percentage/2)*3-300)+"px 0px";
                 $("#jobprogress").css("background-position",bgproperty);
                                $("#jobprogresspercent").text(percentage);
 
@@ -47,7 +47,7 @@
             // gather up form submission
             var inputs = [];
             $(':input', f).each(function() {
-                if (this.type == 'radio') {
+                if (this.type == 'radio' || this.type == 'checkbox') {
                     if (this.checked) {
                         inputs.push(this.name + '=' + escape(this.value));
                     }
@@ -66,7 +66,7 @@
                 data: inputs.join('&'),
                 url: f.action,
                 dataType: 'json',
-               type: 'post',
+                       type: 'post',
                 success: function(json) {
                     jobID = json.jobID;
                     inBackgroundJobProgressTimer = false;
index 7eb0fe8..9f2e143 100644 (file)
@@ -74,7 +74,7 @@ window.onload=function(){
         <!-- TMPL_IF NAME="101" -->
         The database returned an error while <!-- TMPL_IF NAME="card_element" -->saving <!-- TMPL_VAR NAME="card_element" --> <!-- TMPL_VAR NAME="element_id" --><!-- TMPL_ELSE -->attempting a save operation<!-- /TMPL_IF -->. Please have your system administrator check the error log for details.
         <!-- TMPL_ELSIF NAME="102" -->
-        The database returned an error while <!-- TMPL_IF NAME="card_element" -->deleteing <!-- TMPL_VAR NAME="card_element" --> <!-- TMPL_VAR NAME="element_id" --><!-- TMPL_ELSIF NAME=image_ids --><!-- TMPL_VAR NAME="image_ids" --><!-- TMPL_ELSE -->attempting a delete operation<!-- /TMPL_IF -->. Please have your system administrator check the error log for details.
+        The database returned an error while <!-- TMPL_IF NAME="card_element" -->deleting <!-- TMPL_VAR NAME="card_element" --> <!-- TMPL_VAR NAME="element_id" --><!-- TMPL_ELSIF NAME=image_ids --><!-- TMPL_VAR NAME="image_ids" --><!-- TMPL_ELSE -->attempting a delete operation<!-- /TMPL_IF -->. Please have your system administrator check the error log for details.
         <!-- TMPL_ELSIF NAME="201" -->
         An unsupported operation was attempted<!-- TMPL_IF NAME="element_id" --> on <!-- TMPL_VAR NAME="card_element" --> <!-- TMPL_VAR NAME="element_id" --><!-- /TMPL_IF -->. Please have your system administrator check the error log for details.
         <!-- TMPL_ELSIF NAME="202" -->
diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/label-status.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/label-status.inc
deleted file mode 100644 (file)
index 3202ad4..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-<div style="margin-top: 1em;">
-<h3>Active  Settings</h3>
-<table>
-<tr><th>Layout:</th><td><!-- TMPL_IF NAME="active_layout_name" --><!-- TMPL_VAR NAME="active_layout_name" --><!-- TMPL_ELSE --><span class="error">No Layout Specified: <a href="/cgi-bin/koha/labels/label-home.pl">Select a Label Layout</a></span><!-- /TMPL_IF --> </td></tr>
-<tr><th>Template: </th><td><!-- TMPL_IF NAME="active_template_name" --><!-- TMPL_VAR NAME="active_template_name" --><!-- TMPL_ELSE --><span class="error">No Template Specified: <a href="/cgi-bin/koha/labels/label-templates.pl">Select a Label Template</a></span><!-- /TMPL_IF --> </td></tr>
-<tr><th>Batch: </th><td><!-- TMPL_IF NAME="batch_id" --><!-- TMPL_VAR NAME="batch_id" --><!-- TMPL_ELSE --><span class="error"><a href="/cgi-bin/koha/labels/label-manager.pl?op=add_batch&amp;type=<!-- TMPL_VAR NAME="batch_type" -->">Create a new batch</a></span><!-- /TMPL_IF --> </td></tr>
-</table>
-</div>
index 47a0b8f..f3a2006 100644 (file)
                 }
             };
             function Add() {
-                window.open("/cgi-bin/koha/labels/label-item-search.pl?batch_id=<!-- TMPL_VAR NAME="batch_id" -->&amp;type=labels",'FindABibIndex','width=875,height=400,toolbar=no,scrollbars=yes');
+                var barcodes = document.getElementById("barcode");
+                if (barcodes.value == '') {
+                    window.open("/cgi-bin/koha/labels/label-item-search.pl?batch_id=<!-- TMPL_VAR NAME="batch_id" -->&amp;type=labels",'FindABibIndex','width=875,height=400,toolbar=no,scrollbars=yes');
+                }
+                else {
+                    document.forms["add_by_barcode"].submit();
+                }
             };
             function DeDuplicate() {
                 window.location = "/cgi-bin/koha/labels/label-edit-batch.pl?op=de_duplicate&amp;batch_id=<!-- TMPL_VAR NAME="batch_id" -->";
index cd3226c..fe58c61 100644 (file)
@@ -20,6 +20,7 @@
     <option value="callnum">&nbsp;&nbsp;&nbsp;&nbsp; Call Number</option>
     <option value="ln,rtrn">Language</option>
     <option value="nt">Notes/Comments</option>
+    <option value="curriculum">Curriculum</option>
     <option value="pb">Publisher</option>
     <option value="pl">Publisher Location</option>
     <option value="yr">Publication Date (yyyy)</option>
index e8ef0eb..f09f474 100644 (file)
@@ -19,7 +19,7 @@
 
 
 <!-- TMPL_IF NAME="total" -->
-<b><!-- TMPL_VAR NAME="total" -->results found </b> 
+<b><!-- TMPL_VAR NAME="total" --> results found </b> 
 <!-- TMPL_VAR name='pagination_bar'-->
 <!-- TMPL_ELSE -->
 <h3> No results found</h3>
index 1534e75..9b6bb56 100644 (file)
@@ -1,5 +1,5 @@
 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
-<title>Koha &rsaquo; Acquisitions &rsaquo; Shopping Basket <!-- TMPL_VAR NAME="basketno" --> &rsaquo; <!-- TMPL_IF name="ordernumber" -->Modify order details (line #<!-- TMPL_VAR NAME="ordernumber" -->)<!-- TMPL_ELSE -->New order<!-- /TMPL_IF --></title>
+<title>Koha &rsaquo; Acquisitions &rsaquo; Basket <!-- TMPL_VAR NAME="basketno" --> &rsaquo; <!-- TMPL_IF name="ordernumber" -->Modify order details (line #<!-- TMPL_VAR NAME="ordernumber" -->)<!-- TMPL_ELSE -->New order<!-- /TMPL_IF --></title>
 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
 
 <script type="text/javascript" src="<!-- TMPL_VAR NAME='themelang' -->/js/acq.js"></script>
@@ -21,7 +21,7 @@ function Check(ff) {
 
     if (!(isNum(ff.quantity,0))){
         ok=1;
-                    _alertString += "\n- " + _("Quanity must be greater than '0'");
+                    _alertString += "\n- " + _("Quantity must be greater than '0'");
     }
 
     if (!(isNum(ff.listprice,0))){
@@ -57,7 +57,7 @@ ff.submit();
 <!-- TMPL_INCLUDE NAME="header.inc" -->
 <!-- TMPL_INCLUDE NAME="acquisitions-search.inc" -->
 
-<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a> &rsaquo; <a href="/cgi-bin/koha/acqui/basket.pl?basketno=<!-- TMPL_VAR NAME="basketno" -->">Shopping Basket <!-- TMPL_VAR NAME="basketno" --></a> &rsaquo; <!-- TMPL_IF name="ordernumber" -->Modify order details (line #<!-- TMPL_VAR NAME="ordernumber" -->)<!-- TMPL_ELSE -->New order<!-- /TMPL_IF --></div>
+<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a> &rsaquo; <a href="/cgi-bin/koha/acqui/basket.pl?basketno=<!-- TMPL_VAR NAME="basketno" -->">Basket <!-- TMPL_VAR NAME="basketno" --></a> &rsaquo; <!-- TMPL_IF name="ordernumber" -->Modify order details (line #<!-- TMPL_VAR NAME="ordernumber" -->)<!-- TMPL_ELSE -->New order<!-- /TMPL_IF --></div>
 
 <div id="doc3" class="yui-t2">
 
index e18b89f..630d9ba 100644 (file)
@@ -6,7 +6,7 @@
 <!-- TMPL_INCLUDE NAME="header.inc" -->
 <!-- TMPL_INCLUDE NAME="suggestions-add-search.inc" -->
 
-<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a> &rsaquo; <a href="/cgi-bin/koha/acqui/supplier.pl?supplierid=<!-- TMPL_VAR NAME="supplierid" -->"><!-- TMPL_VAR NAME="name" --></a> &rsaquo; <a href="/cgi-bin/koha/acqui/basket.pl?basketno=<!-- TMPL_VAR NAME="basketno" -->">Shopping Basket <!-- TMPL_VAR NAME="basketno" --></a> &rsaquo; Add order from a suggestion</div>
+<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a> &rsaquo; <a href="/cgi-bin/koha/acqui/supplier.pl?supplierid=<!-- TMPL_VAR NAME="supplierid" -->"><!-- TMPL_VAR NAME="name" --></a> &rsaquo; <a href="/cgi-bin/koha/acqui/basket.pl?basketno=<!-- TMPL_VAR NAME="basketno" -->">Basket <!-- TMPL_VAR NAME="basketno" --></a> &rsaquo; Add order from a suggestion</div>
 
 <div id="doc3" class="yui-t2">
    
index 9f7f11e..d3409ca 100644 (file)
     <thead>
         <tr>
             <th>Basket</th>
-            <th>Order</th>
+            <th>Order Line</th>
             <th>Summary</th>
            <th>View Record</th>
             <th>Quantity</th>
         <thead>
            <tr>
                <th>Basket</th>
-               <th>Order</th>
+               <th>Order Line</th>
                <th>Summary</th>
                <th>View Record</th>
                <th>Est cost</th>
                </li>
 
                <li>
-                   <label for="orderfilter">Order :</label>
+                   <label for="orderfilter">Order Line :</label>
                    <input type="text" name="orderfilter" id="orderfilter" />
                </li>
            </ol>
index f9f96ae..2219dfa 100644 (file)
@@ -14,6 +14,7 @@ $.tablesorter.addParser({
 });
 
        $(document).ready(function(){
+    $.tablesorter.defaults.widgets = ['zebra'];
     $("#CheckAll").click(function(){
         $(".checkboxed").checkCheckboxes();
         return false;
@@ -22,23 +23,48 @@ $.tablesorter.addParser({
         $(".checkboxed").unCheckCheckboxes();
         return false;
     });
+
+    $("#closemenu").click(function(e){
+        $(".linktools").hide();
+        $("tr").removeClass("selected");
+    });
+
        $("#resultst").tablesorter({
                sortList: [[1,0]],
-               headers: { 0: {sorter:false}, 1: { sorter: 'articles' },5: { sorter: false },6: { sorter: false }}
+               headers: { 1: { sorter: 'articles' },5: { sorter: false },6: { sorter: false }}
        });
+        /* Inline edit/delete links */
+        $("td").click(function(event){
+            var $tgt = $(event.target);
+            $(".linktools").hide();
+            $("tr").removeClass("selected");
+            if($tgt.is("a")||$tgt.is(":nth-child(5)")||$tgt.is(":nth-child(6)")||$tgt.is(":nth-child(7)")||$tgt.is(":nth-child(8)")){
+                return true;
+            } else {
+                var position = $(this).offset();
+                var top = position.top+5;
+                var left = position.left+5;
+                $(".linktools",row).show().css("position","absolute").css("top",top).css("left",left);
+            }
+            var row = $(this).parent();
+            row.addClass("selected");
+        });
 });
 //]]>
 </script>
-   <style type="text/css">
-   #custom-doc { width:54.92em;*width:53.55em;min-width:720px; margin:auto; text-align:left; }
-   </style>
+<style type="text/css">
+.linktools { background-color:#FFF;border-top:1px solid #DDD; border-left: 1px solid #DDD; border-right: 1px solid #666; border-bottom:1px solid #666;display: none; white-space: nowrap;}
+.linktools a { font-size : 85%; text-decoration:none; padding:.3em;;background-color:#FFF; display:block;float:left;border-right:1px solid #DDD;}
+.linktools a:hover { background-color:#EEE;color:#CC3300;border-right:1px solid #CCC;}
+tr.selected { background-color : #FFFFCC; } tr.selected td { background-color : transparent !important; }
+</style>
 </head>
 <body>
 <!-- TMPL_INCLUDE NAME="header.inc" -->
 <!-- TMPL_INCLUDE NAME="acquisitions-search.inc" -->
 
 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a> &rsaquo; Order from Z39.50 search</div>
-<div id="custom-doc" class="yui-t7">
+<div id="doc3" class="yui-t7">
       <div id="bd">
          <!-- TMPL_IF name="opsearch" -->
 <h2>Z39.50 Search Points</h2>
@@ -114,13 +140,13 @@ $.tablesorter.addParser({
         <!-- TMPL_IF NAME="breedingid" -->
 
         <!-- TMPL_IF NAME="toggle" --><tr class="highlight"><!-- TMPL_ELSE --><tr><!-- /TMPL_IF -->
-            <td><!-- TMPL_VAR name="server" --></td>
+            <td><!-- TMPL_VAR name="server" --> <div class="linktools"><a href="/cgi-bin/koha/catalogue/showmarc.pl?importid=<!-- TMPL_VAR NAME="breedingid" -->" rel="gb_page_center[600,500]">Preview MARC</a> <a href="/cgi-bin/koha/catalogue/showmarc.pl?viewas=card&amp;importid=<!-- TMPL_VAR NAME="breedingid" -->" rel="gb_page_center[600,500]">Preview Card</a> <a href="/cgi-bin/koha/acqui/neworderempty.pl?frameworkcode=<!-- TMPL_VAR name="frameworkcode" -->&amp;breedingid=<!-- TMPL_VAR NAME="breedingid" -->&amp;booksellerid=<!-- TMPL_VAR name="booksellerid" -->&amp;basketno=<!-- TMPL_VAR name="basketno" -->">Order</a> <a href="#" id="closemenu" title="Close this menu"> X </a></div></td>
             <td><!-- TMPL_VAR NAME="title" ESCAPE="html" --></td>
             <td><!-- TMPL_VAR NAME="author" --></td>
             <td><!-- TMPL_VAR NAME="isbn" --></td>
             <td><!-- TMPL_VAR NAME="lccn" --></td>
-            <td><a href="/cgi-bin/koha/catalogue/showmarc.pl?importid=<!-- TMPL_VAR NAME="breedingid" -->" title="MARC" rel="gb_page_center[600,500]">MARC</a></td><td><a href="/cgi-bin/koha/catalogue/showmarc.pl?viewas=card&importid=<!-- TMPL_VAR NAME="breedingid" -->" title="MARC" rel="gb_page_center[600,500]">Card</a></td>
-                       <td><a href="/cgi-bin/koha/acqui/neworderempty.pl?frameworkcode=<!-- TMPL_VAR name="frameworkcode" -->&breedingid=<!-- TMPL_VAR NAME="breedingid" -->&booksellerid=<!-- TMPL_VAR name="booksellerid" -->&basketno=<!-- TMPL_VAR name="basketno" -->">Order</a></td>
+            <td><a href="/cgi-bin/koha/catalogue/showmarc.pl?importid=<!-- TMPL_VAR NAME="breedingid" -->" title="MARC" rel="gb_page_center[600,500]">MARC</a></td><td><a href="/cgi-bin/koha/catalogue/showmarc.pl?viewas=card&amp;importid=<!-- TMPL_VAR NAME="breedingid" -->" title="MARC" rel="gb_page_center[600,500]">Card</a></td>
+                       <td><a href="/cgi-bin/koha/acqui/neworderempty.pl?frameworkcode=<!-- TMPL_VAR name="frameworkcode" -->&amp;breedingid=<!-- TMPL_VAR NAME="breedingid" -->&amp;booksellerid=<!-- TMPL_VAR name="booksellerid" -->&amp;basketno=<!-- TMPL_VAR name="basketno" -->">Order</a></td>
 
         </tr>
         <!-- /TMPL_IF -->
index 367930a..cd2cf33 100644 (file)
@@ -70,7 +70,7 @@
                        <ul>
                                        <li><a href="/cgi-bin/koha/admin/authorised_values.pl?op=add_form&amp;category=<!-- TMPL_VAR NAME="category" -->#none">None</a></li>
                                  <!-- TMPL_LOOP NAME="imagesets" -->
-                                       <li><a href="/cgi-bin/koha/admin/authorised_values.pl?op=add_form&amp;category=<!-- TMPL_VAR NAME="category" -->#<!-- TMPL_VAR NAME="imagesetname" -->"><!-- TMPL_VAR name="imagesetname" --></a></li>
+                                       <!-- TMPL_IF NAME="imagesetactive" --><li class="ui-tabs-selected"><!-- TMPL_ELSE --><li><!-- /TMPL_IF --><a href="/cgi-bin/koha/admin/authorised_values.pl?op=add_form&amp;category=<!-- TMPL_VAR NAME="category" -->#<!-- TMPL_VAR NAME="imagesetname" -->"><!-- TMPL_VAR name="imagesetname" --></a></li>
                                  <!-- /TMPL_LOOP -->
                        </ul>
                </div>
index 2c1f022..1b108a7 100644 (file)
                                        <!-- TMPL_IF NAME="type_A" --><option value="A" selected="selected">Adult</option><!-- TMPL_ELSE --><option value="A">Adult</option><!-- /TMPL_IF -->
                                        <!-- TMPL_IF NAME="type_C" --><option value="C" selected="selected">Child</option><!-- TMPL_ELSE --><option value="C">Child</option><!-- /TMPL_IF -->
                                        <!-- TMPL_IF NAME="type_S" --><option value="S" selected="selected">Staff</option><!-- TMPL_ELSE --><option value="S">Staff</option><!-- /TMPL_IF -->
-                                       <!-- TMPL_IF NAME="type_I" --><option value="I" selected="selected">Organisztion</option><!-- TMPL_ELSE --><option value="I">Organization</option><!-- /TMPL_IF -->
+                                       <!-- TMPL_IF NAME="type_I" --><option value="I" selected="selected">Organization</option><!-- TMPL_ELSE --><option value="I">Organization</option><!-- /TMPL_IF -->
                                        <!-- TMPL_IF NAME="type_P" --><option value="P" selected="selected">Professional</option><!-- TMPL_ELSE --><option value="P">Professional</option><!-- /TMPL_IF -->
                                        <!-- TMPL_IF NXME="type_X" --><option value="X" selected="selected">Statistical</option><!-- TMPL_ELSE --><option value="X">Statistical</option><!-- /TMPL_IF -->
                                        </select>
index e77c51d..48ba766 100644 (file)
@@ -27,7 +27,7 @@
     <tr>
         <td>itemnum</td>
         <td><ul><li>The field itemnum MUST be mapped </li>
-            <li>The correspounding subfield MUST be in with -1 (ignore) tab</li></ul></td>
+            <li>The corresponding subfield MUST be in with -1 (ignore) tab</li></ul></td>
     </tr>
 <!-- TMPL_ELSE -->
     <tr>
@@ -67,7 +67,7 @@
         <td>itemtype NOT mapped</td>
         <td>the biblioitems.itemtype field MUST :<br />
             <ul><li>be mapped to a MARC subfield, </li>
-            <li>the correspounding subfield MUST have authorised_value=itemtype</li></ul></td>
+            <li>the corresponding subfield MUST have authorised_value=itemtype</li></ul></td>
     </tr>
 <!-- TMPL_ELSE -->
     <tr>
@@ -81,7 +81,7 @@
         <td>homebranch NOT mapped</td>
         <td>the items.homebranch field MUST :<br />
             <ul><li>be mapped to a MARC subfield,</li>
-            <li>the correspounding subfield MUST have authorised value=branches</li></ul></td>
+            <li>the corresponding subfield MUST have authorised value=branches</li></ul></td>
     </tr>
 <!-- TMPL_ELSE -->
     <tr>
@@ -95,7 +95,7 @@
         <td>holdingbranch NOT mapped</td>
         <td>the items.holdingbranch field MUST :<br />
             <ul><li>be mapped to a MARC subfield, </li>
-            <li>the correspounding subfield MUST have authorised value=branches</li></ul></td>
+            <li>the corresponding subfield MUST have authorised value=branches</li></ul></td>
     </tr>
 <!-- TMPL_ELSE -->
     <tr>
index e19e5e2..a95967d 100644 (file)
 <!-- TMPL_IF NAME="delete_confirm" -->
     <!-- TMPL_IF NAME="totalgtzero" -->
     <div class="dialog message">
-        <h3>Cannot Delete Currencey <span class="ex">'<!-- TMPL_VAR NAME="searchfield" -->'</span></h3>
+        <h3>Cannot Delete Currency <span class="ex">'<!-- TMPL_VAR NAME="searchfield" -->'</span></h3>
         <p>This currency is used <!-- TMPL_VAR NAME="total" --> times. Deletion not possible</p>
         <form action="<!-- TMPL_VAR NAME="script_name" -->" method="post">
             <input type="submit" value="OK" class="approve" />
index 3781398..0e4e0a0 100644 (file)
@@ -25,15 +25,15 @@ $(document).ready(function() {
                <div class="yui-b">
                        <h2>Keyword to MARC Mapping</h2>
                        <!-- TMPL_UNLESS NAME="fields" -->
-                       <div class="dialog message"><p>There are no mappings for this framework. </p></div>
+                       <div class="dialog message"><p>There are no mappings for the <!-- TMPL_IF NAME="frameworktext" --><em><!-- TMPL_VAR NAME="frameworktext" --></em><!-- TMPL_ELSE -->default<!-- /TMPL_IF --> framework. </p></div>
                        <!-- /TMPL_UNLESS -->
                        <form method="get" action="/cgi-bin/koha/admin/fieldmapping.pl" id="selectframework">
-                               <label for="framework">Framework :</label>
+                               <label for="framework">Framework:</label>
                                <select name="framework" id="framework" style="width:20em;">
                                        <option value="">Default</option>
                                <!-- TMPL_LOOP NAME="frameworkloop" -->
                                        <!-- TMPL_IF NAME="selected" -->
-                                       <option selected="selected" value="<!-- TMPL_VAR NAME='value' -->"><!--TMPL_VAR NAME='frameworktext' --></option>
+                                       <option selected="selected" value="<!-- TMPL_VAR NAME='value' -->"><!--TMPL_VAR NAME="frameworktext" --></option>
                                        <!-- TMPL_ELSE -->
                                        <option value="<!-- TMPL_VAR NAME="value" -->"><!--TMPL_VAR NAME="frameworktext" --></option>
                                        <!-- /TMPL_IF -->
@@ -59,7 +59,7 @@ $(document).ready(function() {
                        </form>
 
                                <!-- TMPL_IF NAME="fields" --><table>
-                                                               <caption>Mappings for this framework</caption>
+                                                               <caption>Mappings for the <!-- TMPL_IF NAME="frameworktext" --><em><!-- TMPL_VAR NAME="frameworktext" --></em><!-- TMPL_ELSE -->default<!-- /TMPL_IF --> framework</caption>
                                                                        <tr>
                                                                                <th>Field</th>
                                                                                <th>MARC Field</th>
index 4c34695..a36c4ee 100644 (file)
@@ -162,16 +162,16 @@ Item Types Administration
       <li>
           <label for="description">Description</label><input type="text" id="description" name="description" size="48" maxlength="80" value="<!-- TMPL_VAR name="description" escape="HTML" -->" />      </li>
      <!-- TMPL_IF NAME="noItemTypeImages" -->
-        <li><span class="label">Image: </span>Item type images are disabled. To enable them, turn off the <a href="/cgi-bin/koha/admin/systempreferences.pl?tab=all&searchfield=noItemTypeImages">noItemTypeImages system preference</a></li></ol>
+        <li><span class="label">Image: </span>Item type images are disabled. To enable them, turn off the <a href="/cgi-bin/koha/admin/systempreferences.pl?tab=all&amp;searchfield=noItemTypeImages">noItemTypeImages system preference</a></li></ol>
         <!-- TMPL_ELSE --></ol>
                <div id="icons" class="toptabs">
                <h5 style="margin-left:10px;">Choose an Icon:</h5>
                        <ul>
                                        <li><a href="/cgi-bin/koha/admin/itemtypes.pl#none">None</a></li>
                                  <!-- TMPL_LOOP NAME="imagesets" -->
-                                       <li><a href="/cgi-bin/koha/admin/itemtypes.pl#<!-- TMPL_VAR NAME="imagesetname" -->"><!-- TMPL_VAR name="imagesetname" --></a></li>
+            <!-- TMPL_IF NAME="imagesetactive" --><li class="ui-tabs-selected"><!-- TMPL_ELSE --><li><!-- /TMPL_IF --><a href="/cgi-bin/koha/admin/itemtypes.pl#<!-- TMPL_VAR NAME="imagesetname" -->"><!-- TMPL_VAR name="imagesetname" --></a></li>
                                  <!-- /TMPL_LOOP -->
-                                 <li><a href="/cgi-bin/koha/admin/itemtypes.pl#remote">Remote Image</a></li>
+                                 <!-- TMPL_IF NAME="remote_image" --><li class="ui-tabs-selected"><!-- TMPL_ELSE --><li><!-- /TMPL_IF --><a href="/cgi-bin/koha/admin/itemtypes.pl#remote">Remote Image</a></li>
                        </ul>
                </div>
   <div id="none"><ul>
index f36a264..591e6ca 100644 (file)
@@ -8,6 +8,10 @@ I18N/L10N:
               metric: dd/mm/yyyy
               iso: yyyy/mm/dd
         - .
+    -
+        - "Enable the following languages on the staff interface:"
+        - pref: language
+          type: staff-languages
     -
         - pref: opaclanguagesdisplay
           default: 0
@@ -15,3 +19,7 @@ I18N/L10N:
               yes: Allow
               no: "Don't allow"
         - patrons to change the language they see on the OPAC.
+    -
+        - "Enable the following languages on the OPAC:"
+        - pref: opaclanguages
+          type: opac-languages
index c844df4..2619d8c 100644 (file)
@@ -5,16 +5,6 @@ OPAC:
             - pref: opacthemes
               choices: opac-templates
             - theme on the OPAC.
-        -
-            - "Enable the following languages on the OPAC:"
-            - pref: opaclanguages
-              type: opac-languages
-        -
-            - pref: opaclanguagesdisplay
-              choices:
-                  yes: Allow
-                  no: "Don't allow"
-            - patrons to select their language on the OPAC.
         -
             - "The OPAC is located at http://"
             - pref: OPACBaseURL
index 4abe419..324f8af 100644 (file)
@@ -5,10 +5,6 @@ Staff Client:
             - pref: template
               choices: staff-templates
             - theme on the staff interface.
-        -
-            - "Enable the following languages on the staff interface:"
-            - pref: language
-              type: staff-languages
         -
             - "The staff client is located at http://"
             - pref: staffClientBaseURL
index 033c4d2..e5cc60d 100644 (file)
@@ -7,7 +7,7 @@ Hi,
 
 Here is your cart, sent from our online catalog.
 
-Please note that the attached file is a MARC biblographic records file
+Please note that the attached file is a MARC bibliographic records file
 which can be imported into a Personal Bibliographic Software like EndNote,
 Reference Manager or ProCite.
 <END_HEADER>
index 5615786..96110d8 100644 (file)
                        <!-- TMPL_IF name="f16c" -->
                         <option value="c" selected="selected">c- Comic strips</option>
                         <!-- TMPL_ELSE -->
-                        <option value="c">c- Comic stripts</option>
+                        <option value="c">c- Comic strips</option>
                         <!-- /TMPL_IF -->
                        
                         <!-- TMPL_IF name="f16d" -->
 
                         <!-- TMPL_IF name="f17c" -->
                         <option value="c" selected="selected">c- Collective biography</option>                              <!-- TMPL_ELSE -->
-                        <option value="c">c- Collective biographyl</option>
+                        <option value="c">c- Collective biography</option>
                         <!-- /TMPL_IF -->
                        
                         <!-- TMPL_IF name="f17d" -->
index 5d926ed..9dddccb 100644 (file)
                </td>
        </tr>
        <tr>
-               <td><label for="f710">7-10 Date1 / Begininning date of publication</label> </td>
+               <td><label for="f710">7-10 Date1 / Beginning date of publication</label> </td>
                <td>
                        <input type="text" name="f710" id="f710" size="4" maxlength="4" value="<!-- TMPL_VAR NAME="f710" -->"/>
                </td>
                        <!-- TMPL_IF name="f33c" -->
                         <option value="c" selected="selected">c- Comic strips</option>
                         <!-- TMPL_ELSE -->
-                        <option value="c">c- Comic stripts</option>
+                        <option value="c">c- Comic strips</option>
                         <!-- /TMPL_IF -->
                        
                         <!-- TMPL_IF name="f33d" -->
index e031214..48aafb5 100644 (file)
@@ -454,7 +454,7 @@ level)</option>
              <!-- TMPL_IF name="f1207" -->
                 <option value="07" selected="selected">07- ISO 10586 (Georgian set)</option>
             <!-- TMPL_ELSE -->
-                <option value="07">07- ISO ISO 10586 (Georgian set)</option>
+                <option value="07">07- ISO 10586 (Georgian set)</option>
             <!-- /TMPL_IF -->
 
              <!-- TMPL_IF name="f1208" -->
@@ -535,7 +535,7 @@ languages and obsolete typography)
            <!-- TMPL_IF name="f1307" -->
                 <option value="07" selected="selected">07- ISO 10586 (Georgian set)</option>
             <!-- TMPL_ELSE -->
-                <option value="07">07- ISO ISO 10586 (Georgian set)</option>
+                <option value="07">07- ISO 10586 (Georgian set)</option>
             <!-- /TMPL_IF -->
 
              <!-- TMPL_IF name="f1308" -->
index 55859c7..f0b11f8 100644 (file)
@@ -38,18 +38,19 @@ $(document).ready(function(){
     }); 
         /* Inline edit/delete links */
         $("td").click(function(event){
+            var $tgt = $(event.target);
             $(".linktools").hide();
             $("tr").removeClass("selected");
+            if($tgt.is("a")||$tgt.is(":nth-child(7)")||$tgt.is(":nth-child(8)")||$tgt.is(":nth-child(9)")||$tgt.is(":nth-child(10)")){
+                return true;
+            } else {
+                var position = $(this).offset();
+                var top = position.top+5;
+                var left = position.left+5;
+                $(".linktools",row).show().css("position","absolute").css("top",top).css("left",left);
+            }
             var row = $(this).parent();
             row.addClass("selected");
-
-            var $tgt = $(event.target);
-            if($tgt.is("a")||$tgt.is(":nth-child(7)")||$tgt.is(":nth-child(8)")||$tgt.is(":nth-child(9)")||$tgt.is(":nth-child(10)")){ return true; } else {
-            var position = $(this).offset();
-            var top = position.top+5;
-            var left = position.left+5;
-            $(".linktools",row).show().css("position","absolute").css("top",top).css("left",left);
-            }
         });
 });
 
index a06bd5e..c751c5f 100644 (file)
     <!-- TMPL_IF Name="trsfitemloop" -->
         <div class="yui-g">
                <table>
-            <caption>Transfered Items</caption>
+            <caption>Transferred Items</caption>
             <tr>
                 <th>Bar Code</th>
                 <th>Title</th>
index 980d195..0b4ac29 100644 (file)
@@ -843,7 +843,7 @@ No patron matched <span class="ex"><!-- TMPL_VAR name="message" --></span>
                         <!-- TMPL_IF name="transfered" --> <strong>in transit</strong> from
                         <!-- TMPL_VAR NAME="frombranch" --> since <!-- TMPL_VAR NAME="datesent" -->
                         <!-- /TMPL_IF -->
-                        <!-- TMPL_IF name="nottransfered" --> hasn't been transfered yet from <!-- TMPL_VAR NAME="nottransferedby" --></i>
+                        <!-- TMPL_IF name="nottransfered" --> hasn't been transferred yet from <!-- TMPL_VAR NAME="nottransferedby" --></i>
                         <!-- /TMPL_IF --></em></td>
                     <td>
                         <!-- TMPL_IF NAME="waitingposition" --><b> <!-- TMPL_VAR NAME="waitingposition" --> </b><!-- /TMPL_IF -->
index 7b5ea18..ca95bd3 100644 (file)
@@ -1,5 +1,5 @@
 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
-<title>Koha &rsaquo; Circulation &rsaquo; Pending Holds</title>
+<title>Koha &rsaquo; Circulation &rsaquo; Holds to Pull</title>
 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
 <!-- Additions to enable Calendar system -->
 <link rel="stylesheet" type="text/css" href="<!-- TMPL_VAR name="themelang" -->/lib/calendar/calendar-system.css" />
@@ -34,7 +34,7 @@ $.tablesorter.addParser({
 <!-- TMPL_INCLUDE NAME="circ-search.inc" -->
 
 
-<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a> &rsaquo; Pending Holds</div>
+<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a> &rsaquo; Holds to Pull</div>
 
 <div id="doc3" class="yui-t2">
    
@@ -42,7 +42,7 @@ $.tablesorter.addParser({
        <div id="yui-main">
        <div class="yui-b">
 
-<h2>Pending holds<!-- TMPL_IF NAME="run_report" --> placed between <!-- TMPL_VAR NAME="from" --> and <!-- TMPL_VAR NAME="to" --><!-- /TMPL_IF --></h2>
+<h2>Holds to Pull<!-- TMPL_IF NAME="run_report" --> placed between <!-- TMPL_VAR NAME="from" --> and <!-- TMPL_VAR NAME="to" --><!-- /TMPL_IF --></h2>
 <!-- TMPL_IF NAME="run_report" -->
 <h3>Reported on <!-- TMPL_VAR NAME="todaysdate" --></h3>
 <p>The following holds have not been filled. Please retrieve them and check them in.</p>
index 71934c9..ba8d117 100644 (file)
@@ -175,7 +175,7 @@ function Dopop(link) {
 
     <!-- TMPL_IF Name="needstransfer" -->
        <!-- needstransfer -->
-       <div class="dialog message"><h3> This item needs to be transfered to <!-- TMPL_VAR Name="homebranchname" --></h3>
+       <div class="dialog message"><h3> This item needs to be transferred to <!-- TMPL_VAR Name="homebranchname" --></h3>
        Transfer Now?<br />
     <form method="post" action="returns.pl" name="mainform" id="mainform">
        <input type="submit" name="dotransfer" value="Yes" class="submit" />
index bbb5dfb..63b9e26 100644 (file)
@@ -46,7 +46,7 @@ $.tablesorter.addParser({
         </h2>
         <!-- TMPL_IF NAME="messagetransfert" -->
             <div>
-                <h2>Hold find for (<!-- TMPL_VAR NAME="nextreservtitle" -->) must transfered</h2>
+                <h2>Hold find for (<!-- TMPL_VAR NAME="nextreservtitle" -->), must be transferred</h2>
                 <p>This hold placed by : <b> <!-- TMPL_VAR NAME="nextreservsurname" --> <!-- TMPL_VAR NAME="nextreservfirstname" --></b> at the library : <b> <!-- TMPL_VAR NAME="branchname" --> </b>, Please transfer this hold.
                 </p>
                 <form name="cancelReservewithtransfert" action="waitingreserves.pl" method="post">
index ecf8b8f..18f8d0d 100644 (file)
@@ -4,6 +4,7 @@
 
 <p>Using the Order Search you can search for items that have been ordered with or without the vendor.</p>
 
-<p>You can enter info in one or both fields and and you can enter any part of the title and/or vendor name.</p>
+<p>You can enter info in one or both fields and you can enter any part of the title and/or vendor name.</p>
        
-<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
+
index b2ff5c9..85af6a9 100644 (file)
@@ -3,16 +3,16 @@
 <h1>Order Details Help</h1>
 
 <h2>What is the &quot;Vendor Price&quot;?</h2>
-<p>The vendor price is the price given to you by the vendor, sometimes called the &quot;List Price&quot;. Depdending on how the Vendor is setup this may or maynot include any discount given to you by the vendor and/or any sales tax. See Vendors for more information.</p>
+<p>The vendor price is the price given to you by the vendor, sometimes called the &quot;List Price&quot;. Depending on how the Vendor is setup this may or maynot include any discount given to you by the vendor and/or any sales tax. See Vendors for more information.</p>
 
 <h2>What is the &quot;Replacement Price&quot;?</h2>
 <p>The replacement price is the total cost of what it would cost to replace the item if you had to purchase the item retail at recommended retail. This is the amount that a patron could be charged if item is lost or damaged beyond repair.</p>
 
 <h2>What is the &quot;Budgeted Price&quot;?</h2>
-<p>This is the price you expect to pay for the item, including any discount and any relevant sales tax (depending on the vendor setup) and is the amount that will be charged to your <strong>Commited budget</strong>.</p>
+<p>This is the price you expect to pay for the item, including any discount and any relevant sales tax (depending on the vendor setup) and is the amount that will be charged to your <strong>Committed budget</strong>.</p>
 
 <h2>What is the &quot;Actual Price&quot;?</h2>
-<p>This is the price that shows on the invoice or packing slip when you receive the item. When placing an order, Koha will automatically calculate this for you. When an item is received, this can be over keyed with the actual value. This is to take into account any slight differences in rounding or price flutucations between ordering the item and actually recieving it.</p>
+<p>This is the price that shows on the invoice or packing slip when you receive the item. When placing an order, Koha will automatically calculate this for you. When an item is received, this can be over keyed with the actual value. This is to take into account any slight differences in rounding or price fluctuations between ordering the item and actually recieving it.</p>
 <p>The Actual price is what is committed to your <strong>Spent budget</strong>.</p>    
 
-<!-- TMPL_INCLUDE name="help-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE name="help-bottom.inc" -->
index 4a44bd4..00bd787 100644 (file)
@@ -2,7 +2,7 @@
 
 <h1>Cataloging Help</h1><h2>How to edit a bibliographic record?</h2>
 
-<p>To edit a bibliographic record, use the cataloging search to find the record. This can be done either via the cataloging interface or the catalog search. A search with in the Cataloging module will search the catalog and the reservior (see below).</p>
+<p>To edit a bibliographic record, use the cataloging search to find the record. This can be done either via the cataloging interface or the catalog search. A search with in the Cataloging module will search the catalog and the reservoir (see below).</p>
 
 <h2>How to add a new bibliographic record?</h2>
 
@@ -10,7 +10,8 @@
 
 <h2>How to add new items to a record?</h2>
 
-<p>A bibliographic record needs items or holdings for it to show in the OPAC. There are two ways to add new items to a bibliographic record:</p><ol><li><strong>Through Cataloging</strong>. After adding the new bibliographic record, you will be given the option to add items the record. One record can have many items. </li><li><strong>Through Acquisitions</strong>.&nbsp; Items can be added to orders in acquisitions. Item details are added upon recieving the item. Using the acquisitions module for adding items allows you to track the libraries spend against funds and budgets. </li></ol><h2>What is the reservoir?</h2>
+<p>A bibliographic record needs items or holdings for it to show in the OPAC. There are two ways to add new items to a bibliographic record:</p><ol><li><strong>Through Cataloging</strong>. After adding the new bibliographic record, you will be given the option to add items to the record. One record can have many items. </li><li><strong>Through Acquisitions</strong>.&nbsp; Items can be added to orders in acquisitions. Item details are added upon receiving the item. Using the acquisitions module for adding items allows you to track the libraries spend against funds and budgets. </li></ol><h2>What is the reservoir?</h2>
 
 <p>The reservoir is a holding area for bibilographic records that are not yet used in the library catalog.&nbsp; When an item arrives that matches a record in the reservoir, the two can be matched and the bibliographic pulled from the reservoir into the main catalog.</p><p>The reservoir can be populated with MARC records through the &quot;Stage MARC Records for Import&quot; under Tools.</p> 
-<!-- TMPL_INCLUDE name="help-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE name="help-bottom.inc" -->
+
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/help/cataloguing/merge.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/help/cataloguing/merge.tmpl
new file mode 100644 (file)
index 0000000..aba4e22
--- /dev/null
@@ -0,0 +1,23 @@
+<!-- TMPL_INCLUDE NAME="help-top.inc" -->
+
+<h1>Merging Items</h1>
+
+<p style="color: rgb(153, 0, 0);">Important: Merging will only work with two bibliographic records that use the same bibliographic framework.</p>
+
+<p>The easiest way to merge together duplicate bibliographic records is to add them to a list and use the Merge Tool from there.</p>
+
+<p>From the list, check the two bibliographic records you want to merge. If you choose more than or fewer than 2, you will be presented with an error.</p>
+
+<p>Once you have selected the records you want to merge, click the 'Merge selected records' button. You will be asked which of the two records you would like to keep as your primary record and which will be deleted after the merge.</p>
+
+<p>You will be presented with the MARC for both of the records (each accessible by tabs labeled with the bib numbers for those records). By default the entire first record will be selected, uncheck the fields you don't want in the final (destination) record and then move on to the second tab to choose which fields should be in the final (destination) record.</p>
+
+<p>Should you try to add a field that is not repeatable two times (like choosing the 245 field from both record #1 and #2) you will be presented with an error</p>
+
+<p>Most importantly you want to make sure that all of the items from the two records are attached to the new record. To do this you want to make sure that all 952 files are selected before completing the merge.</p>
+
+<p>Once you have completed your selections click the 'merge' button. The primary record will now show the data you chose for it, and the second record will be deleted.</p>
+
+<p style="color: rgb(153, 0, 0);">Important: It is important to rebuild your zebra index immediately after merging records. If a search is performed for a record which has been deleted Koha will present the patrons with an error in the OPAC.</p>
+
+<!-- TMPL_INCLUDE name="help-bottom.inc" -->
index 61f9f42..855a0a1 100644 (file)
@@ -3,17 +3,17 @@
 
 <p>If this is your first time logging into Koha, you should now got to Koha Administration and setup all system parameters, especially Patron Categories.</p>
 
-<p>Once you have&nbsp; set up patron categories, you should create a new user in &quot;Patrons&quot; with super librarian privileges. Then use that user to log in rather than the root user set up as part of installation.</p>
+<p>Once you have set up patron categories, you should create a new user in &quot;Patrons&quot; with super librarian privileges. Then use that user to log in rather than the root user set up as part of installation.</p>
 
 <p>Here are some other suggestions: </p>
 
 <ul>
 <li><a href="http://koha-community.org/documentation/">Read Koha Documentation</a></li>
 <li><a href="http://wiki.koha-community.org">Read/Write to the Koha Wiki</a></li>
-<li><a href="http://koha-community.org/support/">Read and Contribute to Discussions</a></li>
+<li><a href="http://koha-community.org/support/koha-mailing-lists/">Read and Contribute to Discussions</a></li>
 <li><a href="http://bugs.koha-community.org">Report Koha Bugs</a></li>
 <li><a href="http://wiki.koha-community.org/wiki/Version_Control_Using_Git">Submit Patches to Koha using Git (Version Control System)</a></li>
-<li><a href="http://koha-community.org/support/">Chat with Koha users and developers</a></li>
+<li><a href="http://koha-community.org/get-involved/irc/">Chat with Koha users and developers</a></li>
 </ul>
 
 <h2>Can I edit the online help? </h2>
@@ -26,4 +26,4 @@
 
 <p>The online help directory is: <pre>&nbsp;/koha-tmpl/intranet-tmpl/prog/en/modules/help</pre></p>
 
-<!-- TMPL_INCLUDE name="help-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE name="help-bottom.inc" -->
index c16b139..dc00acf 100644 (file)
@@ -2,7 +2,7 @@
 
 <h1>Change Patron Password</h1>
 
-<p>Koha cannot display existing passwords, so this form can only be used to change a patron's username and/or password, but not to recover an exisiting password.</p>
+<p>Koha cannot display existing passwords, so this form can only be used to change a patron's username and/or password, but not to recover an existing password.</p>
                <div class="hint">      The default minimum password length is 3 characters long.  To change this value, update your system preferences.
                </div>
                <div class="hint">
@@ -11,4 +11,5 @@
                        </ul>
                </div>
 
-<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
+
index 3a607aa..13cba5b 100644 (file)
 <p>Using the form that appears you can define the template for your sheet of labels or cards.</p>
 
 <ul>
-<li>Template ID will be automatically generated after saving your template, this is simply a system genereated unique id</li>
+<li>Template ID will be automatically generated after saving your template, this is simply a system generated unique id</li>
 <li>Template Code should be something you can use to identify your template on a list of templates</li>
 <li>You can use the Template Description to add additional information about the template</li>
 <li>The Units pull down is used to define what measurement scale you're going to be using for the template. This should probably match the unit of measurement used on the template description provided by the product vendor.</li>
 <li>The measurements can be found on the vendor product packaging or website.</li>
 <li>A profile is a set of “adjustments” applied to a given template just prior to printing which compensates for anomalies unique and peculiar to a given printer (to which the profile is assigned).
 <ul><li>Before picking a profile try printing some sample cards so that you can easily define a profile that is right for your printer/template combination.</li>
-<li>After finding any anomolies in the printed document, create a profile and assign it to the template.</li></ul></li></ul>
+<li>After finding any anomalies in the printed document, create a profile and assign it to the template.</li></ul></li></ul>
 
 <p>After saving, your templates will appear on the 'Manage Templates' page.</p>
 
-<!-- TMPL_INCLUDE name="help-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE name="help-bottom.inc" -->
+
index df2b000..cd28653 100644 (file)
                        <li>Options without radio buttons such as 'Patron status', 'Patron activity', and 'Date of Birth' are limits you can place on the report.</li>
                        <li style="background-color: #ffe599">
 TIP: To place no limits for a category, choose the blank field. When blank field is chosen all categories will be included in the statistical count.</li>
-                       <li>Choose a method for 'outputing' (viewing) the report: Options are 'browser' or saving as a file viewable in a program like Excel.</li>
+                       <li>Choose a method for 'outputting' (viewing) the report: Options are 'browser' or saving as a file viewable in a program like Excel.</li>
                        <li>Click 'Submit'</li>
-                       <li>For each patron category (rows), there is a count given by branch. Each row and and columns are also totaled</li>
+                       <li>For each patron category (rows), there is a count given by branch. Each row and columns are also totaled</li>
                </ul>
-       </div>  <!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
\ No newline at end of file
+       </div>
+
+<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
+
index 4fc356c..b94254c 100644 (file)
@@ -19,6 +19,9 @@
                </ul></li>
        </ul>
        <ul>
-               <li>Choose a method for 'outputing' (viewing) the report: Options are 'browser' or saving as a file viewable in a program like Excel.</li>
+               <li>Choose a method for 'outputting' (viewing) the report: Options are 'browser' or saving as a file viewable in a program like Excel.</li>
                <li>Click 'Submit'</li>
-       </ul><!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
\ No newline at end of file
+       </ul>
+
+<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
+
index d664b20..b2c0c98 100644 (file)
@@ -6,8 +6,9 @@
  
 <p>Koha comes with a number of predefined (or &quot;canned&quot;) reports, along with two report builder engines.</p>
 <p><strong>Pre-defined Reports</strong></p>
-<p>There are number of predefined reports in Koha. Check the the Circulation module for additional Circulation specific reports.</p>
+<p>There are number of predefined reports in Koha. Check the Circulation module for additional Circulation specific reports.</p>
 <p><strong>Statistics Wizards</strong></p>
 <p>The statistics wizards provide a way to build simple reports for each module. The reports produced can either be viewed on screen or downloaded for opening in a spreadsheet program or text editor.</p>
 <p><strong>Guided Reports Wizard</strong></p>
-<p>The Guided Reports Wizard helps you build reports using all the fields in the database for each module. The reports can then be saved and run using the scheduler. </p><!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
\ No newline at end of file
+<p>The Guided Reports Wizard helps you build reports using all the fields in the database for each module. The reports can then be saved and run using the scheduler. </p><!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
+
index 71b068f..c239d83 100644 (file)
@@ -4,6 +4,7 @@
 
 <p>The serials module assists in managing your serial subscriptions (journals, magazines, and newspapers).</p>
 
-<p>You can search for exisiting subscriptions by using the search box at the top of the page. You can search for any part of the serial title or ISSN. </p>
+<p>You can search for existing subscriptions by using the search box at the top of the page. You can search for any part of the serial title or ISSN. </p>
+
+<!-- TMPL_INCLUDE name="help-bottom.inc" -->
 
-<!-- TMPL_INCLUDE name="help-bottom.inc" -->
\ No newline at end of file
index 1bccbbf..198daef 100644 (file)
 <li>If no values are entered in these fields, they will use the OPACSerialIssueDisplayCount and StaffSerialIssueDisplayCount system preference values</li>
 
        </ul>
-<li>In 'First issue publication' you want to enter the the date of the issue you have in your hand, the date from which the prediction pattern will start</li>
+<li>In 'First issue publication' you want to enter the date of the issue you have in your hand, the date from which the prediction pattern will start</li>
 <li>There are several pre-defined options for the 'Frequency' of publication</li>
 <ul>
-<li>Without periodicy: some very specific (usually high level science journals) don't have a true periodicity. When you subscribe to the title, you subscribe for 6 issues, which can arrive in 1 year... or 2... There is no regularity or known schedule.</li>
+<li>Without periodicity: some very specific (usually high level science journals) don't have a true periodicity. When you subscribe to the title, you subscribe for 6 issues, which can arrive in 1 year... or 2... There is no regularity or known schedule.</li>
 <li>Unknown select this if none of the other choices are relevant</li>
 <li>Irregular: The journal is not "regular" but has a periodicity. You know that it comes out on January, then in October and December, it is irregular, but you know when it's going to arrive.</li>
 <li>2/day: Twice daily</li>
@@ -56,7 +56,7 @@
 <li>1/month: Monthly</li>
 <li>1/ 2 months (6/year): Bi-monthly</li>
 <li>1/ 3 months (1/quarter): Quarterly</li>
-<li>1/quarter (seasonal) : Quarterly related to seasons (ie. Summer, Autumn, Winter, Spring)</li>
+<li>1/quarter (seasonal) : Quarterly related to seasons (i.e. Summer, Autumn, Winter, Spring)</li>
 <li>2/year: Half yearly</li>
 <li>1/year: Annual</li>
 <li>1/ 2 years: Bi-annual</li>
@@ -77,4 +77,5 @@
 
 
 
-<!-- TMPL_INCLUDE name="help-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE name="help-bottom.inc" -->
+
index b0c6dc7..9089b01 100644 (file)
@@ -30,7 +30,7 @@ To manage suggestions, go to More &gt; Acquisitions
        <li style="color: #990000">IMPORTANT: You need to have authorized values for 'Reason' already set before working with suggestions</li>
        <ul>
                <li style="background-color: #ffe599">TIP: Reasons are the librarian's reason for accepting/rejecting request</li>
-               <li>If reasons are not set the Suggestions page will will look like this:<br />
+               <li>If reasons are not set the Suggestions page will look like this:<br />
                </li>
                <li>If you get this error, click 'authorized values'
                <ul>
@@ -61,4 +61,5 @@ To manage suggestions, go to More &gt; Acquisitions
        <li>If you accidentally pick the wrong option (accept or reject) you can always edit your selection by visiting the appropriate tab</li>
 </ul>
 
-<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
+
index fc472bf..cdee0ff 100644 (file)
@@ -26,7 +26,7 @@
             below the calendar</p></li></ul>
             <h3>Editing Events</h3><p>To edit events</p><ul class="itemizedlist" type="disc"><li class="listitem"><p>Click on the event on the calendar that you want to change
             (do this by clicking on the date on the calendar, not the event
-            listed in the summary)</p></li><li class="listitem"><p>From this form you can make edits to the holiday or deleete
+            listed in the summary)</p></li><li class="listitem"><p>From this form you can make edits to the holiday or delete
             the holiday completely. Both actions require that you click 'Save'
             before the change will be made.</p></li><li class="listitem"><p>Clicking on repeatable events will offer slightly different
             options</p>
@@ -56,10 +56,11 @@ You can make use of the Holidays Calendar by turning on the proper system prefer
         <ul> <li>This will use the check the holiday calendar before charging fines</li></ul>
 </ul>
  
-<p><strong>How is the dropbox date is determined?</strong></p>
+<p><strong>How is the dropbox date determined?</strong></p>
 
 <p>Is it the last open date for the checkout branch? Is it today's date minus one? Can the dropbox checkin date be set? If the library is closed for four days for repairs, for example, there would be more than one day needed for the dropbox date.</p>
 
 <p>You will only have one dropbox date and that will be the last day that the library open (determined by the holiday calendar) because there is no real way to know what day the books were dropped into the box during the 4 closed days. The only way to change the effective checkin date in dropbox mode is to modify the calendar.</p>
 
-<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
+
index e7d4c46..90cd7e0 100644 (file)
@@ -12,7 +12,7 @@
 <li>Click 'Import into catalog' to complete the import</li>
 <li>Once your import is complete a link to the new bib records will appear to the right of each title that was imported</li>
 <li>You can also undo your import by clicking the 'Undo import into catalog' button</li>
-<li>Records imported using this tool remain in the 'reservior' until they are cleaned. These items will appear when searching the catalog from the Cataloging tool.</li></ul>
+<li>Records imported using this tool remain in the 'reservoir' until they are cleaned. These items will appear when searching the catalog from the Cataloging tool.</li></ul>
 
 <p>To clean items out of the 'reservoir':</p>
 
@@ -23,4 +23,5 @@
 <li>This action cannot be undone, so make sure you confirm that you are cleaning the correct import</li></ul>
 
        
-<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
+
index 2910c73..c7af03a 100644 (file)
@@ -8,7 +8,7 @@
 
 <p>In order to have overdue notices sent to your patrons, you need to set that patron category to require overdue notices.</p>
 
-<p>The Overdue Notice/Status Triggers tool gives the librarian the power to send up to three notices to each patron type notifiying them of overdue items</p>
+<p>The Overdue Notice/Status Triggers tool gives the librarian the power to send up to three notices to each patron type notifying them of overdue items</p>
 
 <ul><li>Delay is the number of days after an issue is due before an action is triggered.</li>
 <ul><li style="color:#990000;"><strong>Important: These rules should not be used for Advanced Notices.  Advanced Notices should be set using the Enhanched Messaging Preferences on the Patron Profile.</strong></li>
@@ -40,4 +40,5 @@
 
 <p>Sincerely, Library Staff</p>
 
-<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE NAME="help-bottom.inc" -->
+
index 0efeb34..846f32e 100644 (file)
@@ -8,7 +8,6 @@
 <form name="f" method="post">
        <input type="hidden" name="op" value="do_search" />
        <input type="hidden" name="type" value="intranet" />
-       <input type="hidden" name="nbstatements" value="<!-- TMPL_VAR NAME="nbstatements" -->" />
        <div class="details">
                <h2>Search on</h2>
                <p>
@@ -32,4 +31,4 @@
 </form>
 </div>
 
-<!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->
index df1f556..7ca0d02 100644 (file)
@@ -1,9 +1,26 @@
+    <!-- PLEASE MAINTAIN PROPER INDENTATION!!!!  -->
     <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
     <title>Koha &rsaquo; Tools &rsaquo; Labels &rsaquo; Manage Label Batches</title>
     <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
     <!-- TMPL_INCLUDE NAME="greybox.inc" -->
+    <script type="text/javascript">
+    //<![CDATA[
+        function dofocus() {    // named function req'd for body onload event by some FF and IE7 security models
+            $(".focus:last").select();
+        }
+        function verifyBarcodes(barcodes) {
+            if (barcodes.value == '') {
+                alert("Please add barcodes using either the direct entry text area or the item search.");
+                return false;   // not ok
+            }
+            else {
+                return true;    // ok
+            };
+        }
+    //]]>
+    </script>
 </head>
-<body>
+<body onload="dofocus();">
     <!-- TMPL_INCLUDE NAME="header.inc" -->
     <!-- TMPL_INCLUDE NAME="cat-search.inc" -->
     <div id="breadcrumbs">
                     <div class="yui-g">
                         <div class="yui-u first" id="manage-label-batches">
                             <div class="hint">Current Branch: <!-- TMPL_VAR NAME="LoginBranchname" --></div>
+                            <form name="add_by_barcode" action="/cgi-bin/koha/labels/label-edit-batch.pl" method="post">
+                                <div>
+                                    <fieldset class="rows" style="border-bottom: 0px; border: 0px;">
+                                    <ol><li>
+                                    <input type="hidden" name="op" value="add" \>
+                                    <input type="hidden" name="batch_id" value="<!-- TMPL_VAR NAME="batch_id" -->" \>
+                                    <label for="barcode">Add by Barcode(s): 
+                                        <br \> <span class="hint">One barcode per line.</span>
+                                        <br \> <span class="hint">Leave empty to add via item search.</span>
+                                    </label>
+                                    <textarea rows="5" id="barcode" name="barcode" tabindex="1" class="focus"></textarea>
+                                    </li></ol>
+                                    </fieldset>
+                                </div>
+                            </form>
                                 <!-- TMPL_IF NAME="table_loop" -->
                                 <form name="items" class="checkboxed">
                                     <h2>Items in batch number <!-- TMPL_VAR NAME="batch_id" --></h2>
                                     </table>
                                 </form>
                                 <!-- TMPL_ELSE -->
-                                    <div class="dialog message"><h4>There are no items in Batch <!-- TMPL_VAR NAME="batch_id" --> yet</h4>
-                                    <p>Use the toolbar above to add items.</p></div>
+                                <fieldset class="rows" style="border-bottom: 0px; border: 0px;">
+                                <ol><li>
+                                    <div class="dialog message">
+                                        <h4>There are no items in Batch <!-- TMPL_VAR NAME="batch_id" --> yet</h4>
+                                        <p>Add items by barcode using the text area above or leave empty to add via item search.</p>
+                                    </div>
+                                </li></ol>
+                                </fieldset>
                                 <!-- /TMPL_IF -->
                             </div>
                             <!-- TMPL_IF NAME="err" -->
index 815e5d1..9597776 100644 (file)
@@ -60,7 +60,7 @@ is now <!-- TMPL_VAR NAME="sub" ESCAPE="HTML" -->
 
 
 <!-- TMPL_IF NAME="finun-p" -->
-<h3>Succesfully undeleted</h3>
+<h3>Successfully undeleted</h3>
 <p><a href="/cgi-bin/koha/maint/catmaintain.pl">Back to Catalog Maintenance</a></p>
 <!-- /TMPL_IF -->
 
@@ -118,4 +118,5 @@ is now <!-- TMPL_VAR NAME="sub" ESCAPE="HTML" -->
 </div>
 
 <!-- TMPL_INCLUDE NAME="mainmenu.inc" -->
-<!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->
+
index b21d35a..50a7bb1 100644 (file)
@@ -46,6 +46,8 @@
         $("select", clone).attr('name', function() {
             return this.name.replace(/patron_attr_\d+/, 'patron_attr_' + newId);
         });
+        $("input#patron_attr_" + newId, clone).attr('value','');
+        $("select#patron_attr_" + newId, clone).attr('value','');
         original.parentNode.insertBefore(clone, original.nextSibling);
     }
 
         <!-- /TMPL_LOOP -->
                </select>
     <!-- TMPL_ELSE -->
-        <span class="problem">There is no category type to add <!--TMPL_IF Name="A"-->an Adult<!--/TMPL_IF--><!--TMPL_IF Name="C"-->a Child<!--/TMPL_IF--><!--TMPL_IF Name="I"-->an Institution<!--/TMPL_IF--><!--TMPL_IF Name="P"-->a professionnal<!--/TMPL_IF--><!--TMPL_IF Name="S"-->a Staff Member<!--/TMPL_IF-->.</span>
+        <span class="problem">There is no category type to add <!--TMPL_IF Name="A"-->an Adult<!--/TMPL_IF--><!--TMPL_IF Name="C"-->a Child<!--/TMPL_IF--><!--TMPL_IF Name="I"-->an Institution<!--/TMPL_IF--><!--TMPL_IF Name="P"-->a Professional<!--/TMPL_IF--><!--TMPL_IF Name="S"-->a Staff Member<!--/TMPL_IF-->.</span>
               <a href="/cgi-bin/koha/admin/categorie.pl">Please create one</a>
     <!-- /TMPL_IF -->
     </li>
 </div><!-- /TMPL_UNLESS -->
 </div>
 <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->
+
index a63e15d..83bd151 100644 (file)
@@ -14,7 +14,8 @@
 
 <h3><!-- TMPL_VAR name="LibraryName" --></h3>
 <!-- TMPL_IF NAME="branchname" --><!-- TMPL_VAR NAME="branchname" --><br /><!-- /TMPL_IF -->
-Checked out to <a href="/cgi-bin/koha/circ/circulation.pl?findborrower=<!-- TMPL_VAR NAME="cardnumber">"><!-- TMPL_VAR NAME="cardnumber" --></a><br />
+Checked out to <!-- TMPL_VAR NAME="firstname" --> <!-- TMPL_VAR NAME="surname" --> <br />
+(<a href="/cgi-bin/koha/circ/circulation.pl?findborrower=<!-- TMPL_VAR NAME="cardnumber">"><!-- TMPL_VAR NAME="cardnumber" --></a>)<br />
 
 <!-- TMPL_VAR NAME="todaysdate" --><br />
 
index dfad6ee..5f3bbba 100644 (file)
@@ -539,7 +539,7 @@ if (nodename =="barcodes[]"){
                 <!-- /TMPL_IF -->
 
                 <!-- TMPL_IF name="nottransfered" -->
-                <em>Item hasn't been transfered yet from <!-- TMPL_VAR NAME="nottransferedby" --></em>
+                <em>Item hasn't been transferred yet from <!-- TMPL_VAR NAME="nottransferedby" --></em>
                 <!-- /TMPL_IF -->
                 <!-- TMPL_IF name="barcodereserv" -->
                 <a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->"><!-- TMPL_VAR NAME="barcodereserv" --></a>
index 7a24859..52f1051 100644 (file)
@@ -50,9 +50,9 @@ $(document).ready(function(){
 &rsaquo; <a href="/cgi-bin/koha/reports/reports-home.pl">Reports</a>
 &rsaquo; <a href="/cgi-bin/koha/reports/guided_reports.pl">Guided Reports Wizard</a>
 &rsaquo; 
-<!-- TMPL_IF NAME="saved1"  --><strong>Saved Reports</strong>
-<!-- TMPL_ELSIF NAME="create"  --><strong>Create from SQL</strong>
-<!-- TMPL_ELSIF NAME="showsql" --><a href="/cgi-bin/koha/reports/guided_reports.pl?phase=Use%20saved">Saved Reports</a> &rsaquo; <strong>SQL View</strong>
+<!-- TMPL_IF NAME="saved1"  -->Saved Reports
+<!-- TMPL_ELSIF NAME="create"  -->Create from SQL
+<!-- TMPL_ELSIF NAME="showsql" --><a href="/cgi-bin/koha/reports/guided_reports.pl?phase=Use%20saved">Saved Reports</a> &rsaquo; SQL View
 <!-- TMPL_ELSIF NAME="execute" --><a href="/cgi-bin/koha/reports/guided_reports.pl?phase=Use%20saved">Saved Reports</a> &rsaquo; <em><!-- TMPL_VAR NAME="name" --></em> Report
 <!-- TMPL_ELSIF NAME="buildx"  --><a href="/cgi-bin/koha/reports/guided_reports.pl?phase=Build%20new">Build A Report</a> &rsaquo; Step <!-- TMPL_VAR NAME="buildx" --> of 6:
     <!-- TMPL_IF    NAME="build1" -->Choose a Module
index 67baf2d..f70d764 100644 (file)
@@ -639,7 +639,7 @@ function checkMultiHold() {
                 Waiting to be pulled
             <!-- /TMPL_IF -->
           <!-- TMPL_ELSE -->
-            Item being transfered to <b> <!-- TMPL_VAR NAME="wbrname" --></b> <input type="hidden" name="pickup" value="<!-- TMPL_VAR NAME="wbrcode" -->" />
+            Item being transferred to <b> <!-- TMPL_VAR NAME="wbrname" --></b> <input type="hidden" name="pickup" value="<!-- TMPL_VAR NAME="wbrcode" -->" />
          <!-- /TMPL_IF -->
     <!-- TMPL_ELSE -->
           <select name="pickup">
index 2cfa8b6..ae0277f 100644 (file)
@@ -18,7 +18,7 @@
           <br />
           <!-- TMPL_IF NAME="previousActionAdd" -->
             <!-- TMPL_IF NAME="addSuccess" -->
-              <div>Item with barcode '<!-- TMPL_VAR NAME="addedBarcode" -->' Added Succesfully!</div>
+              <div>Item with barcode '<!-- TMPL_VAR NAME="addedBarcode" -->' Added Successfully!</div>
             <!-- TMPL_ELSE -->
               <div>Failed to add item with barcode '<!-- TMPL_VAR NAME="addedBarcode" -->'!</div>
               <div>Reason: <strong><!-- TMPL_VAR NAME="failureMessage" --></strong></div>
@@ -27,7 +27,7 @@
 
           <!-- TMPL_IF NAME="previousActionRemove" -->
             <!-- TMPL_IF NAME="removeSuccess" -->
-              <div>Item with barcode '<!-- TMPL_VAR NAME="addedBarcode" -->' Removed Succesfully!</div>
+              <div>Item with barcode '<!-- TMPL_VAR NAME="addedBarcode" -->' Removed Successfully!</div>
             <!-- TMPL_ELSE -->
               <div>Failed to remove item with barcode '<!-- TMPL_VAR NAME="removedBarcode" -->'!</div>
               <div>Reason: <strong><!-- TMPL_VAR NAME="failureMessage" --></strong></div>
@@ -85,4 +85,5 @@
 
 </div>
 </div>
-<!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->
+
index 93055c7..6cc93d4 100644 (file)
@@ -16,7 +16,7 @@
 <!--
       <!-- TMPL_IF NAME="previousActionCreate" -->
         <!-- TMPL_IF NAME="createSuccess" -->
-          <div>Collection '<!-- TMPL_VAR NAME="createdTitle" -->' Created Succesfully!</div>
+          <div>Collection '<!-- TMPL_VAR NAME="createdTitle" -->' Created Successfully!</div>
         <!-- TMPL_ELSE -->
           <div>Collection '<!-- TMPL_VAR NAME="createdTitle" -->' Failed To Be Created!</div>
           <div>Reason: <strong><!-- TMPL_VAR NAME="failureMessage" --></strong></div>
@@ -25,7 +25,7 @@
 
       <!-- TMPL_IF NAME="previousActionDelete" -->
         <!-- TMPL_IF NAME="DeleteSuccess" -->
-          <div>Collection Deleted Succesfully!</div>
+          <div>Collection Deleted Successfully!</div>
         <!-- TMPL_ELSE -->
           <div>Collection Failed To Be Deleted!</div>
         <!-- /TMPL_IF -->
@@ -34,7 +34,7 @@
 
       <!-- TMPL_IF NAME="previousActionUpdate" -->
         <!-- TMPL_IF NAME="updateSuccess" -->
-          <div>Collection '<!-- TMPL_VAR NAME="updatedTitle" -->' Updated Succesfully!</div>
+          <div>Collection '<!-- TMPL_VAR NAME="updatedTitle" -->' Updated Successfully!</div>
         <!-- TMPL_ELSE -->
           <div>Collection '<!-- TMPL_VAR NAME="updatedTitle" -->' Failed To Be Updated!</div>
           <div>Reason: <strong><!-- TMPL_VAR NAME="failureMessage" --></strong></div>
 
 </div>
 </div>
-<!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->
\ No newline at end of file
+<!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->
+
index 56f29e8..4fa488d 100644 (file)
@@ -13,7 +13,7 @@
       <h1>Rotating Collections: Transfer Collection</h1>
     <br />
       <!-- TMPL_IF NAME="transferSuccess" -->
-        <div>Collection Transfered Successfully</div>
+        <div>Collection Transferred Successfully</div>
       <!-- /TMPL_IF -->
 
       <!-- TMPL_IF NAME="transferFailure" -->
index f2227a8..7489cb6 100644 (file)
@@ -395,7 +395,7 @@ h4.collapse a { font-size : 80%; text-decoration: none; } fieldset.brief ol { di
                     <li><input type="submit" value="Go" /></li></ol>
                 </fieldset>
 
-                               <fieldset class="brief"><h4 class="collapse"><a href="#">Acquistion information</a></h4>
+                               <fieldset class="brief"><h4 class="collapse"><a href="#">Acquisition information</a></h4>
                     <ol><li><label for="budgetid"> Book fund:</label>
                     <select name="budgetid" id="budgetid"><option value="">Any</option><!-- TMPL_LOOP name="budgetid_loop" -->
                         <!-- TMPL_IF NAME="selected" --> <option value="<!-- TMPL_VAR name="code" -->" selected="selected"><!-- TMPL_VAR name="desc" --></option><!-- TMPL_ELSE --><option value="<!-- TMPL_VAR name="code" -->"><!-- TMPL_VAR name="desc" --></option><!-- /TMPL_IF -->
@@ -413,3 +413,4 @@ h4.collapse a { font-size : 80%; text-decoration: none; } fieldset.brief ol { di
         </div><!-- /TMPL_UNLESS -->
 </div>
 <!--TMPL_INCLUDE NAME="intranet-bottom.inc"-->
+
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/test/README b/koha-tmpl/intranet-tmpl/prog/en/modules/test/README
new file mode 100644 (file)
index 0000000..20fe504
--- /dev/null
@@ -0,0 +1 @@
+Test templates, to be used with test scripts
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/test/progressbar.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/test/progressbar.tmpl
new file mode 100644 (file)
index 0000000..73f148f
--- /dev/null
@@ -0,0 +1,43 @@
+<!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
+<title>Koha &rsaquo; Tools &rsaquo; Stage MARC Records For Import</title>
+<!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
+<!-- TMPL_INCLUDE NAME="file-upload.inc" -->
+<!-- TMPL_INCLUDE NAME="background-job.inc" -->
+<style type="text/css">
+       #uploadpanel,#fileuploadstatus,#fileuploadfailed,#jobpanel,#jobstatus,#jobfailed { display : none; }
+       #fileuploadstatus,#jobstatus { margin:.4em; }
+       #fileuploadprogress,#jobprogress{ width:150px;height:10px;border:1px solid #666;background:url('/intranet-tmpl/prog/img/progress.png') -300px 0px no-repeat; }</style>
+<script type="text/javascript">
+//<![CDATA[
+$(document).ready(function(){
+});
+function CheckForm(f) {
+    submitBackgroundJob(f);
+    return false;
+}
+
+//]]>
+</script>
+</head>
+<body>
+<div id="doc3" class="yui-t2">
+   
+<form method="post" action="progressbarsubmit.pl">
+<input type="hidden" name="submitted" id="submitted" value="1" />
+<input type="hidden" name="runinbackground" id="runinbackground" value="" />
+<input type="hidden" name="completedJobID" id="completedJobID" value="" />
+
+<input type="button" id="mainformsubmit" onclick="return CheckForm(this.form);" value="Start" />
+       <div id="jobpanel">
+           <div id="jobstatus">Job progress: <div id="jobprogress"></div> <span id="jobprogresspercent">0</span>%</div>
+           <div id="jobfailed"></div>
+       </div>
+  
+</form>
+</div>
+
+<div>
+Completed: <span id="completed"><!-- TMPL_VAR NAME="completedJobID" --> </span>
+</div>
+</body>
index 01f718c..38b12dd 100644 (file)
@@ -1,46 +1,14 @@
 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
-<title>Koha &rsaquo; Tools &rsaquo; Calendar</title>
+<title>Koha &rsaquo; Tools &rsaquo; <!-- TMPL_VAR NAME="branchname" --> Calendar</title>
 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
 <!-- TMPL_INCLUDE NAME="calendar.inc" -->
 <script type="text/javascript" src="<!-- TMPL_VAR NAME="themelang" -->/lib/jquery/plugins/jquery.tablesorter.min.js"></script>
 <script language="JavaScript" type="text/javascript">
 //<![CDATA[
-       // Captura el evento onmousemove para cualquier navegador
-       if (document.layers) { // Netscape
-               document.captureEvents(Event.MOUSEMOVE);
-           document.onmousemove = captureMousePosition;
-       } else if (document.all) { // Internet Explorer
-           document.onmousemove = captureMousePosition;
-       } else if (document.getElementById) { // Netcsape 6
-           document.onmousemove = captureMousePosition;
-       }
 
-       var mouseXMax = 0;
-       var mouseYMax = 0;
-       var mouseX = 0;
-       var mouseY = 0;
        var weekdays = new Array("Sundays", "Mondays", "Tuesdays",
                        "Wednesdays", "Thursdays", "Fridays", "Saturdays");
 
-       function captureMousePosition(e) {
-           if (document.layers) {
-                   mouseX = e.pageX;
-                       mouseY = e.pageY;
-               mouseXMax = window.innerWidth + window.pageXOffset;
-                   mouseYMax = window.innerHeight + window.pageYOffset;
-           } else if (document.all) {
-                   mouseX = window.event.x + document.body.scrollLeft;
-               mouseY = window.event.y + document.body.scrollTop;
-               mouseXMax = document.body.clientWidth + document.body.scrollLeft;
-               mouseYMax = document.body.clientHeight + document.body.scrollTop;
-           } else if (document.getElementById) {
-               mouseX = e.pageX;
-                   mouseY = e.pageY;
-               mouseXMax = window.innerWidth + window.pageXOffset;
-               mouseYMax = window.innerHeight + window.pageYOffset;
-           }
-       } 
-
        function holidayOperation(formObject, opType) {
                var op = document.getElementsByName('operation');
                op[0].value = opType;
        function showHoliday (exceptionPosibility, dayName, day, month, year, weekDay, title, description, holidayType) {
                $("#newHoliday").slideUp("fast");
                $("#showHoliday").slideDown("fast");
-               document.getElementById('showDayname').value = dayName;
-               document.getElementById('showBranchName').value = document.getElementById('branch').value;
-               document.getElementById('showDay').value = day;
-               document.getElementById('showMonth').value = month;
-               document.getElementById('showYear').value = year;
-               document.getElementById('showDescription').value = description;
-               document.getElementsByName('showWeekday')[0].value = weekDay;
-               document.getElementById('showTitle').value = title;
-               document.getElementById('showHolidayType').value = holidayType;
+               $('#showDaynameOutput').html(dayName);
+               $('#showDayname').val(dayName);
+               $('#showBranchNameOutput').html($("#branch :selected").text());
+               $('#showBranchName').val($("#branch").val());
+               $('#showDayOutput').html(day);
+               $('#showDay').val(day);
+               $('#showMonthOutput').html(month);
+               $('#showMonth').val(month);
+               $('#showYearOutput').html(year);
+               $('#showYear').val(year);
+               $('#showDescription').val(description);
+               $('#showWeekday:first').val(weekDay);
+               $('#showTitle').val(title);
+               $('#showHolidayType').val(holidayType);
 
                if (holidayType == 'exception') {
-                       document.getElementById('showOperationDelLabel').innerHTML = 'Delete this exception.';
+                       $("#showOperationDelLabel").html(_('Delete this exception.'));
+                       $("#holtype").attr("class","key exception").html(_("Holiday exception"));
+               } else if(holidayType == 'weekday') {
+                       $("#showOperationDelLabel").html(_('Delete this holiday.'));
+                       $("#holtype").attr("class","key repeatableday").html(_("Repeatable holiday"));
                } else {
-                       document.getElementById('showOperationDelLabel').innerHTML = 'Delete this holiday.';
+                       $("#showOperationDelLabel").html(_('Delete this holiday.'));
+                       $("#holtype").attr("class","key holiday").html(_("Unique holiday"));
                }
                
                if (exceptionPosibility == 1) {
-                       document.getElementById('exceptionPosibility').style.display = 'inline';
+                       $("#exceptionPosibility").parent().show();
                } else {
-                       document.getElementById('exceptionPosibility').style.display = 'none';
+                       $("#exceptionPosibility").parent().hide();
                }
        }
 
        function newHoliday (dayName, day, month, year, weekDay) {
                $("#showHoliday").slideUp("fast");
                $("#newHoliday").slideDown("fast");
+               $("#newDaynameOutput").html(dayName);
                $("#newDayname").val(dayName);
+               $("#newBranchNameOutput").html($('#branch :selected').text());
                $("#newBranchName").val($('#branch').val());
+               $("#newDayOutput").html(day);
                $("#newDay").val(day);
+               $("#newMonthOutput").html(month);
                $("#newMonth").val(month);
+               $("#newYearOutput").html(year);
                $("#newYear").val(year);
-               $("#newWeekday")[0].val(weekDay);
+               $("#newWeekday:first").val(weekDay);
        }
 
        function hidePanel(aPanelName) {
                location.href='/cgi-bin/koha/tools/holidays.pl?branch=' + branch + '&calendardate=' + "<!-- TMPL_VAR NAME='calendardate' -->";
        }
 
-       function additionalInformation (anExplanation) {
-               var panel = document.getElementById('information');
-               var paragraph = document.getElementById('explanation');
-               panel.style.display = 'inline'
-               panel.style.top = mouseY;
-               panel.style.left = mouseX;
-               var info = document.createTextNode(anExplanation);
-               if (paragraph.hasChildNodes()) {
-                       paragraph.removeChild(paragraph.lastChild);
-               }
-               paragraph.appendChild(info);
-       }
-
        function Help() {
                newin=window.open("/cgi-bin/koha/help.pl","KohaHelp",'width=600,height=600,toolbar=false,scrollbars=yes');
        }
        $(document).ready(function() {
+               $(".hint").hide();
                $("#branch").change(function(){
                        changeBranch();
                });
                $("#holidaysunique").tablesorter({
                  sortList: [[0,0]], widgets: ['zebra']
                });
+               $("a.helptext").click(function(){
+                       $(this).parent().find(".hint").toggle(); return false;
+               });
        });
 //]]>
 </script>
-<style type="text/css">
-.normalday { background-color :  #EDEDED; color :  Black; border : 1px solid #000000; }
-.exception { background-color :  #EDEDED; color :  Black; border : 1px solid #000000; }
-.holiday {  background-color :  red; color :  Black;  border : 1px solid #000000; }
-.repeatableday {  background-color :  yellow; color :  Black;  border : 1px solid #000000; }
+<style type="text/css"> .key { padding : 3px; white-space:nowrap; line-height:230%; }
+.normalday { background-color :  #EDEDED; color :  Black; border : 1px solid #BCBCBC; }
+.exception { background-color :  #b3d4ff; color :  Black; border : 1px solid #BCBCBC; }
+.holiday {  background-color :  #ffaeae; color :  Black;  border : 1px solid #BCBCBC; }
+.repeatableday {  background-color :  #FFFF99; color :  Black;  border : 1px solid #BCBCBC; }
 .information { z-index : 1; background-color :  #DCD2F1; width : 300px; display : none; border : 1px solid #000000; color :  #000000; font-size :  8pt; font-weight :  bold; background-color :  #FFD700; cursor :  pointer; padding : 2px; }
-.panel { z-index : 1; width : 500px; display : none; border : 1px solid #000000; padding : 3px; /* position: absolute; */ background-color: #CCCCCC; }
-div.dmy { display:inline; }
-.blacklabel, div.dmy input { background-color:#FFFFFF; color:Black; font-size:10px; }
-h1 select { width: 20em; }
+.panel { z-index : 1; display : none; border : 3px solid #CCC; padding : 3px; margin-top: .3em;  background-color: #FEFEFE; } fieldset.brief { border : 0; margin-top: 0; }
+#showHoliday { margin : .5em 0; } h1 select { width: 20em; } div.yui-b fieldset.brief ol { font-size:100%; } div.yui-b fieldset.brief li, div.yui-b fieldset.brief li.radio  { padding:0.2em 0; } .help { margin:.3em 0;border:1px solid #EEE;padding:.3em .7em; font-size : 90%; } #holidayweeklyrepeatable, #holidaysyearlyrepeatable, #holidaysunique, #holidayexceptions { font-size : 90%; margin-bottom : 1em;} .calendar td, .calendar th, .calendar .button, .calendar tbody .day { padding : .7em; font-size: 110%; } .calendar { width: auto; border : 0; }
 </style>
 </head>
 <body>
 <!-- TMPL_INCLUDE NAME="header.inc" -->
 <!-- TMPL_INCLUDE NAME="cat-search.inc" -->
 
-<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> &rsaquo; Calendar</div>
+<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> &rsaquo; <!-- TMPL_VAR NAME="branchname" --> Calendar</div>
 
-<div id="doc3" class="yui-t2">
+<div id="doc3" class="yui-t1">
    
    <div id="bd">
        <div id="yui-main">
        <div class="yui-b">
-
-
-
-
-<!-- *************************************************************************************** -->
-<!-- ******                     START OF INFORMATION PANEL                            ****** -->
-<!-- *************************************************************************************** -->
-
-<div class="information" style="position:absolute" id="information" onclick=" hidePanel('information')">
-       <table>
-               <tr>
-                       <td>
-                               <p id="explanation" style="display:inline;align:justify"></p>
-                       </td>
-               </tr>
-       </table>
-</div>
-
-<!-- ************************************************************************************** -->
-<!-- ******                      END OF INFORMATION PANEL                            ****** -->
-<!-- ************************************************************************************** -->
-
-<h1>Define the holidays for :</h1>
-        <label for="branch">Select a library :</label>
+       <h2><!-- TMPL_VAR NAME="branchname" --> Calendar</h2>
+       <div class="yui-g">
+       <div class="yui-u first">
+        <label for="branch">Define the holidays for:</label>
             <select id="branch" name="branch">
                 <!-- TMPL_LOOP NAME="branchloop" -->
                     <!-- TMPL_IF NAME="selected" -->
@@ -186,17 +138,6 @@ h1 select { width: 20em; }
                     <!-- /TMPL_IF -->
                 <!-- /TMPL_LOOP -->
             </select>
-       <ul>
-               <li>Search in the calendar the day you want to set as holiday.</li>
-               <li>Complete the information in the right area.</li>
-               <li>Once you finish the steps above, click Save.</li>
-       </ul>
-       <p>
-               <span class="normalday">Working day</span>
-               <span class="holiday">Unique holiday</span>
-               <span class="repeatableday">Repeatable holiday</span>
-               <span class="exception">Holiday exception</span>
-       </p>
        
        <!-- ******************************** FLAT PANELS ******************************************* -->
        <!-- *****           Makes all the flat panel to deal with holidays                     ***** -->
@@ -206,39 +147,49 @@ h1 select { width: 20em; }
        <div class="panel" id="showHoliday">
                <form action="/cgi-bin/koha/tools/exceptionHolidays.pl" method="post">
                        <input type="hidden" id="showHolidayType" name="showHolidayType" value="" />
-                       <h2>Edit this holiday</h2>
-                       <p>
-                               <label for="showBranchName">Library</label>
-                               <input type="text" size="20" id="showBranchName" name="showBranchName" readonly="readonly" class="blacklabel" />
-                       </p>
-                       <p>
-                               <label for="showDayname">Day name</label>
-                               <input type="text" size="20" id="showDayname" name="showDayname" readonly="readonly" class="blacklabel" />
-                               <input type="hidden" name="showWeekday" />
-                       </p>
-                       <div class="dmy">
-                               <label for="showDay">Day</label> <input type="text" size="2" id="showDay" name="showDay" readonly="readonly" />
-                               <label for="showMonth">Month</label> <input type="text" size="2" id="showMonth" name="showMonth" readonly="readonly" />
-                               <label for="showYear">Year</label> <input type="text" size="4" id="showYear" name="showYear" readonly="readonly" />             
-                       </div>
+                       <fieldset class="brief">
+                       <h3>Edit this holiday</h3>
+                       <span id="holtype"></span>
+                       <ol>
+                       <li>
+                               <strong>Library:</strong> <span id="showBranchNameOutput"></span>
+                               <input type="hidden" id="showBranchName" name="showBranchName" />
+                       </li>
+                       <li>
+                               <strong>Date:</strong>
+                               <span id="showDaynameOutput"></span>, 
+                               
+                               <!-- TMPL_IF NAME="dateformat_us" --><span id="showMonthOutput"></span>/<span id="showDayOutput"></span>/<span id="showYearOutput"></span><!-- TMPL_ELSIF NAME="dateformat_metric" --><span id="showDayOutput"></span>/<span id="showMonthOutput"></span>/<span id="showYearOutput"></span><!-- TMPL_ELSE --><span id="showYearOutput"></span>/<span id="showMonthOutput"></span>/<span id="showDayOutput"></span><!-- /TMPL_IF -->
+
+                               <input type="hidden" id="showDayname" name="showDayname" />
+                               <input type="hidden" id="showWeekday" name="showWeekday" />
+                               <input type="hidden" id="showDay" name="showDay" />
+                               <input type="hidden" id="showMonth" name="showMonth" />
+                               <input type="hidden" id="showYear" name="showYear" />
+                       </li>
+                       <li><label for="showTitle">Title: </label><input type="text" name="showTitle" id="showTitle" size="35" /></li>
                    <!-- showTitle is necessary for exception radio button to work properly --> 
-                   <input type="hidden" id="showTitle" name="showTitle" value="" />
-                   <p><label for="showDescription">Description:</label>
-                               <br />
+                               <label for="showDescription">Description:</label>
                                <textarea rows="2" cols="40" id="showDescription" name="showDescription"></textarea>    
-                       </p>
-                       <div id="exceptionPosibility" style="position:static">
+                   </li>
+                       <li class="radio"><div id="exceptionPosibility" style="position:static">
                                <input type="radio" name="showOperation" id="showOperationExc" value="exception" /> <label for="showOperationExc">Generate an exception for this repeated holiday.</label>
-                               <a href="#" onclick=" additionalInformation('You can make an exception for this holiday rule. This means that you will be able to say for a repeatable holiday, that there is one of those days that is going to be an exception.')"><img src="<!-- TMPL_VAR NAME="themelang" -->/../img/more.gif" border="0" alt="More information" /></a><br />
-                       </div>
-                       <input type="radio" name="showOperation" id="showOperationDel" value="delete" /> <label for="showOperationDel" id="showOperationDelLabel">Delete this holiday</label>
-                       <a href="#" onclick=" additionalInformation('This will delete this holiday rule. If it is a repeatable holiday, this option checks for posible exceptions. If an exception exists, this option will remove the exception and set the date to a regular holiday.')"><img src="<!-- TMPL_VAR NAME="themelang" -->/../img/more.gif" border="0" alt="More information" /></a><br />
-                       <input type="radio" name="showOperation" id="showOperationEdit" value="edit" checked="checked" /> <label for="showOperationEdit">Edit this holiday</label>
-                       <a href="#" onclick=" additionalInformation('This will save changes to the holiday\'s description. If the description for a repeatable holiday is modified, it affects all of the dates that the holiday is repeated.')"><img src="<!-- TMPL_VAR NAME="themelang" -->/../img/more.gif" border="0" alt="More information" /></a>
-                       <p>
+                               <a href="#" class="helptext">[?]</a>
+                               <div class="hint">You can make an exception for this holiday rule. This means that you will be able to say that for a repeatable holiday there is one day which is going to be an exception.</div>
+                       </div></li>
+                       <li class="radio"><input type="radio" name="showOperation" id="showOperationDel" value="delete" /> <label for="showOperationDel" id="showOperationDelLabel">Delete this holiday</label>
+                               <a href="#" class="helptext">[?]</a>
+                               <div class="hint">This will delete this holiday rule. If it is a repeatable holiday, this option checks for posible exceptions. If an exception exists, this option will remove the exception and set the date to a regular holiday.</div></li>
+                       <li class="radio"><input type="radio" name="showOperation" id="showOperationEdit" value="edit" checked="checked" /> <label for="showOperationEdit">Edit this holiday</label>
+                                               <a href="#" class="helptext">[?]</a>
+                                               <div class="hint">This will save changes to the holiday's title and description. If the information for a repeatable holiday is modified, it affects all of the dates on which the holiday is repeated.</div></li>
+
+                       </ol>
+                       <fieldset class="action">
                                <input type="submit" name="submit" value="Save" />
-                               <input type="button" name="cancel2" value="Cancel" onclick=" hidePanel('showHoliday');hidePanel('information')" />
-                       </p>
+                               <a href="#" class="cancel" name="cancel2" onclick=" hidePanel('showHoliday');">Cancel</a>
+                       </fieldset>
+                       </fieldset>
                </form>
        </div>
 
@@ -246,44 +197,56 @@ h1 select { width: 20em; }
        <div class="panel" id="newHoliday">
                <form action="/cgi-bin/koha/tools/newHolidays.pl" method="post">
                                <input type="hidden" name="branchCodes" id="branchCodes" value="<!-- TMPL_VAR NAME="branchcodes" -->" /> 
-                       <h2>Add new holiday</h2>
-                       <p>
-                               <label for="newBranchName">Library</label>
-                               <input type="text" size="20" id="newBranchName" name="newBranchName" readonly="readonly" class="blacklabel" />
-                       </p>
-                       <p>
-                               <label for="newDayname">Day name</label>
-                               <input type="text" size="20" id="newDayname" name="newDayname" readonly="readonly" class="blacklabel" />
-                               <input type="hidden" name="newWeekday" />
-                       </p>
-                       <div class="dmy">
-                               <label for="newDay">Day</label> <input type="text" size="2" id="newDay" name="newDay" readonly="readonly" />
-                               <label for="newMonth">Month</label> <input type="text" size="2" id="newMonth" name="newMonth"  readonly="readonly" />
-                               <label for="newYear">Year</label> <input type="text" size="4" id="newYear" name="newYear" readonly="readonly" />
-                       </div>
-                       <p><label for="newDescription">Description:</label>
-                               <br />
+                       <fieldset class="brief">
+                       <h3>Add new holiday</h3>
+                       <ol>
+                       <li>
+                               <strong>Library:</strong>
+                               <span id="newBranchNameOutput"></span>
+                               <input type="hidden" id="newBranchName" name="newBranchName" />
+                       </li>
+                       <li>
+                               <strong>Date:</strong>
+                               <span id="newDaynameOutput"></span>, 
+
+                               <!-- TMPL_IF NAME="dateformat_us" --><span id="newMonthOutput"></span>/<span id="newDayOutput"></span>/<span id="newYearOutput"></span><!-- TMPL_ELSIF NAME="dateformat_metric" --><span id="newDayOutput"></span>/<span id="newMonthOutput"></span>/<span id="newYearOutput"></span><!-- TMPL_ELSE --><span id="newYearOutput"></span>/<span id="newMonthOutput"></span>/<span id="newDayOutput"></span><!-- /TMPL_IF -->
+
+                               <input type="hidden" id="newDayname" name="showDayname" />
+                               <input type="hidden" id="newWeekday" name="newWeekday" />
+                               <input type="hidden" id="newDay" name="newDay" />
+                               <input type="hidden" id="newMonth" name="newMonth" />
+                               <input type="hidden" id="newYear" name="newYear" />
+                       </li>
+                       <li><label for="title">Title: </label><input type="text" name="newTitle" id="title" size="35" /></li>
+                       <li><label for="newDescription">Description:</label>
                                <textarea rows="2" cols="40" id="newDescription" name="newDescription"></textarea>
-                       </p>
-                               <input type="radio" name="newOperation" id="newOperationOnce" value="holiday" checked="checked" />
-                               <label for="newOperationOnce">Holiday only on this day</label>.
-                               <a href="#" onclick=" additionalInformation('Make a single holiday. For example, selecting August 1st, 2012 will make it holiday, but will not affect August 1st in other years.')"><img src="<!-- TMPL_VAR NAME="themelang" -->/../img/more.gif" border="0" alt="More information" /></a>
-                               <br />
-                               <input type="radio" name="newOperation" id="newOperationDay" value="weekday" />
-                               <label for="newOperationDay">Holiday repeated every same day of the week</label>.
-                               <a href="#" onclick=" additionalInformation('Make this weekday a holiday, every week. For example, if your library is closed on Saturdays, use this option to make every Saturday a holiday.')"><img src="<!-- TMPL_VAR NAME="themelang" -->/../img/more.gif" border="0" alt="More information" /></a>
-                               <br />
-                               <input type="radio" name="newOperation" id="newOperationYear" value="repeatable" />
-                               <label for="newOperationYear">Holiday repeated yearly on the same date</label>.
-                               <a href="#" onclick=" additionalInformation('This will take this day and month as a reference to make it holiday. Through this option, you can repeat this rule for every year. For example, selecting August 1st will make August 1st a holiday every year.')"><img src="<!-- TMPL_VAR NAME="themelang" -->/../img/more.gif" border="0" alt="More information" /></a>
-                               <p>
+                       </li>
+                       <li class="radio"><input type="radio" name="newOperation" id="newOperationOnce" value="holiday" checked="checked" />
+                       <label for="newOperationOnce">Holiday only on this day</label>.
+                       <a href="#" class="helptext">[?]</a>
+                       <div class="hint">Make a single holiday. For example, selecting August 1st, 2012 will make it a holiday, but will not affect August 1st in other years.</div>
+                       </li>
+                       <li class="radio"><input type="radio" name="newOperation" id="newOperationDay" value="weekday" />
+                                                       <label for="newOperationDay">Holiday repeated every same day of the week</label>.
+                                                       <a href="#" class="helptext">[?]</a>
+                                                       <div class="hint">Make this weekday a holiday, every week. For example, if your library is closed on Saturdays, use this option to make every Saturday a holiday.</div>
+                                                       </li>
+                       <li class="radio"><input type="radio" name="newOperation" id="newOperationYear" value="repeatable" />
+                                                       <label for="newOperationYear">Holiday repeated yearly on the same date</label>.
+                                                       <a href="#" class="helptext">[?]</a>
+                                                       <div class="hint">This will take this day and month as a reference to make it a holiday. Through this option, you can repeat this rule for every year. For example, selecting August 1st will make August 1st a holiday every year.</div>
+                                                       </li>
+                               <li class="radio">
                                <input type="checkbox" name="allBranches" id="allBranches" />
                                <label for="allBranches">Copy to all libraries</label>.
-                               <a href="#" onclick=" additionalInformation('If checked, this holiday will be copied to all libraries. If the holiday already exists for a library, no change is made.')"><img src="<!-- TMPL_VAR NAME="themelang" -->/../img/more.gif" border="0" alt="More information" /></a>
-                               </p><p>
+                               <a href="#" class="helptext">[?]</a>
+                               <div class="hint">If checked, this holiday will be copied to all libraries. If the holiday already exists for a library, no change is made.</div>
+                               </li></ol>
+                               <fieldset class="action">
                                        <input type="submit" name="submit" value="Save" />
-                                       <input type="button" name="cancel2" value="Cancel" onclick=" hidePanel('newHoliday');hidePanel('information')" />
-                               </p>
+                                       <a href="#" class="cancel" name="cancel2" onclick=" hidePanel('newHoliday');">Cancel</a>
+                               </fieldset>
+                               </fieldset>
                </form>
        </div>
 
@@ -294,7 +257,7 @@ h1 select { width: 20em; }
 <!-- ************************************************************************************** -->
 <!-- ******                              MAIN SCREEN CODE                            ****** -->
 <!-- ************************************************************************************** -->
-<h2>Calendar information</h2>
+<h3>Calendar information</h3>
 <div id="calendar-container">
 <script type="text/javascript">
        /* Creates all the structures to deal with all diferents kinds of holidays */
@@ -368,6 +331,27 @@ h1 select { width: 20em; }
        );
 </script>
 
+
+</div>
+</div>
+<div class="yui-u">
+<div class="help">
+<h4>Hints</h4>
+       <ul>
+               <li>Search in the calendar the day you want to set as holiday.</li>
+               <li>Click the date to add or edit a holiday.</li>
+               <li>Enter a title and description for the holdiay.</li>
+               <li>Specify how the holiday should repeat.</li>
+               <li>Click Save to finish.</li>
+       </ul>
+<h4>Key</h4>
+       <p>
+               <span class="key normalday">Working day</span>
+               <span class="key holiday">Unique holiday</span>
+               <span class="key repeatableday">Repeatable holiday</span>
+               <span class="key exception">Holiday exception</span>
+       </p>
+</div>
 <div id="holiday-list">
 <!-- Exceptions First -->
 <!--   this will probably always have the least amount of data -->
@@ -383,7 +367,7 @@ h1 select { width: 20em; }
 <tbody>
   <!-- TMPL_LOOP NAME="EXCEPTION_HOLIDAYS_LOOP" -->
   <tr>
-  <td><!-- TMPL_VAR NAME="DATE" --></td>
+  <td><a href="/cgi-bin/koha/tools/holidays.pl?branch=<!-- TMPL_VAR NAME="branch" -->&amp;calendardate=<!-- TMPL_VAR NAME="DATE" -->"><!-- TMPL_VAR NAME="DATE" --></a></td>
   <td><!-- TMPL_VAR NAME="TITLE" --></td>
   <td><!-- TMPL_VAR NAME="DESCRIPTION" --></td> 
   </tr>
@@ -457,7 +441,7 @@ h1 select { width: 20em; }
 <tbody>
     <!-- TMPL_LOOP NAME="HOLIDAYS_LOOP" -->
 <tr>
-  <td><!-- TMPL_VAR NAME="DATE" --></td>
+  <td><a href="/cgi-bin/koha/tools/holidays.pl?branch=<!-- TMPL_VAR NAME="branch" -->&amp;calendardate=<!-- TMPL_VAR NAME="DATE" -->"><!-- TMPL_VAR NAME="DATE" --></a></td>
   <td><!-- TMPL_VAR NAME="TITLE" --></td>
   <td><!-- TMPL_VAR NAME="DESCRIPTION" --></td>
 </tr>
@@ -469,6 +453,7 @@ h1 select { width: 20em; }
 </div>
 </div>
 </div>
+</div>
 
 <div class="yui-b noprint">
 <!-- TMPL_INCLUDE NAME="tools-menu.inc" -->
index ad3b663..0e409b6 100644 (file)
 <div class="yui-u">
 <h2>Notes:</h2>
 <ul>
+<li>The first line in the file must be a header row defining which columns you are supplying in the import file.</li>
 <li><b>Download a starter CSV file with all the columns <a href="?sample=1">here</a>.</b>  Values are comma-separated.</li>
-<li>OR format your file in CSV format with the following fields:<ul><li>
+<li>OR choose which fields you want to supply from the following list:<ul><li>
     <!-- TMPL_LOOP name="columnkeys" -->'<!-- TMPL_VAR name="key" -->', <!-- /TMPL_LOOP -->
 </li></ul></li>
 <!-- TMPL_IF NAME="ExtendedPatronAttributes" -->
 </li>
 <!-- /TMPL_IF -->
 <li>The fields 'branchcode' and 'categorycode' are <b>required</b> and <b>must match</b> valid entries in your database.</li>
-<li>'password' should be stored in plaintext, and will be converted to a md5 hash (if your passwords are already encrypted, talk to your systems administrator about options).</li>
-<li>Date formats should match your system preference, and <b>must</b> be zero-padded, e.g. '01/02/2008'.</li>
-<li>You may optionally include a header row, defining which columns you are supplying in the import file.</li>
+<li>'password' should be stored in plaintext, and will be converted to a MD5 hash (if your passwords are already encrypted, talk to your system administrator about options).</li>
+<li>Date formats should match your system preference, and <b>must</b> be zero-padded, e.g. '01/02/2008'.  Alternatively,
+you can supply dates in ISO format (e.g., '2010-10-28').
+</li>
 </ul>
 
      </div>
index f2750e3..21e8271 100644 (file)
                 <!-- TMPL_IF name="ERRORS" -->
                 <div class="dialog alert">
                     <!-- TMPL_LOOP name="ERRORS" -->
-                        <!-- TMPL_IF name="NOTZIP" --><li><b>The upload file does not appear to be a zip file.  The extention is not '.zip'.</b></li>
+                        <!-- TMPL_IF name="NOTZIP" --><li><b>The upload file does not appear to be a zip file.  The extension is not '.zip'.</b></li>
                         <!-- TMPL_ELSIF name="NOWRITETEMP" --><li><b>This script is not able to create/write to the necessary temporary directory.</b></li>
                         <!-- TMPL_ELSIF name="EMPTYUPLOAD" --><li><b>The upload file appears to be empty.</b></li>
                         <!-- TMPL_ELSIF name="OPNLINK" --><li><b>Cannot open <!-- TMPL_VAR NAME="OPNLINK" --> to read.<br />Please verify that it exists.</b></li>
                         <!-- TMPL_ELSIF name="OPNIMG" --><li><b>Cannot open <!-- TMPL_VAR NAME="OPNIMG" --> to read.<br />Please verify that it exists.</b></li>
-                        <!-- TMPL_ELSIF name="DELERR" --><li><b>Unrecognized or missing field delimeter.<br />Please verify that you are using either a single quote or a tab.</b></li>
+                        <!-- TMPL_ELSIF name="DELERR" --><li><b>Unrecognized or missing field delimiter.<br />Please verify that you are using either a single quote or a tab.</b></li>
                         <!-- TMPL_ELSIF name="UZIPFAIL" --><li><b><!-- TMPL_VAR name="UZIPFAIL" --> failed to unpack.<br />Please verify the integrity of the zip file and retry.</b></li>
                         <!-- TMPL_ELSE --><li><b><!-- TMPL_VAR name ="CORERR" --> An unknown error has occurred.<br />Please review the error log for more details.</b></li><!-- /TMPL_IF -->
                     <!-- /TMPL_LOOP -->
index 3f8502e..9da4d45 100644 (file)
@@ -7,7 +7,7 @@ Hi,
 
 Here is your list called <!-- TMPL_VAR NAME="shelfname" -->, sent from our online catalog.
 
-Please note that the attached file is a MARC biblographic records file
+Please note that the attached file is a MARC bibliographic records file
 which can be imported into a Personal Bibliographic Software like EndNote,
 Reference Manager or ProCite.
 <END_HEADER>
index 547668a..35c022b 100644 (file)
@@ -211,8 +211,8 @@ function placeHold () {
     </table><fieldset class="action">
         <!-- TMPL_IF name="manageshelf" -->
             <input type="button" id="placehold" style="display:none" onclick="placeHold(); return false;" value="Place Holds" />
-            <input type="submit" value="Remove selected Items" onclick="return confirm(_('Are you sure you want to remove these items from the shelf?'));" />
-            <input type="submit" value="Merge selected Items" onclick="return MergeItems();" />
+            <input type="submit" value="Remove selected records" onclick="return confirm(_('Are you sure you want to remove these records from the shelf?'));" />
+            <input type="submit" value="Merge selected records" onclick="return MergeItems();" />
         <!-- /TMPL_IF -->
  </fieldset>
  </fieldset>
index 4756615..f4bc51f 100644 (file)
         </xsl:if>
 
         <xsl:if test="marc:datafield[substring(@tag, 1, 1) = '6']">
-            <span class="results_summary"><span class="label">Related Subjects: </span>
+            <span class="results_summary"><span class="label">Subject(s): </span>
             <xsl:for-each select="marc:datafield[substring(@tag, 1, 1) = '6']">
             <a>
             <xsl:choose>
index 52b00e7..1ee82d0 100644 (file)
@@ -82,6 +82,7 @@
 <!-- /TMPL_IF -->
 <!-- TMPL_IF NAME="expanded_options" -->
             <option value="nt">Notes/Comments</option>
+            <option value="curriculum">Curriculum</option>
 <!-- /TMPL_IF -->
             <option value="pb,wrdl">Publisher</option>
             <option value="pl,wrdl">Publisher Location</option>
index 2b07471..f0b4cf7 100644 (file)
@@ -12,7 +12,6 @@
 <form name="f" action="/cgi-bin/koha/opac-authorities-home.pl" method="get">
         <input type="hidden" name="op" value="do_search" />
         <input type="hidden" name="type" value="opac" />
-        <input type="hidden" name="nbstatements" value="<!-- TMPL_VAR NAME="nbstatements" -->" />
 <fieldset class="rows">
 <legend>Authority search</legend>
 <ol>
index 3282600..3d59dd1 100644 (file)
@@ -90,7 +90,7 @@ function highlightOn() {
     for (x in q_array) {
        $(".title").highlight(q_array[x]);
        $(".author").highlight(q_array[x]);
-        $(".result_summary").highlight(q_array[x]);
+        $(".results_summary").highlight(q_array[x]);
     }
     $(".highlight_toggle").toggle();
 }
index 5513198..57f62ee 100644 (file)
@@ -7,7 +7,7 @@ Hi,
 
 <!-- TMPL_VAR NAME="firstname" --> <!-- TMPL_VAR NAME="surname" --> sent you a cart from our online catalog.
 
-Please note that the attached file is a MARC biblographic records file
+Please note that the attached file is a MARC bibliographic records file
 which can be imported into a Personal Bibliographic Software like EndNote,
 Reference Manager or ProCite.
 <END_HEADER>
index 1d4e4c6..1c367a0 100644 (file)
@@ -7,7 +7,7 @@ Hi,
 
 <!-- TMPL_VAR NAME="firstname" --> <!-- TMPL_VAR NAME="surname" -->, sent you from our online catalog, the virtual shelf called :  <!-- TMPL_VAR NAME="shelfname" -->.
 
-Please note that the attached file is a MARC biblographic records file
+Please note that the attached file is a MARC bibliographic records file
 which can be imported into a Personal Bibliographic Software like EndNote,
 Reference Manager or ProCite.
 <END_HEADER>
index 6c3cb94..2e6ba39 100644 (file)
                <form method="get" action="opac-tags.pl">
                <fieldset>Show up to <input type="text" name="limit" style="text-align: right;" maxlength="4" size="4" value="<!-- TMPL_VAR NAME="limit" DEFAULT="100" -->" />
                        tags from other users.
-                        <!-- TMPL_IF NAME="hidemytags" -->
-                       <input type="hidden" name="hidemytags" value="1" />
-                        <!-- /TMPL_IF -->
                        <input type="submit" value="OK" />
                         <!-- TMPL_UNLESS NAME="loggedinusername" -->
                           <a href="/cgi-bin/koha/opac-user.pl">Log in</a> to see your own saved tags.
                         <!-- TMPL_ELSE -->
-                          <!-- TMPL_IF NAME="hidemytags" --><a class="hidemytags" href="/cgi-bin/koha/opac-tags.pl?limit=<!-- TMPL_VAR NAME="limit" DEFAULT="100" -->">Show my tags</a>
-                          <!-- TMPL_ELSE --><a class="hidemytags" href="/cgi-bin/koha/opac-tags.pl?limit=<!-- TMPL_VAR NAME="limit" DEFAULT="100" -->&amp;hidemytags=1">Hide my tags</a>
-                          <!-- /TMPL_IF -->
                         <!-- /TMPL_UNLESS --></fieldset>
                </form>
        
          <!-- /TMPL_IF -->
        <!-- /TMPL_IF -->
 
-       <!-- TMPL_UNLESS NAME="hidemytags" -->
        <!-- TMPL_IF NAME="MY_TAGS" -->
                <form method="post" action="opac-tags.pl">
                <h2>My Tags</h2>
                </table>
                </form>
        <!-- /TMPL_IF -->
-       <!-- /TMPL_UNLESS -->
 
 </div>
 </div>
index 95d3303..e31dbe7 100755 (executable)
         </xsl:if>
 
         <xsl:if test="marc:datafield[substring(@tag, 1, 1) = '6']">
-            <span class="results_summary"><span class="label">Related Subjects: </span>
+            <span class="results_summary"><span class="label">Subject(s): </span>
             <xsl:for-each select="marc:datafield[substring(@tag, 1, 1) = '6']">
             <a>
             <xsl:choose>
index aaa702a..372d31c 100644 (file)
            </xsl:call-template>
         </xsl:if>
 
-       <a><xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of select="$biblionumber"/></xsl:attribute>
+        <a><xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of select="$biblionumber"/></xsl:attribute><xsl:attribute name="class">title</xsl:attribute>
 
         <xsl:if test="marc:datafield[@tag=245]">
         <xsl:for-each select="marc:datafield[@tag=245]">
     <xsl:choose>
     <xsl:when test="marc:datafield[@tag=100] or marc:datafield[@tag=110] or marc:datafield[@tag=111] or marc:datafield[@tag=700] or marc:datafield[@tag=710] or marc:datafield[@tag=711]">
 
-    by 
+    by <span class="author">
         <xsl:for-each select="marc:datafield[@tag=100 or @tag=700]">
             <xsl:choose>
             <xsl:when test="position()=last()">
             </xsl:otherwise>
             </xsl:choose>
         </xsl:for-each>
+    </span>
     </xsl:when>
     </xsl:choose>
     </p>
index 94d56b4..370807c 100755 (executable)
@@ -27,6 +27,7 @@ use CGI;
 use C4::Auth qw(get_template_and_user);
 use C4::Output qw(output_html_with_http_headers);
 use C4::Branch qw(get_branch_code_from_name);
+use C4::Items qw(GetItemnumberFromBarcode);
 use C4::Creators 1.000000;
 use C4::Labels 1.000000;
 
@@ -57,7 +58,8 @@ my $display_columns = [ {_label_number  => {label => 'Label Number', link_field
 my $op = $cgi->param('op') || 'edit';
 my $batch_id = $cgi->param('element_id') || $cgi->param('batch_id') || undef;
 my @label_ids = $cgi->param('label_id') if $cgi->param('label_id');
-my @item_numbers = $cgi->param('item_number') if $cgi->param('item_number');
+my @item_numbers = $cgi->param('item_number') || ();
+my $barcode = $cgi->param('barcode') if $cgi->param('barcode');
 
 my $branch_code = get_branch_code_from_name($template->param('LoginBranchname'));
 
@@ -76,6 +78,15 @@ elsif ($op eq 'delete') {
     $errstr = "batch $batch_id was not deleted." if $err;
 }
 elsif ($op eq 'add') {
+    if ($barcode) {
+        my @barcodes = split /\n/, $barcode; # $barcode is effectively passed in as a <cr> separated list
+        foreach my $number (@barcodes) {
+            $number =~ s/\r$//; # strip any naughty return chars
+            if (my $item_number = GetItemnumberFromBarcode($number)) {  # we must test in case an invalid barcode is passed in; we effectively disgard them atm
+                push @item_numbers, $item_number;
+            }
+        }
+    }
     $batch = C4::Labels::Batch->retrieve(batch_id => $batch_id);
     $batch = C4::Labels::Batch->new(branch_code => $branch_code) if $batch == -2;
     if ($branch_code){
index f811b24..7d5bcd1 100755 (executable)
@@ -37,12 +37,13 @@ use Getopt::Long;
 
 sub usage {
     print STDERR <<USAGE;
-Usage: $0 [-h|--help] [--sessions] [-v|--verbose] [--zebraqueue DAYS]
+Usage: $0 [-h|--help] [--sessions] [--sessdays DAYS] [-v|--verbose] [--zebraqueue DAYS]
         [-m|--mail]
    -h --help          prints this help message, and exits, ignoring all
                       other options
    --sessions         purge the sessions table.  If you use this while users 
                       are logged into Koha, they will have to reconnect.
+   --sessdays DAYS   purge only sessions older than DAYS days (use together with sessions parameter).
    -v --verbose       will cause the script to give you a bit more information
                       about the run.
    --zebraqueue DAYS  purge completed entries from the zebraqueue from 
@@ -52,11 +53,12 @@ USAGE
     exit $_[0];
 }
 
-my ($help, $sessions, $verbose, $zebraqueue_days, $mail);
+my ($help, $sessions, $sess_days, $verbose, $zebraqueue_days, $mail);
 
 GetOptions(
     'h|help'    => \$help,
     'sessions'  => \$sessions,
+    'sessdays:i' => \$sess_days,
     'v|verbose' => \$verbose,
     'm|mail'    => \$mail,
     'zebraqueue:i' => \$zebraqueue_days,
@@ -77,7 +79,7 @@ my $sth;
 my $sth2;
 my $count;
 
-if ($sessions) {
+if ($sessions && !$sess_days) { #old behavior
     if ($verbose){
         print "Session purge triggered.\n";
         $sth = $dbh->prepare("SELECT COUNT(*) FROM sessions");
@@ -91,6 +93,15 @@ if ($sessions) {
         print "Done with session purge.\n";
     }
 }
+elsif($sessions && $sess_days>0) { #new behavior with number of days old
+    if ($verbose){
+        print "Session purge triggered with days>$sess_days.\n";
+    }
+    RemoveOldSessions();
+    if ($verbose){
+        print "Done with session purge with days>$sess_days.\n";
+    }
+}
 
 if ($zebraqueue_days){
     $count = 0;
@@ -122,3 +133,31 @@ if ($mail) {
     print "Done with purging the mail queue.\n" if ($verbose);
 }
 exit(0);
+
+sub RemoveOldSessions {
+  my ($id, $a_session, $limit, $lasttime);
+  $limit= time() - 24*3600*$sess_days;
+
+  $sth= $dbh->prepare("SELECT id, a_session FROM sessions");
+  $sth->execute or die $dbh->errstr;
+  $sth->bind_columns(\$id, \$a_session);
+  $sth2 = $dbh->prepare("DELETE FROM sessions WHERE id=?");
+  $count=0;
+
+  while ($sth->fetch) {
+    $lasttime=0;
+    if($a_session =~ /lasttime:\s+(\d+)/) {
+       $lasttime= $1;
+    }
+    elsif($a_session =~ /(ATIME|CTIME):\s+(\d+)/ ) {
+       $lasttime= $2;
+    }
+    if($lasttime && $lasttime < $limit) {
+       $sth2->execute($id) or die $dbh->errstr;
+       $count++;
+    }
+  }
+  if ($verbose){
+      print "$count sessions were deleted.\n";
+  }
+}
index da0ebf7..2f18d52 100755 (executable)
@@ -169,13 +169,14 @@ RECORD: while (  ) {
     # get records
     eval { $record = $batch->next() };
     if ( $@ ) {
-        print "Bad MARC record: skipped\n";
+        print "Bad MARC record $i: $@ skipped\n";
         # FIXME - because MARC::Batch->next() combines grabbing the next
         # blob and parsing it into one operation, a correctable condition
         # such as a MARC-8 record claiming that it's UTF-8 can't be recovered
         # from because we don't have access to the original blob.  Note
         # that the staging import can deal with this condition (via
         # C4::Charset::MarcToUTF8Record) because it doesn't use MARC::Batch.
+        $i++;
         next;
     }
     # skip if we get an empty record (that is MARC valid, but will result in AddBiblio failure
index 09630bd..4444e7c 100755 (executable)
@@ -26,6 +26,7 @@ use warnings;
 use CGI;
 use C4::Circulation;
 use C4::Auth;
+use URI::Escape;
 use C4::Dates qw/format_date_in_iso/;
 my $input = new CGI;
 
@@ -99,6 +100,7 @@ foreach my $barcode (@barcodes) {
 # redirection to the referrer page
 #
 if ($input->param('destination') eq "circ"){
+    $cardnumber = uri_escape($cardnumber);
     print $input->redirect(
         '/cgi-bin/koha/circ/circulation.pl?findborrower='.$cardnumber.$failedrenews.$failedreturn
     );
diff --git a/t/AuthoritiesMarc_MARC21.t b/t/AuthoritiesMarc_MARC21.t
new file mode 100755 (executable)
index 0000000..d83534a
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::AuthoritiesMarc::MARC21');
+}
+
diff --git a/t/AuthoritiesMarc_UNIMARC.t b/t/AuthoritiesMarc_UNIMARC.t
new file mode 100755 (executable)
index 0000000..0a55cd6
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::AuthoritiesMarc::UNIMARC');
+}
+
diff --git a/t/Barcodes_annual.t b/t/Barcodes_annual.t
new file mode 100755 (executable)
index 0000000..b89d207
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Barcodes::annual');
+}
+
diff --git a/t/Barcodes_hbyymmincr.t b/t/Barcodes_hbyymmincr.t
new file mode 100755 (executable)
index 0000000..a2377d3
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Barcodes::hbyymmincr');
+}
+
diff --git a/t/Barcodes_incremental.t b/t/Barcodes_incremental.t
new file mode 100755 (executable)
index 0000000..1bde5d3
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Barcodes::incremental');
+}
+
diff --git a/t/Cache_FastMemcached.t b/t/Cache_FastMemcached.t
new file mode 100755 (executable)
index 0000000..589e9b1
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Cache::FastMemcached');
+}
+
diff --git a/t/Cache_Memcached.t b/t/Cache_Memcached.t
new file mode 100755 (executable)
index 0000000..80dfc7f
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Cache::Memcached');
+}
+
diff --git a/t/Cache_Memoize_Memcached.t b/t/Cache_Memoize_Memcached.t
new file mode 100755 (executable)
index 0000000..13e26e5
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Cache::Memoize::Memcached');
+}
+
diff --git a/t/ClassSortRoutine_Dewey.t b/t/ClassSortRoutine_Dewey.t
new file mode 100755 (executable)
index 0000000..a2d3dc1
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::ClassSortRoutine::Dewey');
+}
+
diff --git a/t/ClassSortRoutine_Generic.t b/t/ClassSortRoutine_Generic.t
new file mode 100755 (executable)
index 0000000..d627259
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::ClassSortRoutine::Generic');
+}
+
diff --git a/t/ClassSortRoutine_LCC.t b/t/ClassSortRoutine_LCC.t
new file mode 100755 (executable)
index 0000000..9a5e007
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::ClassSortRoutine::LCC');
+}
+
diff --git a/t/External_BakerTaylor.t b/t/External_BakerTaylor.t
new file mode 100755 (executable)
index 0000000..fdccaee
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::External::BakerTaylor');
+}
+
diff --git a/t/External_Syndetics.t b/t/External_Syndetics.t
new file mode 100755 (executable)
index 0000000..e335c74
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::External::Syndetics');
+}
+
diff --git a/t/Form_MessagingPreferences.t b/t/Form_MessagingPreferences.t
new file mode 100755 (executable)
index 0000000..483e133
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Form::MessagingPreferences');
+}
+
diff --git a/t/Heading_MARC21.t b/t/Heading_MARC21.t
new file mode 100755 (executable)
index 0000000..a0ca21b
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::External::Amazon');
+}
+
diff --git a/t/ILSDI_Services.t b/t/ILSDI_Services.t
new file mode 100755 (executable)
index 0000000..99476d3
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::ILSDI::Services');
+}
+
diff --git a/t/ILSDI_Utility.t b/t/ILSDI_Utility.t
new file mode 100755 (executable)
index 0000000..c06209b
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::ILSDI::Utility');
+}
+
diff --git a/t/ImportBatch.t b/t/ImportBatch.t
new file mode 100644 (file)
index 0000000..3c4935c
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::ImportBatch');
+}
+
diff --git a/t/Installer_PerlDependencies.t b/t/Installer_PerlDependencies.t
new file mode 100755 (executable)
index 0000000..45dc1f1
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Installer::PerlDependencies');
+}
+
diff --git a/t/Installer_PerlModules.t b/t/Installer_PerlModules.t
new file mode 100755 (executable)
index 0000000..561d84c
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Installer::PerlModules');
+}
+
diff --git a/t/ItemType.t b/t/ItemType.t
new file mode 100755 (executable)
index 0000000..de7a4e2
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::ItemType');
+}
+
index c06a406..a042f47 100755 (executable)
--- a/t/Koha.t
+++ b/t/Koha.t
@@ -2,7 +2,7 @@
 use strict;
 use warnings;
 
-use Test::More tests => 2;
+use Test::More tests => 5;
 
 use_ok('C4::Koha');
 
@@ -13,3 +13,9 @@ my $date = "01/01/2002";
 my $newdate = &slashifyDate("2002-01-01");
 
 ok($date eq $newdate, 'slashifyDate');
+
+my $undef = undef;
+is(xml_escape($undef), '', 'xml_escape() returns empty string on undef input');
+my $str = q{'"&<>'};
+is(xml_escape($str), '&apos;&quot;&amp;&lt;&gt;&apos;', 'xml_escape() works as expected');
+is($str, q{'"&<>'}, '... and does not change input in place');
diff --git a/t/Members_AttributeTypes.t b/t/Members_AttributeTypes.t
new file mode 100755 (executable)
index 0000000..9dfc6c3
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Members::AttributeTypes');
+}
+
diff --git a/t/Members_Messaging.t b/t/Members_Messaging.t
new file mode 100755 (executable)
index 0000000..9395008
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Members::Messaging');
+}
+
diff --git a/t/Output_JSONStream.t b/t/Output_JSONStream.t
new file mode 100755 (executable)
index 0000000..2ee22fe
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Output::JSONStream');
+}
+
diff --git a/t/Patroncards_Batch.t b/t/Patroncards_Batch.t
new file mode 100755 (executable)
index 0000000..a0743ff
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Patroncards::Batch');
+}
+
diff --git a/t/Patroncards_Layout.t b/t/Patroncards_Layout.t
new file mode 100755 (executable)
index 0000000..fe68761
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Patroncards::Layout');
+}
+
diff --git a/t/Patroncards_Lib.t b/t/Patroncards_Lib.t
new file mode 100755 (executable)
index 0000000..88154a6
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Patroncards::Lib');
+}
+
diff --git a/t/Patroncards_Patroncard.t b/t/Patroncards_Patroncard.t
new file mode 100755 (executable)
index 0000000..8868350
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Patroncards::Patroncard');
+}
+
diff --git a/t/Patroncards_Profile.t b/t/Patroncards_Profile.t
new file mode 100755 (executable)
index 0000000..78cb6cf
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Patroncards::Profile');
+}
+
diff --git a/t/Patroncards_Template.t b/t/Patroncards_Template.t
new file mode 100755 (executable)
index 0000000..a781e0c
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Patroncards::Template');
+}
+
diff --git a/t/Reports_Guided.t b/t/Reports_Guided.t
new file mode 100755 (executable)
index 0000000..0b0cda6
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Reports::Guided');
+}
+
diff --git a/t/SIP_ILS.t b/t/SIP_ILS.t
new file mode 100755 (executable)
index 0000000..4a3ee70
--- /dev/null
@@ -0,0 +1,16 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use FindBin;
+        use lib "$FindBin::Bin/../C4/SIP";
+        use_ok('C4::SIP::ILS');
+}
+
diff --git a/t/SIP_Sip.t b/t/SIP_Sip.t
new file mode 100755 (executable)
index 0000000..50d1229
--- /dev/null
@@ -0,0 +1,16 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use FindBin;
+        use lib "$FindBin::Bin/../C4/SIP";
+        use_ok('C4::SIP::Sip');
+}
+
diff --git a/t/Search_PazPar2.t b/t/Search_PazPar2.t
new file mode 100755 (executable)
index 0000000..8d51720
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Search::PazPar2');
+}
+
diff --git a/t/VirtualShelves_Merge.t b/t/VirtualShelves_Merge.t
new file mode 100755 (executable)
index 0000000..954fdc4
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::VirtualShelves::Merge');
+}
+
diff --git a/t/VirtualShelves_Page.t b/t/VirtualShelves_Page.t
new file mode 100755 (executable)
index 0000000..236d147
--- /dev/null
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::VirtualShelves::Page');
+}
+
diff --git a/t/Z3950.t b/t/Z3950.t
new file mode 100644 (file)
index 0000000..4fb4c37
--- /dev/null
+++ b/t/Z3950.t
@@ -0,0 +1,14 @@
+#!/usr/bin/perl
+#
+# This Koha test module is a stub!  
+# Add more tests here!!!
+
+use strict;
+use warnings;
+
+use Test::More tests => 1;
+
+BEGIN {
+        use_ok('C4::Z3950');
+}
+
diff --git a/test/README b/test/README
new file mode 100644 (file)
index 0000000..fe2895c
--- /dev/null
@@ -0,0 +1,3 @@
+A collection of cgi and command line scripts that are useful for some testing,
+but for one reason or another cannot be made into automated test in t.
+Use with templates in koha-tmpl/intranet-tmpl/prog/en/modules/test
diff --git a/test/progressbar.pl b/test/progressbar.pl
new file mode 100755 (executable)
index 0000000..c994baa
--- /dev/null
@@ -0,0 +1,55 @@
+#!/usr/bin/perl
+
+# Script for testing progressbar, part 1 - initial screem
+# it is split into two scripts so we can use firebug to debug it
+
+# Koha library project  www.koha-community.org
+
+# Licensed under the GPL
+
+# Copyright 2010 Catalyst IT, Ltd
+#
+# This file is part of Koha.
+#
+# Koha is free software; you can redistribute it and/or modify it under the
+# terms of the GNU General Public License as published by the Free Software
+# Foundation; either version 2 of the License, or (at your option) any later
+# version.
+#
+# Koha is distributed in the hope that it will be useful, but WITHOUT ANY
+# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
+# A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with Koha; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+use strict;
+use warnings;
+
+# standard or CPAN modules used
+use CGI;
+use CGI::Cookie;
+
+# Koha modules used
+use C4::Context;
+use C4::Auth;
+use C4::Output;
+use C4::BackgroundJob;
+
+my $input = new CGI;
+my $dbh = C4::Context->dbh;
+$dbh->{AutoCommit} = 0;
+
+my ($template, $loggedinuser, $cookie)
+       = get_template_and_user({template_name => "test/progressbar.tmpl",
+                                       query => $input,
+                                       type => "intranet",
+                                       debug => 1,
+                                       });
+
+output_html_with_http_headers $input, $cookie, $template->output;
+
+exit 0;
+
+
diff --git a/test/progressbarsubmit.pl b/test/progressbarsubmit.pl
new file mode 100755 (executable)
index 0000000..22b0a41
--- /dev/null
@@ -0,0 +1,104 @@
+#!/usr/bin/perl
+
+# Script for testing progressbar, part 2 - json submit handler
+#   and Z39.50 lookups
+
+# Koha library project  www.koha-community.org
+
+# Licensed under the GPL
+
+# Copyright 2010  Catalyst IT, Ltd
+#
+# This file is part of Koha.
+#
+# Koha is free software; you can redistribute it and/or modify it under the
+# terms of the GNU General Public License as published by the Free Software
+# Foundation; either version 2 of the License, or (at your option) any later
+# version.
+#
+# Koha is distributed in the hope that it will be useful, but WITHOUT ANY
+# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
+# A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with Koha; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+use strict;
+use warnings;
+
+# standard or CPAN modules used
+use CGI;
+use CGI::Cookie;
+
+# Koha modules used
+use C4::Context;
+use C4::Auth;
+use C4::Output;
+use C4::BackgroundJob;
+
+my $input = new CGI;
+
+my $submitted=$input->param('submitted');
+my $runinbackground = $input->param('runinbackground');
+my $jobID = $input->param('jobID');
+my $completedJobID = $input->param('completedJobID');
+
+my ($template, $loggedinuser, $cookie)
+    = get_template_and_user({template_name => "test/progressbar.tmpl",
+                    query => $input,
+                    type => "intranet",
+                    debug => 1,
+                    });
+
+my %cookies = parse CGI::Cookie($cookie);
+my $sessionID = $cookies{'CGISESSID'}->value;
+if ($completedJobID) {
+} elsif ($submitted) {
+    my $job = undef;
+    if ($runinbackground) {
+        my $job_size = 100;
+        $job = C4::BackgroundJob->new($sessionID, undef, $ENV{'SCRIPT_NAME'}, $job_size);
+        $jobID = $job->id();
+
+        # fork off
+        if (my $pid = fork) {
+            # parent
+            # return job ID as JSON
+            
+            # prevent parent exiting from
+            # destroying the kid's database handle
+            # FIXME: according to DBI doc, this may not work for Oracle
+
+            my $reply = CGI->new("");
+            print $reply->header(-type => 'text/html');
+            print "{ jobID: '$jobID' }";
+            exit 0;
+        } elsif (defined $pid) {
+        # if we get here, we're a child that has detached
+        # itself from Apache
+
+            # close STDOUT to signal to Apache that
+            # we're now running in the background
+            close STDOUT;
+            close STDERR;
+
+            foreach (1..100) {
+                $job->progress( $_ );
+                sleep 1;
+            }
+            $job->finish();
+        } else {
+            # fork failed, so exit immediately
+            die "fork failed while attempting to run $ENV{'SCRIPT_NAME'} as a background job";
+        }
+
+    }
+} else {
+    # initial form
+    die "We should not be here";
+}
+
+exit 0;
+
+
diff --git a/test/search.pl b/test/search.pl
new file mode 100755 (executable)
index 0000000..4362791
--- /dev/null
@@ -0,0 +1,74 @@
+#!/usr/bin/perl -w
+
+use C4::Search;
+
+my @SEARCH = (
+    { operators => [
+          'and',
+          'and'
+      ],
+      operands => [
+          'shakespeare, "(william)"',
+          'dream'
+      ],
+      indexes => [
+          'au,wrdl',
+          'ti',
+          'kw'
+      ],
+      limits => [
+          'yr,st-numeric=2000-'
+      ],
+      sort_by => [
+          'relevance'
+      ],
+      lang => 'en',
+    },
+);
+
+
+foreach ( @SEARCH ) {
+    my ($expected, @mismatch);
+    my( $error,
+        $query,
+        $simple_query,
+        $query_cgi,
+        $query_desc,
+        $limit,
+        $limit_cgi,
+        $limit_desc,
+        $stopwords_removed,
+        $query_type )
+      = buildQuery( $_->{operators}, $_->{operands}, $_->{indexes}, $_->{limits}, $_->{sort_by}, 0,  $_->{lang} );
+
+    die $error if $error;
+
+    $expected = $_->{query};
+    push @mismatch, "Query: $query (not: $expected)" unless $query eq $expected;
+
+    $expected = $_->{simple_query};
+    push @mismatch, "Simple Query: $simple_query (not: $expected)" unless $simple_query eq $expected;
+
+    $expected = $_->{query_cgi};
+    push @mismatch, "Query CGI: $query_cgi (not: $expected)" unless $query_cgi eq $expected;
+
+    $expected = $_->{query_desc};
+    push @mismatch, "Query desc: $query_desc (not: $expected)" unless $query_desc eq $expected;
+
+    $expected = $_->{limit};
+    push @mismatch, "Limit: $limit (not: $expected)" unless $limit eq $expected;
+
+    $expected = $_->{limit_cgi};
+    push @mismatch, "Limit CGI: $limit_cgi (not: $expected)" unless $limit_cgi eq $expected;
+
+    $expected = $_->{limit_desc};
+    push @mismatch, "Limit desc: $limit_desc (not: $expected)" unless $limit_desc eq $expected;
+
+    $expected = $_->{stopwords_removed};
+    push @mismatch, "Stopwords removed: $stopwords_removed (not: $expected)" unless $stopwords_removed eq $expected;
+
+    $expected = $_->{query_type};
+    push @mismatch, "Query Type: $query_type (not: $expected)" unless $query_type eq $expected;
+
+    die map "$_\n", @mismatch if @mismatch;
+}
index a6afcaa..eb3bc9c 100755 (executable)
@@ -64,6 +64,7 @@ my $onlymine=(C4::Context->preference('IndependantBranches') &&
 if ( $onlymine ) { 
     $branch = C4::Context->userenv->{'branch'};
 }
+my $branchname = GetBranchName($branch);
 my $branches = GetBranches($onlymine);
 my @branchloop;
 for my $thisbranch (sort { $branches->{$a}->{branchname} cmp $branches->{$b}->{branchname} } keys %$branches) {
@@ -136,15 +137,16 @@ foreach my $yearMonthDay (keys %$single_holidays) {
 }
 
 $template->param(WEEK_DAYS_LOOP => \@week_days,
-                               branchloop => \@branchloop, 
-                               HOLIDAYS_LOOP => \@holidays,
-                               EXCEPTION_HOLIDAYS_LOOP => \@exception_holidays,
-                               DAY_MONTH_HOLIDAYS_LOOP => \@day_month_holidays,
-                               calendardate => $calendardate,
-                               keydate => $keydate,
-                               branchcodes => $branchcodes,
-                               branch => $branch
-       );
+        branchloop => \@branchloop, 
+        HOLIDAYS_LOOP => \@holidays,
+        EXCEPTION_HOLIDAYS_LOOP => \@exception_holidays,
+        DAY_MONTH_HOLIDAYS_LOOP => \@day_month_holidays,
+        calendardate => $calendardate,
+        keydate => $keydate,
+        branchcodes => $branchcodes,
+        branch => $branch,
+        branchname => $branchname
+  );
 
 # Shows the template with the real values replaced
 output_html_with_http_headers $input, $cookie, $template->output;