my $data = $sth->fetchrow_hashref;
$sth->finish;
- my $sth = $dbh->prepare("UPDATE accountlines
+ $sth = $dbh->prepare("UPDATE accountlines
SET amountoutstanding = 0
WHERE borrowernumber = ?
AND accountno = ?");
# create new line
my $payment = 0 - $amount;
- my $sth = $dbh->prepare("INSERT INTO accountlines
+ $sth = $dbh->prepare("INSERT INTO accountlines
(borrowernumber, accountno, date, amount,
description, accounttype, amountoutstanding)
VALUES (?,?,now(),?,?,'Pay',0)");
my $output;
# TODO: Translate headers
- my @headers = qw(contractname ordernumber line entrydate isbn author title publishercode collectiontitle notes quantity rrp);
+ my @headers = qw(contractname ordernumber entrydate isbn author title publishercode collectiontitle notes quantity rrp);
$csv->combine(@headers);
$output = $csv->string() . "\n";
my @rows;
foreach my $order (@orders) {
my @cols;
- my $bd = GetBiblioData($order->{'biblionumber'});
+ # newlines are not valid characters for Text::CSV combine()
+ $order->{'notes'} =~ s/[\r\n]+//g;
push(@cols,
$contract->{'contractname'},
$order->{'ordernumber'},
$order->{'entrydate'},
$order->{'isbn'},
- $bd->{'author'},
- $bd->{'title'},
- $bd->{'publishercode'},
- $bd->{'collectiontitle'},
+ $order->{'author'},
+ $order->{'title'},
+ $order->{'publishercode'},
+ $order->{'collectiontitle'},
$order->{'notes'},
$order->{'quantity'},
$order->{'rrp'},
push (@rows, \@cols);
}
- # Sort by publishercode
- # TODO: Sort by publishercode then by title
- @rows = sort { @$a[7] cmp @$b[7] } @rows;
-
foreach my $row (@rows) {
$csv->combine(@$row);
$output .= $csv->string() . "\n";
OR datereceived IS NULL
OR aqorders.quantityreceived < aqorders.quantity
)
+ AND (aqorders.datecancellationprinted IS NULL OR aqorders.datecancellationprinted='0000-00-00')
";
my $having = "";
if ($dbdriver eq "mysql") {
my $in = shift;
my $template =
gettemplate( $in->{'template_name'}, $in->{'type'}, $in->{'query'} );
- my ( $user, $cookie, $sessionID, $flags ) = checkauth(
- $in->{'query'},
- $in->{'authnotrequired'},
- $in->{'flagsrequired'},
- $in->{'type'}
- ) unless ($in->{'template_name'}=~/maintenance/);
+ my ( $user, $cookie, $sessionID, $flags );
+ if ( $in->{'template_name'} !~m/maintenance/ ) {
+ ( $user, $cookie, $sessionID, $flags ) = checkauth(
+ $in->{'query'},
+ $in->{'authnotrequired'},
+ $in->{'flagsrequired'},
+ $in->{'type'}
+ );
+ }
my $borrowernumber;
my $insecure = C4::Context->preference('insecure');
"BiblioDefaultView".C4::Context->preference("BiblioDefaultView") => 1,
EnhancedMessagingPreferences => C4::Context->preference('EnhancedMessagingPreferences'),
GoogleJackets => C4::Context->preference("GoogleJackets"),
+ OpenLibraryCovers => C4::Context->preference("OpenLibraryCovers"),
KohaAdminEmailAddress => "" . C4::Context->preference("KohaAdminEmailAddress"),
LoginBranchcode => (C4::Context->userenv?C4::Context->userenv->{"branch"}:"insecure"),
LoginFirstname => (C4::Context->userenv?C4::Context->userenv->{"firstname"}:"Bel"),
opacuserlogin => "" . C4::Context->preference("opacuserlogin"),
reviewson => C4::Context->preference("reviewson"),
ShowReviewer => C4::Context->preference("ShowReviewer"),
+ ShowReviewerPhoto => C4::Context->preference("ShowReviewerPhoto"),
suggestion => "" . C4::Context->preference("suggestion"),
virtualshelves => "" . C4::Context->preference("virtualshelves"),
OPACSerialIssueDisplayCount => C4::Context->preference("OPACSerialIssueDisplayCount"),
my $userid = shift or return;
my $uid_field = $mapping{userid}->{is} or die ldapserver_error("mapping for 'userid'");
my $filter = Net::LDAP::Filter->new("$uid_field=$userid") or die "Failed to create new Net::LDAP::Filter";
- my $res = ($config{anonymous}) ? $db->bind : $db->bind($ldapname, password=>$ldappassword);
- if ($res->code) { # connection refused
- warn "LDAP bind failed as ldapuser " . ($ldapname || '[ANONYMOUS]') . ": " . description($res);
- return 0;
- }
my $search = $db->search(
base => $base,
filter => $filter,
}
# FIXME dpavlin -- we really need $userldapentry leater on even if using auth_by_bind!
- my $search = search_method($db, $userid) or return 0; # warnings are in the sub
- $userldapentry = $search->shift_entry;
+
+ # BUG #5094
+ # 2010-08-04 JeremyC
+ # a $userldapentry is only needed if either updating or replicating are enabled
+ if($config{update} or $config{replicate}) {
+ my $search = search_method($db, $userid) or return 0; # warnings are in the sub
+ $userldapentry = $search->shift_entry;
+ }
} else {
+ my $res = ($config{anonymous}) ? $db->bind : $db->bind($ldapname, password=>$ldappassword);
+ if ($res->code) { # connection refused
+ warn "LDAP bind failed as ldapuser " . ($ldapname || '[ANONYMOUS]') . ": " . description($res);
+ return 0;
+ }
my $search = search_method($db, $userid) or return 0; # warnings are in the sub
$userldapentry = $search->shift_entry;
my $cmpmesg = $db->compare( $userldapentry, attr=>'userpassword', value => $password );
if (C4::Context->preference('ExtendedPatronAttributes') && $borrowernumber && ($config{update} ||$config{replicate})) {
my @types = C4::Members::AttributeTypes::GetAttributeTypes();
my @attributes = grep{my $key=$_; any{$_ eq $key}@types;} keys %borrower;
- my $extended_patron_attributes = map{{code=>$_,value=>$borrower{$_}}}@attributes;
- my $extended_patron_attributes = [] unless $extended_patron_attributes;
+ my $extended_patron_attributes;
+ @{$extended_patron_attributes} =
+ map { { code => $_, value => $borrower{$_} } } @attributes;
my @errors;
#Check before add
for (my $i; $i< scalar(@$extended_patron_attributes)-1;$i++) {
$debug and print STDERR "Finsihed \%memberhash has ", scalar(keys %memberhash), " keys\n",
"Referencing \%mapping with ", scalar(keys %mapping), " keys\n";
foreach my $key (keys %mapping) {
- my $data = $memberhash{$mapping{$key}->{is}};
+ my $data = $memberhash{ lc($mapping{$key}->{is}) }; # Net::LDAP returns all names in lowercase
$debug and printf STDERR "mapping %20s ==> %-20s (%s)\n", $key, $mapping{$key}->{is}, $data;
unless (defined $data) {
$data = $mapping{$key}->{content} || ''; # default or failsafe ''
} elsif ($record->field('148')) {
$heading.= $field->as_string('abvxyz68');
} elsif ($record->field('150')) {
- # $heading.= $field->as_string('abvxyz68');
- $heading.= $field->as_formatted();
+ $heading.= $field->as_string('abvxyz68');
+ #$heading.= $field->as_formatted();
my $tag=$field->tag();
$heading=~s /^$tag//g;
$heading =~s /\_/\$/g;
} else {
#zebra connection
my $oConnection=C4::Context->Zconn("biblioserver",0);
+ my $oldSyntax = $oConnection->option("preferredRecordSyntax");
$oConnection->option("preferredRecordSyntax"=>"XML");
my $query;
$query= "an=".$mergefrom;
push @reccache, $marcdata;
$z++;
}
- $oConnection->destroy();
+ $oResult->destroy();
+ $oConnection->option("preferredRecordSyntax"=>$oldSyntax);
}
#warn scalar(@reccache)." biblios to update";
# Get All candidate Tags for the change
use strict;
use warnings;
+use Carp;
# use utf8;
use MARC::Record;
sub ModBiblio {
my ( $record, $biblionumber, $frameworkcode ) = @_;
+ croak "No record" unless $record;
+
if ( C4::Context->preference("CataloguingLog") ) {
my $newrecord = GetMarcBiblio($biblionumber);
logaction( "CATALOGUING", "MODIFY", $biblionumber, "BEFORE=>" . $newrecord->as_formatted );
if ( C4::Context->preference("marcflavour") eq "UNIMARC" ) {
# Setting datas
- $aulast = $record->subfield( '700', 'a' );
- $aufirst = $record->subfield( '700', 'b' );
+ $aulast = $record->subfield( '700', 'a' ) || '';
+ $aufirst = $record->subfield( '700', 'b' ) || '';
$oauthors = "&rft.au=$aufirst $aulast";
# others authors
( $mtx eq 'dc' )
? "&rft.title=" . $record->subfield( '200', 'a' )
: "&rft.title=" . $record->subfield( '200', 'a' ) . "&rft.btitle=" . $record->subfield( '200', 'a' );
- $pubyear = $record->subfield( '210', 'd' );
- $publisher = $record->subfield( '210', 'c' );
- $isbn = $record->subfield( '010', 'a' );
- $issn = $record->subfield( '011', 'a' );
+ $pubyear = $record->subfield( '210', 'd' ) || '';
+ $publisher = $record->subfield( '210', 'c' ) || '';
+ $isbn = $record->subfield( '010', 'a' ) || '';
+ $issn = $record->subfield( '011', 'a' ) || '';
} else {
# MARC21 need some improve
my $value = $subject_subfield->[1];
my $linkvalue = $value;
$linkvalue =~ s/(\(|\))//g;
- my $operator = " and " unless $counter == 0;
+ my $operator;
+ if ( $counter != 0 ) {
+ $operator = ' and ';
+ }
if ( $code eq 9 ) {
$found9 = 1;
@link_loop = ( { 'limit' => 'an', link => "$linkvalue" } );
if ( not $found9 ) {
push @link_loop, { 'limit' => $subject_limit, link => $linkvalue, operator => $operator };
}
- my $separator = C4::Context->preference("authoritysep") unless $counter == 0;
+ my $separator;
+ if ( $counter != 0 ) {
+ $separator = C4::Context->preference('authoritysep');
+ }
# ignore $9
my @this_link_loop = @link_loop;
my $value = $authors_subfield->[1];
my $linkvalue = $value;
$linkvalue =~ s/(\(|\))//g;
- my $operator = " and " unless $count_auth == 0;
+ my $operator;
+ if ( $count_auth != 0 ) {
+ $operator = ' and ';
+ }
# if we have an authority link, use that as the link, otherwise use standard searching
if ($subfield9) {
$value = GetAuthorisedValueDesc( $field->tag(), $authors_subfield->[0], $authors_subfield->[1], '', $tagslib )
if ( $marcflavour eq 'UNIMARC' and ( $authors_subfield->[0] =~ /4/ ) );
my @this_link_loop = @link_loop;
- my $separator = C4::Context->preference("authoritysep") unless $count_auth == 0;
- push @subfields_loop, { code => $subfieldcode, value => $value, link_loop => \@this_link_loop, separator => $separator } unless ( $authors_subfield->[0] eq '9' );
+ my $separator;
+ if ( $count_auth != 0 ) {
+ $separator = C4::Context->preference('authoritysep');
+ }
+ push @subfields_loop,
+ { code => $subfieldcode,
+ value => $value,
+ link_loop => \@this_link_loop,
+ separator => $separator
+ }
+ unless ( $authors_subfield->[0] eq '9' );
$count_auth++;
}
push @marcauthors, { MARCAUTHOR_SUBFIELDS_LOOP => \@subfields_loop };
my $value = $series_subfield->[1];
my $linkvalue = $value;
$linkvalue =~ s/(\(|\))//g;
- my $operator = " and " unless $counter == 0;
- push @link_loop, { link => $linkvalue, operator => $operator };
- my $separator = C4::Context->preference("authoritysep") unless $counter == 0;
+ if ( $counter != 0 ) {
+ push @link_loop, { link => $linkvalue, operator => ' and ', };
+ } else {
+ push @link_loop, { link => $linkvalue, operator => undef, };
+ }
+ my $separator;
+ if ( $counter != 0 ) {
+ $separator = C4::Context->preference('authoritysep');
+ }
if ($volume_number) {
push @subfields_loop, { volumenum => $value };
} else {
- push @subfields_loop, { code => $code, value => $value, link_loop => \@link_loop, separator => $separator, volumenum => $volume_number } unless ( $series_subfield->[0] eq '9' );
+ if ( $series_subfield->[0] ne '9' ) {
+ push @subfields_loop, {
+ code => $code,
+ value => $value,
+ link_loop => \@link_loop,
+ separator => $separator,
+ volumenum => $volume_number,
+ };
+ }
}
$counter++;
}
my $tagslib = &GetMarcStructure( 1, $frameworkcode );
# return nothing if we don't have found an existing framework.
- return "" unless $tagslib;
- my $itemrecord = C4::Items::GetMarcItem( $bibnum, $itemnum ) if ($itemnum);
+ return q{} unless $tagslib;
+ my $itemrecord;
+ if ($itemnum) {
+ $itemrecord = C4::Items::GetMarcItem( $bibnum, $itemnum );
+ }
my @loop_data;
my $authorised_values_sth = $dbh->prepare( "SELECT authorised_value,lib FROM authorised_values WHERE category=? ORDER BY lib" );
foreach my $tag ( sort keys %{$tagslib} ) {
&& C4::Context->preference('itemcallnumber') ) {
my $CNtag = substr( C4::Context->preference('itemcallnumber'), 0, 3 );
my $CNsubfield = substr( C4::Context->preference('itemcallnumber'), 3, 1 );
- my $temp = $itemrecord->field($CNtag) if ($itemrecord);
- if ($temp) {
- $defaultvalue = $temp->subfield($CNsubfield);
+ if ($itemrecord) {
+ my $temp = $itemrecord->field($CNtag);
+ if ($temp) {
+ $defaultvalue = $temp->subfield($CNsubfield);
+ }
}
}
if ( $tagslib->{$tag}->{$subfield}->{kohafield} eq 'items.itemcallnumber'
&& $defaultvalues
&& $defaultvalues->{'callnumber'} ) {
- my $temp = $itemrecord->field($subfield) if ($itemrecord);
+ my $temp;
+ if ($itemrecord) {
+ $temp = $itemrecord->field($subfield);
+ }
unless ($temp) {
$defaultvalue = $defaultvalues->{'callnumber'} if $defaultvalues;
}
if ( ( $tagslib->{$tag}->{$subfield}->{kohafield} eq 'items.holdingbranch' || $tagslib->{$tag}->{$subfield}->{kohafield} eq 'items.homebranch' )
&& $defaultvalues
&& $defaultvalues->{'branchcode'} ) {
- my $temp = $itemrecord->field($subfield) if ($itemrecord);
+ my $temp;
+ if ($itemrecord) {
+ $temp = $itemrecord->field($subfield);
+ }
unless ($temp) {
$defaultvalue = $defaultvalues->{branchcode} if $defaultvalues;
}
}
}
}
- my $itemnumber = $itemrecord->subfield( $itemtagfield, $itemtagsubfield )
- if ( $itemrecord && $itemrecord->field($itemtagfield) );
+ my $itemnumber;
+ if ( $itemrecord && $itemrecord->field($itemtagfield) ) {
+ $itemnumber = $itemrecord->subfield( $itemtagfield, $itemtagsubfield );
+ }
return {
'itemtagfield' => $itemtagfield,
'itemtagsubfield' => $itemtagsubfield,
sub EmbedItemsInMarcBiblio {
my ($marc, $biblionumber) = @_;
+ croak "No MARC record" unless $marc;
my $frameworkcode = GetFrameworkCode($biblionumber);
_strip_item_fields($marc, $frameworkcode);
# drop old field and create new one...
$old_field = $record->field($biblio_tag);
$record->delete_field($old_field) if $old_field;
- $record->append_fields($new_field);
+ $record->insert_fields_ordered($new_field);
# deal with biblioitemnumber
if ( $biblioitem_tag < 10 ) {
}
substr( $string, 22, 6, "frey50" );
unless ( $record->subfield( 100, "a" ) ) {
- $record->insert_grouped_field( MARC::Field->new( 100, "", "", "a" => $string ) );
+ $record->insert_fields_ordered( MARC::Field->new( 100, "", "", "a" => $string ) );
}
}
# add budget-percent and allocation, and flags for html-template
foreach my $r (@sort) {
my $subs_href = $r->{'child'};
- my @subs_arr = @$subs_href if defined $subs_href;
+ my @subs_arr = ();
+ if ( defined $subs_href ) {
+ @subs_arr = @{$subs_href};
+ }
my $moo = $r->{'budget_code_indent'};
$moo =~ s/\ /\ \;/g;
return $result;
}
-=head2 GetBudgets
+=head2 GetChildBudgetsSpent
- &GetBudgets($filter, $order_by);
+ &GetChildBudgetsSpent($budget-id);
-gets all budgets
+gets the total spent of the level and sublevels of $budget_id
=cut
return $total_spent;
}
-=head2 GetChildBudgetsSpent
+=head2 GetBudgets
- &GetChildBudgetsSpent($budget-id);
+ &GetBudgets($filter, $order_by);
-gets the total spent of the level and sublevels of $budget_id
+gets all budgets
=cut
my ($type, $item, $borrower, $branch) =
($opts->{type}, $opts->{item}, $opts->{borrower}, $opts->{branch});
my %message_name = (
- CHECKIN => 'Item Check-in',
- CHECKOUT => 'Item Checkout',
+ CHECKIN => 'Item_Check_in',
+ CHECKOUT => 'Item_Checkout',
);
my $borrower_preferences = C4::Members::Messaging::GetMessagingPreferences({
borrowernumber => $borrower->{borrowernumber},
# Get the biblioitem from the biblionumber
my $biblioitem = ( GetBiblioItemByBiblioNumber( $biblionumber, undef ) )[0];
if ( not $biblioitem->{'biblionumber'} ) {
- $biblioitem = "RecordNotFound";
+ $biblioitem->{code} = "RecordNotFound";
}
# We don't want MARC to be displayed
delete $biblioitem->{'marc'};
- # nor the XML declaration of MARCXML
- $biblioitem->{'marcxml'} =~ s/<\?xml version="1.0" encoding="UTF-8"\?>//go;
-
# Get most of the needed data
my $biblioitemnumber = $biblioitem->{'biblioitemnumber'};
my @reserves = GetReservesFromBiblionumber( $biblionumber, undef, undef );
$biblioitem->{'reserves'}->{'reserve'} = $reserves[1];
$biblioitem->{'issues'}->{'issue'} = $issues;
- map { $biblioitem->{$_} = encode_entities( $biblioitem->{$_}, '&' ) } grep( !/marcxml/, keys %$biblioitem );
-
push @records, $biblioitem;
}
return { code => 'UnsupportedSchema' };
}
- my $records;
+ my @records;
# Let's loop over the authority IDs
foreach my $authid ( split( / /, $cgi->param('id') ) ) {
# Get the record as XML string, or error code
- my $record = GetAuthorityXML($authid) || "<record><code>RecordNotFound</code></record>";
- $record =~ s/<\?xml(.*)\?>//go;
- $records .= $record;
+ push @records, GetAuthorityXML($authid) || { code => 'RecordNotFound' };
}
- return $records;
+ return { record => \@records };
}
=head2 LookupPatron
'Graphics::Magick' => {
'usage' => 'Patron Card Creator Feature',
'required' => '0',
- 'min_ver' => '1.3.5'
+ 'min_ver' => '1.3.05'
},
'MARC::Charset' => {
'usage' => 'Core',
'required' => '1',
'min_ver' => '2.22',
},
+ 'Gravatar::URL' => {
+ 'usage' => 'Photos in OPAC reviews',
+ 'required' => '0',
+ 'min_ver' => '1.03',
+ },
};
1;
=head2 GetItemsInfo
- @results = GetItemsInfo($biblionumber, $type);
+ @results = GetItemsInfo($biblionumber);
-Returns information about books with the given biblionumber.
-
-C<$type> may be either C<intra> or anything else. If it is not set to
-C<intra>, then the search will exclude lost, very overdue, and
-withdrawn items.
+Returns information about items with the given biblionumber.
C<GetItemsInfo> returns a list of references-to-hash. Each element
-contains a number of keys. Most of them are table items from the
+contains a number of keys. Most of them are attributes from the
C<biblio>, C<biblioitems>, C<items>, and C<itemtypes> tables in the
Koha database. Other keys include:
=cut
sub GetItemsInfo {
- my ( $biblionumber, $type ) = @_;
+ my ( $biblionumber ) = @_;
my $dbh = C4::Context->dbh;
# note biblioitems.* must be avoided to prevent large marc and marcxml fields from killing performance.
my $query = "
my $format_string = shift;
my $csv = Text::CSV_XS->new({allow_whitespace => 1});
my $status = $csv->parse($format_string);
- my @sorted_fields = map {{ 'code' => $_, desc => $_ }} $csv->fields();
+ my @sorted_fields = map {{ 'code' => $_, desc => $_ }}
+ map { $_ eq 'callnumber' ? 'itemcallnumber' : $_ } # see bug 5653
+ $csv->fields();
my $error = $csv->error_input();
warn sprintf('Text field sort failed with this error: %s', $error) if $error;
return \@sorted_fields;
$letter->{content} =~ s/<<LibrarianSurname>>/$userenv->{surname}/g;
$letter->{content} =~
s/<<LibrarianEmailaddress>>/$userenv->{emailaddress}/g;
- foreach my $data (@$dataorders) {
- my $line = $1 if ( $letter->{content} =~ m/(<<.*>>)/ );
- foreach my $field ( keys %$data ) {
- $line =~ s/(<<[^\.]+.$field>>)/$data->{$field}/;
+ foreach my $data ( @{$dataorders} ) {
+ if ( $letter->{content} =~ m/(<<.*>>)/ ) {
+ my $line = $1;
+ foreach my $field ( keys %{$data} ) {
+ $line =~ s/(<<[^\.]+.$field>>)/$data->{$field}/;
+ }
+ $letter->{content} =~ s/(<<.*>>)/$line\n$1/;
}
- $letter->{content} =~ s/(<<.*>>)/$line\n$1/;
}
$letter->{content} =~ s/<<[^>]*>>//g;
my $innerletter = $letter;
$letter->{content} =~ s/<<LibrarianSurname>>/$userenv->{surname}/g;
$letter->{content} =~
s/<<LibrarianEmailaddress>>/$userenv->{emailaddress}/g;
- foreach my $data (@$dataorders) {
- my $line = $1 if ( $letter->{content} =~ m/(<<.*>>)/ );
- foreach my $field ( keys %$data ) {
- $line =~ s/(<<[^\.]+.$field>>)/$data->{$field}/;
+ foreach my $data ( @{$dataorders} ) {
+ if ( $letter->{content} =~ m/(<<.*>>)/ ) {
+ my $line = $1;
+ foreach my $field ( keys %{$data} ) {
+ $line =~ s/(<<[^\.]+.$field>>)/$data->{$field}/;
+ }
+ $letter->{content} =~ s/(<<.*>>)/$line\n$1/;
}
- $letter->{content} =~ s/(<<.*>>)/$line\n$1/;
}
$letter->{content} =~ s/<<[^>]*>>//g;
my $innerletter = $letter;
($table eq 'biblio' ) ? "SELECT * FROM $table WHERE biblionumber = ?" :
($table eq 'biblioitems' ) ? "SELECT * FROM $table WHERE biblionumber = ?" :
($table eq 'items' ) ? "SELECT * FROM $table WHERE itemnumber = ?" :
+ ($table eq 'issues' ) ? "SELECT * FROM $table WHERE itemnumber = ?" :
+ ($table eq 'suggestions' ) ? "SELECT * FROM $table WHERE borrowernumber = ? and biblionumber = ?" :
($table eq 'reserves' ) ? "SELECT * FROM $table WHERE borrowernumber = ? and biblionumber = ?" :
($table eq 'borrowers' ) ? "SELECT * FROM $table WHERE borrowernumber = ?" :
($table eq 'branches' ) ? "SELECT * FROM $table WHERE branchcode = ?" :
my @parameters;
$query .= " AND DATE_FORMAT(timestamp, '%Y-%m-%d') >= \"".$iso_datefrom."\" " if $iso_datefrom; #fix me - mysql specific
$query .= " AND DATE_FORMAT(timestamp, '%Y-%m-%d') <= \"".$iso_dateto."\" " if $iso_dateto;
- if($user) {
+ if($user ne "") {
$query .= " AND user = ? ";
push(@parameters,$user);
}
}
}
my $execute_success=UpdateInTable("borrowers",\%data);
-# ok if its an adult (type) it may have borrowers that depend on it as a guarantor
-# so when we update information for an adult we should check for guarantees and update the relevant part
-# of their records, ie addresses and phone numbers
- my $borrowercategory= GetBorrowercategory( $data{'category_type'} );
- if ( exists $borrowercategory->{'category_type'} && $borrowercategory->{'category_type'} eq ('A' || 'S') ) {
- # is adult check guarantees;
- UpdateGuarantees(%data);
+ if ($execute_success) { # only proceed if the update was a success
+ # ok if its an adult (type) it may have borrowers that depend on it as a guarantor
+ # so when we update information for an adult we should check for guarantees and update the relevant part
+ # of their records, ie addresses and phone numbers
+ my $borrowercategory= GetBorrowercategory( $data{'category_type'} );
+ if ( exists $borrowercategory->{'category_type'} && $borrowercategory->{'category_type'} eq ('A' || 'S') ) {
+ # is adult check guarantees;
+ UpdateGuarantees(%data);
+ }
+ logaction("MEMBERS", "MODIFY", $data{'borrowernumber'}, "UPDATE (executed w/ arg: $data{'borrowernumber'})") if C4::Context->preference("BorrowersLog");
}
- logaction("MEMBERS", "MODIFY", $data{'borrowernumber'}, "UPDATE (executed w/ arg: $data{'borrowernumber'})")
- if C4::Context->preference("BorrowersLog");
-
return $execute_success;
}
$borrowernumber = &AddMember(%borrower);
insert new borrower into table
-Returns the borrowernumber
+Returns the borrowernumber upon success
+
+Returns as undef upon any db error without further processing
=cut
sub AddMember {
my (%data) = @_;
my $dbh = C4::Context->dbh;
- $data{'userid'} = '' unless $data{'password'};
- $data{'password'} = md5_base64( $data{'password'} ) if $data{'password'};
+ # generate a proper login if none provided
+ $data{'userid'} = Generate_Userid($data{'borrowernumber'}, $data{'firstname'}, $data{'surname'}) if $data{'userid'} eq '';
+ # create a disabled account if no password provided
+ $data{'password'} = ($data{'password'})? md5_base64($data{'password'}) : '!';
$data{'borrowernumber'}=InsertInTable("borrowers",\%data);
# mysql_insertid is probably bad. not necessarily accurate and mysql-specific at best.
logaction("MEMBERS", "CREATE", $data{'borrowernumber'}, "") if C4::Context->preference("BorrowersLog");
my $sth = $dbh->prepare("SELECT enrolmentfee FROM categories WHERE categorycode=?");
$sth->execute($data{'categorycode'});
my ($enrolmentfee) = $sth->fetchrow;
+ if ($sth->err) {
+ warn sprintf('Database returned the following error: %s', $sth->errstr);
+ return;
+ }
if ($enrolmentfee && $enrolmentfee > 0) {
# insert fee in patron debts
manualinvoice($data{'borrowernumber'}, '', '', 'A', $enrolmentfee);
}
+
return $data{'borrowernumber'};
}
LEFT JOIN items on items.itemnumber=old_issues.itemnumber
LEFT JOIN biblio ON items.biblionumber=biblio.biblionumber
LEFT JOIN biblioitems ON items.biblioitemnumber=biblioitems.biblioitemnumber
- WHERE borrowernumber=?
+ WHERE borrowernumber=? AND old_issues.itemnumber IS NOT NULL
order by $order";
if ( $limit != 0 ) {
$query .= " limit $limit";
$sth->execute( @bind );
my $total = 0;
while ( my $data = $sth->fetchrow_hashref ) {
- my $biblio = GetBiblioFromItemNumber($data->{itemnumber}) if $data->{itemnumber};
- $data->{biblionumber} = $biblio->{biblionumber};
- $data->{title} = $biblio->{title};
+ if ( $data->{itemnumber} ) {
+ my $biblio = GetBiblioFromItemNumber( $data->{itemnumber} );
+ $data->{biblionumber} = $biblio->{biblionumber};
+ $data->{title} = $biblio->{title};
+ }
$acctlines[$numlines] = $data;
$numlines++;
$total += int(1000 * $data->{'amountoutstanding'}); # convert float to integer to avoid round-off errors
sub checkcardnumber {
my ($cardnumber,$borrowernumber) = @_;
+ # If cardnumber is null, we assume they're allowed.
+ return 0 if !defined($cardnumber);
my $dbh = C4::Context->dbh;
my $query = "SELECT * FROM borrowers WHERE cardnumber=?";
$query .= " AND borrowernumber <> ?" if ($borrowernumber);
my $dbh = C4::Context->dbh;
my $sth =
$dbh->prepare(
- "select city_name,city_zipcode from cities where cityid=? ");
+ "select city_name,city_state,city_zipcode,city_country from cities where cityid=? ");
$sth->execute($cityid);
my @data = $sth->fetchrow;
- return $data[0], $data[1];
+ return $data[0], $data[1], $data[2], $data[3];
}
my $dbh = C4::Context->dbh;
my $city_arr = $dbh->selectall_arrayref(
- q|SELECT cityid,city_zipcode,city_name FROM cities ORDER BY city_name|,
+ q|SELECT cityid,city_zipcode,city_name,city_state,city_country FROM cities ORDER BY city_name|,
{ Slice => {} });
if ( @{$city_arr} ) {
unshift @{$city_arr}, {
city_zipcode => q{},
city_name => q{},
cityid => q{},
+ city_state => q{},
+ city_country => q{},
};
}
foreach my $attr (@$attr_list) {
$attr->{password} = undef unless exists $attr->{password};
$sth->execute($borrowernumber, $attr->{code}, $attr->{value}, $attr->{password});
+ if ($sth->err) {
+ warn sprintf('Database returned the following error: %s', $sth->errstr);
+ return; # bail immediately on errors
+ }
}
+ return 1; # borower attributes successfully set
}
=head2 extended_attributes_code_value_arrayref
sub marc2endnote {
my ($marc) = @_;
my $marc_rec_obj = MARC::Record->new_from_usmarc($marc);
- my $f260 = $marc_rec_obj->field('260');
- my $f260a = $f260->subfield('a') if $f260;
+ my ( $abstract, $f260a, $f710a );
+ my $f260 = $marc_rec_obj->field('260');
+ if ($f260) {
+ $f260a = $f260->subfield('a') if $f260;
+ }
my $f710 = $marc_rec_obj->field('710');
- my $f710a = $f710->subfield('a') if $f710;
- my $f500 = $marc_rec_obj->field('500');
- my $abstract = $f500->subfield('a') if $f500;
+ if ($f710) {
+ $f710a = $f710->subfield('a');
+ }
+ my $f500 = $marc_rec_obj->field('500');
+ if ($f500) {
+ $abstract = $f500->subfield('a');
+ }
my $fields = {
DB => C4::Context->preference("LibraryName"),
Title => $marc_rec_obj->title(),
my $dbh = C4::Context->dbh;
my $borrower = C4::Members::GetMember(borrowernumber => $borrowernumber);
+
+ # Try to get the borrower's email address
+ my $to_address;
+ my $which_address = C4::Context->preference('AutoEmailPrimaryAddress');
+ # If the system preference is set to 'first valid' (value == OFF), look up email address
+ if ($which_address eq 'OFF') {
+ $to_address = C4::Members::GetFirstValidEmailAddress( $borrowernumber );
+ } else {
+ $to_address = $borrower->{$which_address};
+ }
+
my $letter_code;
my $print_mode = 0;
my $messagingprefs;
- if ( $borrower->{'email'} || $borrower->{'smsalertnumber'} ) {
- $messagingprefs = C4::Members::Messaging::GetMessagingPreferences( { borrowernumber => $borrowernumber, message_name => 'Hold Filled' } );
+ if ( $to_address || $borrower->{'smsalertnumber'} ) {
+ $messagingprefs = C4::Members::Messaging::GetMessagingPreferences( { borrowernumber => $borrowernumber, message_name => 'Hold_Filled' } );
return if ( !defined( $messagingprefs->{'letter_code'} ) );
$letter_code = $messagingprefs->{'letter_code'};
($trans_date) = @{$self->{fixed_fields}};
- $ils->check_inst_id($fields->{FID_INST_ID}, "handle_end_patron_session");
+ $ils->check_inst_id($fields->{(FID_INST_ID)}, 'handle_end_patron_session');
($status, $screen_msg, $print_line) = $ils->end_patron_session($fields->{(FID_PATRON_ID)});
($reservestatus, $reserveitem) = C4::Reserves::CheckReserves($item->{itemnumber});
}
- # item is withdrawn, lost or damaged
+ # item is withdrawn, lost, damaged, not for loan, reserved or in transit
if ( $item->{wthdrawn}
|| $item->{itemlost}
|| $item->{damaged}
$item_in_transit_count++ if $transfertwhen ne '';
$item_onhold_count++ if $reservestatus eq 'Waiting';
$item->{status} = $item->{wthdrawn} . "-" . $item->{itemlost} . "-" . $item->{damaged} . "-" . $item->{notforloan};
+
+ # can place hold on item ?
+ if ((!$item->{damaged} || C4::Context->preference('AllowHoldsOnDamagedItems'))
+ && !$item->{itemlost}
+ && !$item->{withdrawn}
+ ) {
+ $can_place_holds = 1;
+ }
+
$other_count++;
my $key = $prefix . $item->{status};
$lang = $languages[0] || 'en';
}
my $theme = 'prog'; # in the event of theme failure default to 'prog' -fbcit
- my $dbh = C4::Context->dbh;
my @themes;
if ( $interface eq "intranet" ) {
@themes = split " ", C4::Context->preference("template");
}
my $query =
" SELECT vc.biblionumber, vc.shelfnumber, vc.dateadded, itemtypes.*,
- biblio.*, biblioitems.itemtype, biblioitems.publicationyear, biblioitems.publishercode, biblioitems.place, biblioitems.size, biblioitems.pages
+ biblio.*, biblioitems.itemtype, biblioitems.publicationyear as year, biblioitems.publishercode, biblioitems.place, biblioitems.size, biblioitems.pages
FROM virtualshelfcontents vc
LEFT JOIN biblio ON vc.biblionumber = biblio.biblionumber
LEFT JOIN biblioitems ON biblio.biblionumber = biblioitems.biblionumber
UPGRADE
=======
+If you are running in another language other than english, please
+switch to english before doing the upgrade, the templating system has
+changed and the templates will need to be regenerated.
+Once you have upgraded, please regenerate your templates in your
+chosen languages.
+
If you are upgrading from a previous installation of Koha 3.x, you can
use the following:
=============================
-Installation Guide for Installing Koha on Debian Lenny with MySQL 5
+Installation Guide for Installing Koha on Debian
=============================
Some parts copyright 2010 Chris Nighswonger
+Some parts copyright 2011 MJ Ray and software.coop
Feedback/bug reports: Koha Developer's List:
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel
-This document last modified: October 8, 2010
+This document last modified: 2011-06-19
Installation Instructions
=============================
1. Prepare System and Install Dependencies
-1.1 Install Debian Lenny via Businesscard CD
+1.1 Install Debian via Business Card CD
- See http://www.debian.org/releases/lenny/debian-installer/
+ See http://www.debian.org/CD/netinst/
1.2 Set up Indexdata apt sources for Yaz and Zebra packages
-Edit your /etc/apt/sources.list file and add the following:
+See the instructions from indexdata at
+http://ftp.indexdata.com/pub/debian/README
+
+At the time of writing, you need to create
+/etc/apt/sources.list.d/indexdata.list containing the following:
# Index Data
- deb http://ftp.indexdata.dk/debian lenny main
- deb-src http://ftp.indexdata.dk/debian lenny main
+ deb http://ftp.indexdata.dk/debian squeeze main
+ deb-src http://ftp.indexdata.dk/debian squeeze main
-The Index Data packages are signed with a key you can install as follows:
+and add their archive signing key to your system:
$ wget -O- http://ftp.indexdata.dk/debian/indexdata.asc | sudo apt-key add -
1.3.2 Option B: Download Koha from http://download.koha-community.org
Find the latest Koha stable version on http://download.koha-community.org
-and get it:
+and download it to your server with something like:
- $ wget <URL> found on download.koha-community.org
+ $ wget <URL found on download.koha-community.org>
1.4 Install additional Debian dependencies
IMPORTANT: You should only use CPAN for Perl dependencies which are NOT
available from the package maintainer. You have been warned!
-Run shell script installing all necessary Debian packages, MySQL Server,
+Installing all necessary Debian packages, MySQL Server,
Zebra and all Debian packaged Perl module required by Koha:
- $ sudo install_misc/apt-get-debian-lenny.sh
+ $ sudo dpkg --set-selections < install_misc/debian.packages
+ $ sudo apt-get dselect-upgrade
-1.5 Install Perl dependencies that aren't packaged into Debian Lenny
-sources
+1.5 Install Perl dependencies that aren't packaged into Debian
Run the following command:
- $ sudo cpan Algorithm::CheckDigits SMS::Send HTTP::OAI IPC::Cmd \
- Memoize::Memcached PDF::API2::Simple PDF::Table Storable Test::More \
- Locale::Currency::Format DateTime Lingua::Stem::Snowball Text::CSV::Encoded \
- UNIVERSAL::require YAML Authen::CAS::Client
+ $ perl koha_perl_deps.pl -m -u
-Note: you may need to run CPAN initialization if you've not run cpan
-before:
+This will list whether any Perl dependencies are missing or need a
+later version and whether they are required. You can then install
+them another way. There may be packages on
+http://debian.koha-community.org or maybe you can build packages
+yourself or maybe you will need to install them locally with a command
+similar to
- /etc/perl/CPAN/Config.pm initialized.
+ $ sudo cpan Graphics::Magick
- CPAN is the world-wide archive of perl resources. It consists of about
- 100 sites that all replicate the same contents all around the globe.
- Many countries have at least one CPAN site already. The resources
- found on CPAN are easily accessible with the CPAN.pm module. If you
- want to use CPAN.pm, you have to configure it properly.
-
- If you do not want to enter a dialog now, you can answer 'no' to this
- question and I'll try to autoconfigure. (Note: you can revisit this
- dialog anytime later by typing 'o conf init' at the cpan prompt.)
-
- Are you ready for manual configuration? [yes]
+Note: you may need to run CPAN initialization if you've not run cpan
+before. See http://search.cpan.org/~andk/CPAN/lib/CPAN.pm#CONFIGURATION
When the configuration is completed CPAN will install the Perl modules.
configuration isn't correct. If Koha is the only web application running on the server,
the command "sudo a2dissite default" may be a quick fix. For servers running other sites
alongside Koha, see the Apache HTTPD manual section on virtual hosts for full
- instructions (http://httpd.apache.org/docs/2.0/vhosts/).
+ instructions (http://httpd.apache.org/docs/2.2/vhosts/).
5. Run the Web Installer, populate the database, initial configuration of settings
UPGRADE
=======
+If you are running in another language other than english, please
+switch to english before doing the upgrade, the templating system has
+changed and the templates will need to be regenerated.
+Once you have upgraded, please regenerate your templates in your
+chosen languages.
+
If you are upgrading from a previous installation of Koha 3.x, you can
use the following:
Tested on the following operating environments
==============================================
- Debian Lenny 5.0
+- Debian Squeeze 6.0
Other Notes
=====================
-====== Installation Guide for Installing Koha 3 on openSUSE 11 ======
+= Installation Guide for Installing Koha 3.0.0 on openSUSE 11.3 =
-Original version created by Ricardo Dias Marques - koha@ricmarques.net
+Original version for openSUSE 11.0 created by Ricardo Dias Marques - koha@ricmarques.net
+Version for openSUSE 11.3 adapted by Freek de Kruijf - freek -at- opensuse -dot- org
No liability for the contents of this document can be accepted.
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel
-This document last modified: 02 December 2008
+This document last modified: 15 Oct 2010
-
-===== Installation Instructions =====
+== Installation Instructions ==
This document was prepared in order to help you discover (or test) Koha (Integrated Library System).
The installation of Linux system described below is a basic, it is not designed for a production server (e.g., security, load balancing ... are not described).
-This document describes the different stages of installing the software Koha 3 on the openSUSE 11 Linux distribution
-in a "new" computer, that is, a computer that will have its hard disk contents COMPLETELY ERASED to install openSUSE and Koha!
+This document describes the different stages of installing the software Koha 3 on the openSUSE 11.3 Linux distribution in a "new" computer, the author uses a VirtualBox virtual machine, that is, a virtual computer that will have its virtual hard disk contents COMPLETELY ERASED to install openSUSE and Koha!
-In this example, it's assumed that your server gets an IP address by DHCP that will be later changed to 192.168.0.2.
+In this example, the virtual machine uses a bridged network connection, which mimics a separate computer in the local network, it's assumed that your server gets an IP address by DHCP that later will be changed to 192.168.1.16.
You'll have to change this to the real IP address that your machine should get (or use DHCP, if that's the case).
-This tutorial assumes a Koha installation that does NOT use Zebra ("Zebra is a high-performance, general-purpose structured text indexing and retrieval engine" - http://www.indexdata.dk/zebra/). Additional steps would be required to set up Zebra for Koha.
-
-==== LINUX System Installation ====
+This tutorial assumes a Koha installation that does NOT use Zebra ("Zebra is a high-performance, general-purpose structured text indexing and retrieval engine" - http://www.indexdata.dk/zebra/). Additional steps would be required to set up Zebra for Koha, however it will be installed.
+=== LINUX System Installation ===
-Download openSUSE 11 DVD at:
-http://software.opensuse.org/
-
-Place the DVD in the drive and restart the machine.
+Download openSUSE 11.3 DVD from [http://software.opensuse.org/ here].
+Place the DVD in the drive and restart the machine. In the case of a virtualmachine the iso image is still on the disc and you connect it as a DVD to the virtual machine.
After the "Welcome" screen, you'll get a First menu, with the following options:
Memory Test
----
+You may want to change the screen size to 1024 x 768 by pressing F3.
Choose "Installation" (second command)
-
-=== "Initializing" screen ===
+==== "Initializing" screen ====
(Dialog box appears saying "Probing Mouse")
-
-=== "Welcome" screen ===
+==== "Welcome" screen ====
You'll see two Dropdown Lists: "Language" and "Keyboard Layout"
This depends of your place and preference, naturally.
-I live in Portugal, so I want a Portuguese Keyboard Layout but I prefer an Operating System in English.
-So I leave the default option selected for "Language" (English (US))
-and change "Keyboard Layout" to "Portuguese".
+I live in The Netherlands, and we use the English (US) Keyboard Layout but I prefer an Operating System in English.
+So I leave the default option selected for "Language" and "Keyboard Layout" to (English (US)).
Check the "I Agree to the License Terms" checkbox (under the "License Agreement" textbox).
Click the "Next" button.
-
-
-=== "System Probing" screen ===
-
+==== "System Probing" screen ====
[just watch it...]
-
-
-=== "Installation Mode" screen ===
-
+==== "Installation Mode" screen ====
Leave "New Installation" radio button checked
-Click the "Next" button
+I prefer not to have the "Automatic Configuration" so this option is unchecked.
+It gives you the possibility to specify the name of the system and the network setup.
+Click the "Next" button
-=== "Initializing" screen ===
-
+==== "Initializing" screen ====
[just watch it...]
+==== "Clock and Time Zone" screen ====
+I do this work in Yemen, so I select the following options:
+"Region" listbox: click on "Asia"
-=== "Clock and Time Zone" screen ===
-
-
-Again, I live in Portugal, so I select the following options:
-
-"Region" listbox: click on "Europe"
-
-"Time Zone" listbox: click on "Portugal"
+"Time Zone" listbox: click on "Aden"
I leave the "Hardware Clock Set To UTC" checkbox checked.
Click the "Next" button
+==== "Desktop Selection" screen ====
-=== "Desktop Selection" screen ===
-
-
-You should see four radio buttons: "GNOME", "KDE 4.0", "KDE 3.5" and "Other".
+You should see three radio buttons: "GNOME Desktop", "KDE Desktop" and "Other".
Click on the "Other" radio button.
-Three radio buttons should become visible then:
+Four radio buttons should become visible then:
"XFCE Desktop"
+"LXDE Desktop"
+
"Minimal X Window"
"Minimal Server Selection (Text Mode)"
Click the "Next" button
+==== "Suggested Partitioning" screen ====
-
-=== "Suggested Partitioning" screen ===
-
-
-Partitioning choices are really up to you. In this example, I will create a 9 GB / ("root") partition and a 712 Swap Megs partition.
+Partitioning choices are really up to you. In this example, I started with a 8 GB virtual disc and I will create a 1000 MB swap partition and the rest is the root "/" partition.
So, to do this I click on the "Create Partition Setup..." button.
-=== "Preparing Hard Disk: Step 1" screen ===
-
+===== "Preparing Hard Disk: Step 1" screen =====
I click on the first radio button:
-"1: 1.IDE 10.0 GB,/dev/sda"
+"1: 1.IDE 8.0 GB,/dev/sda"
I click the "Next" button
-
-=== "Preparing Hard Disk: Step 2" screen ===
-
+===== "Preparing Hard Disk: Step 2" screen =====
I uncheck the "Propose separate Home Partition" checkbox.
This takes me back to the Suggested Partitioning screen.
-
-=== "Suggested Partitioning" screen ===
-
+===== "Suggested Partitioning" screen =====
In my case, I now have this:
-- Create swap partition /dev/sda1 (760.8 MB)
+- Create swap volume /dev/sda1 (1004.06 MB)
-- Create root partition /dev/sda2 (9.2 GB with ext3)
+- Create root volume /dev/sda2 (7.02 GB) with ext4
I click the "Next" button.
-
-=== "Create New User" screen ===
-
+==== "Create New User" screen ====
I use this screen to create a regular user.
I uncheck the "Use this password for System Administrator" checkbox.
+I check the "Receive System Mail"
+
I uncheck the "Automatic Login" checkbox.
I click the "Next" button (you may be "nagged" with a dialog box by the YAST2 installer warning that you selected a password that it considers to be too simple. Click "Yes" to keep the password you chose, or "No" to change it).
-
-
-
-
-=== Password for the System Administrator "root" screen ===
-
+==== Password for the System Administrator "root" screen ====
Enter your password (in the "Password for root User" text box) and repeat it (in the "Confirm Password" text box).
-Click the "Accept" button to return to the "Installation Settings" screen.
-
-
-=== "Installation Settings" screen ===
+Click the "Next" button to proceed to the "Installation Settings" screen.
+==== "Installation Settings" screen ====
Click on the "Software" link
-
-=== "Software Selection and System Tasks" screen ===
-
+==== "Software Selection and System Tasks" screen ====
Scroll down the listbox (that begins with the "Base Technologies" group) until you find the "Server Functions" group.
Click on the "OK" button to return to "Installation Settings"
-
-
-=== "Installation Settings" screen ===
-
+==== "Installation Settings" screen ====
Click on the "Install" button (placed in the same place where usually appear the "Accept" or "Next" button).
You should see a "Confirm Installation" dialog box. Click on the "Install" button of that dialog box.
-
-=== "Preparing Your Hard Disk" screen ===
-
+==== "Preparing Your Hard Disk" screen ====
[just watch it...]
-
-=== "Deploying Installation Images" screen ===
-
+==== "Deploying Installation Images" screen ====
[just watch it... ]
-
-
-=== "Package Installation" screen ===
-
-
+==== "Package Installation" screen ====
[just watch it... or click on the "Details" tab if you want to see what packages are being installed.]
-
-=== "Finishing Basic Installation" screen ===
-
+==== "Finishing Basic Installation" screen ====
[just watch it... ]
After some time you'll see a dialog box warning that the system will reboot in 10 seconds.
+==== After reboot ====
+Leave "Boot from Hard Disk" selected and press ENTER
-=== After reboot ===
+You'll have to wait a while (or press ESC to see what the operating system is "doing"). After some moments, you'll be taken to the "Yast2 - installation @ Linux" screen (a text installer).
+On the screen you will see Hostname and Domain Name with a textbox below.
+The cursor is in the textbox below Hostname.
+Press the Backspace to delete the name there and insert the name of your system, e.g. koha-server.
+Pres Tab and Backspace to delete "site" and enter the domain name, e.g. "univ.org".
+Press Tab go to Change Hostname via DHCP en press Space to remove the "x".
+Leave the "x" in Assign Hostname to Loopback IP.
+Press <Alt>+N to activate "Next". Now you enter:
-Leave "Boot from Hard Disk" selected and click ENTER
+==== Network Configuration ====
-You'll have to wait a while (or press ESC to see what the operating system is "doing"). After some moments, you'll
-be taken to the "Yast2 - installation @ Linux" screen (a text installer).
+Press ALT+C to Change Network Settings. Use the Arrow Keys to Highlight "Firewall" and press RETURN.
+Proceed to Firewall and press RETURN. Go to "Allowed Services" and press RETURN. Press TAB several times to highlight "HTTP Server".
+Press ALT+A to add HTTP Server to the list. Press ALT+S to choose the next Service to Allow.
+Press the Down Arrow and a drop down box will appear and press the Down Arrow several times to select Secure Shell Server and press RETURN.
+Press ALT+A to Add.
+We also need port 8080 for the management of Koha to be open, so press ALT+D to activate (Advanced...).
+Press ALT+T to go to TCP Ports and enter 8080 in the textbox.
+Pressing Alt+O for OK, brings you back to the Firewall Configuration.
+Pressing Alt+O for OK, brings you back to Network Configuration, but now you see the SSH port is open, the 8080 port is not shown.
+Press Alt+N for Next, which brings you to: Saving Network Configuration and finally to:
+==== Test Internet Connection ====
-=== "Writing the System Configuration" screen ===
+Press RETURN to activate Next and do the test.
+If all is well you should see "Test Result: Success".
+Press RETURN to activate Next.
+Now the meta data of some repositories will be downloaded and the next screen will appear:
+==== Online Update ====
-[just watch it... ]
+Here you can choose to do an online update or not.
+Press RETURN to activate Next and the update will be done.
+In my case the update even replaced the kernel. Press ALT+A to Accept the update.
+After that you press RETURN to activate Next.
+A warning may appear saying that the system will reboot.
-After a while you'll see a prompt:
-|--------------------
-Welcome to openSUSE 11.0 (i586) - Kernel 2.6.25.4-8-default (tty1)
+You will see the first screen of booting of the DVD again, but again you choose Boot from Hard Disk, which will also happen when you do not do anything.
-linux-3r10 login:
-|--------------------
+After that you will see the normal system boot screen and you do not need to do anything, but you may press RETURN to speed up the start of booting from the disc.
+In my case, after booting, the installtion went on and showed a screen of the YaST2 Package Manager showing the Release Notes.
+Press RETURN to continue.
+Now a screen asking about Hardware Configuration appeared. Press RETURN to continue.
-You may now login with your "root" user.
+Next a screen appears showing Installation Completed.
+Press RETURN to continue and you will see the startup log messages and at the end the following:
+|--------------------
+Welcome to openSUSE 11.3 "Teal" - Kernel 2.6.34.7-0.3-desktop (tty1)
+koha-server login:
+|--------------------
+You may now login with your "root" user.
==== Changing the Hostname and Domain Name ====
-I want to change my hostname, domain name and switch from DHCP to a Static IP address.
+Maybe you want to change the hostname, domain name and switch from DHCP to a Static IP address.
+Changing the hostname and domain name will not be shown here, because we assume that was done according to your whishes during installation.
-So, the first thing I do, is to run yast (the setup tool) by entering the yast command in the command prompt:
+This is how you can do it. You give the command yast (the setup tool) on the command prompt:
|--------------------
-linux-3r10:~ # yast
+koha-server:~ # yast
|--------------------
Yast should appear.
-On the listbox of the left hand side select "Network Devices" (press TAB to turn focus on that listbox, and press the down arrow key several times to reach it). Then, on the listbox of the right hand side, select "Network Settings" (you'll have again to press TAB to turn focus on that listbox, and press the down arrow key several times to reach it).
+On the listbox of the left hand side select "Network Devices" (press TAB to turn focus on that listbox, and press the down arrow key several times to reach it).
+Then, on the listbox of the right hand side, select "Network Settings" (you'll have again to press TAB to turn focus on that listbox, and press the down arrow key several times to reach it).
Press the ENTER key.
-
-=== "Initializing Network Configuration" screen ===
-
+==== "Initializing Network Configuration" screen ====
[just watch it...]
-=== "Network Settings" screen ===
-
+==== "Network Settings" screen ====
-I want to disable IPv6, so I first go to the "Global Options" section (by pushing the key combination ALT+G to press the "G" letter in Global Options that is highlighted). In the next screen, I push ALT+E to uncheck the "Enable IPv6" checkbox. I'll get a dialog box with a Warning saying that "To apply this change a reboot is needed.". I just press ENTER on that dialog box, but I do NOT reboot (at least not yet).
+I want to disable IPv6, so I first go to the "Global Options" section (by pushing the key combination ALT+G to press the "G" letter in Global Options that is highlighted).
+In the next screen, I push ALT+E to uncheck the "Enable IPv6" checkbox.
+I'll get a dialog box with a Warning saying that "To apply this change a reboot is needed.".
+I just press ENTER on that dialog box, but I do NOT reboot (at least not yet).
-Then I press Alt+O to go to the "Overview" (still in "Network Settings"). Then I press ALT+i to "Edit" the information for this Network Card.
-
-=== "Network Card Setup" screen ===
+Then I press Alt+V to go to the "Overview" (still in "Network Settings").
+Then I press ALT+I to "Edit" the information for this Network Card.
+==== "Network Card Setup" screen ====
I check the "Statically assigned IP Address" checkbox, and enter the following info for "IP Address", "Subnet Mask" and "Hostname" (you should use the values defined by your network administrator):
-IP Address: 192.168.0.2
+IP Address: 192.168.1.16
Subnet Mask: 255.255.255.0
-Hostname: myhost
+Hostname: koha-server.univ.org
Then I press ALT+N to click the "Next" button. After a few seconds, I will be taken again to the "Network Settings" screen.
+==== "Network Settings" screen ====
-=== "Network Settings" screen ===
-
-
-I press ALT+s to go to the "Hostname/DNS" screen.
-
-I check the "Change /etc/resolv.conf manually" checkbox and enter the IP Address of my DNS Server in the "Name Server 1" text box:
+I press ALT+S to go to the "Hostname/DNS" screen.
+Press ALT+I and the Arrow Key to choose "Only Custom Policy" by pressing Enter, press Tab to choose "Custom Policy Rule" and select "STATIC".
+Enter the IP Address of the Domain Name Server in the "Name Server 1" text box:
-Name Server 1: 192.168.0.1
+Name Server 1: 192.168.1.254
-Then I press ALT+u to go to the "Routing" configuration.
-
-=== "Routing" screen ===
+Then I press ALT+U to go to the "Routing" configuration.
+==== "Routing" screen ====
In the "Default Gateway" text box, I enter the IP Address of my Default Gateway:
-Default Gateway: 192.168.0.1
-
-Then I press ALT+F to Finish
-
-
+Default Gateway: 192.168.1.254
-=== "Saving Network Configuration" screen ===
+Then I press ALT+O for OK to Finish
+==== "Saving Network Configuration" screen ====
[just watch it...]
-
After a few seconds, you should be taken back to the "YaST2 Control Center" screen.
+Press ALT+Q to Quit YaST2.
+==== Making the ssh-daemon to start at system start ====
+We need a ssh-daemon that does not accept Environment parameters from the remote user.
+So we have to disable accepting these.
+For this you use vim to change the config file of sshd.
+|--------------------
+# cp /etc/ssh/sshd_config /etc/ssh/sshd_config.ORIG
+# vi /etc/ssh/sshd_config
+|--------------------
-==== Enabling access to SSH (Secure Shell) and Apache2 (Web Server) ====
-
-I want to administer remotely this server with a SSH (Secure Shell) client. So, while still in the "YaST2 Control Center, I will enable SSH in the Firewall (running by default). In the listbox of the left hand side, I select "Security and Users" and then, on the listbox of the right side, I select "Firewall" (first option) and press the ENTER key.
-
-=== "yast2 - firewall" screen ===
-
-In the list box of the left side, I select "Allowed Services" and press ENTER.
-
-Then, on the "Service to Allow" dropdown list (on the right side), I leave the "Apache 2" option selected and press "ALt+A" to add it. After adding Apache, I'll press "Alt+S" to see the available services to add. Then, I use the down key in that list until I see "Secure Shell Server" and press ENTER to select it. This will close that list and put "Secure Shell Server" as the selected option. I'll press Alt+A again to add it.
-
-Then I click on ALT+N click on the "Next" button.
-
-
-=== "Firewall Configuration: Summary" screen ===
-
+Find the lines starting with AcceptEnv and insert a # in front of these, There are three lines.
+Afterwards these lines will look like:
+|--------------------
+#AcceptEnv LANG LC_CTYPE LC_NUMERIC LC_TIME LC_COLLATE LC_MONETARY LC_MESSAGES
+#AcceptEnv LC_PAPER LC_NAME LC_ADDRESS LC_TELEPHONE LC_MEASUREMENT
+#AcceptEnv LC_IDENTIFICATION LC_ALL
+|--------------------
-Click on the "Finish" button.
+In order to make the ssh-daemon start at system boot, you have to enable this by giving:
+|--------------------
+# chkconfig sshd on
+|--------------------
-When you get sent back to the "YaST2 Control Center" screen, press ALT+Q to Quit Yast.
+You can check the status with the command "chkconfig -l sshd".
+The output should look like this:
+|--------------------
+# sshd 0:off 1:off 2:off 3:on 4:off 5:on 6:off
+|--------------------
+Also you need to start the sshd service in order to generate the security keypair for sshd.
+|--------------------
+# service sshd start
+|--------------------
This time seems to be a good time to reboot your server:
|--------------------
-linux-3r10:~ # reboot
+# reboot
|--------------------
After rebooting the machine, if you wish, you may go to another machine and connect to your newly created server using a SSH (Secure Shell) client. In Windows, I like to use putty to do ssh sessions to my Linux servers.
-
-==== Configure Software Repositories ===
+=== Configure Software Repositories ===
After the system has rebooted, log in as root.
-Later on, you will need to add some software packages from the openSUSE 11 Distribution. Some of those packages are NOT available in the openSUSE 11.0 DVD (libyaz-devel is one of those packages). So, we'll now set up openSUSE to add the "Official openSUSE 11.0 OSS (Open Source Software) Repository" using yast.
+Later on, you will need to add some software packages from the openSUSE 11 Distribution.
+Some of those packages are NOT available in the openSUSE 11.3 DVD (libyaz-devel is one of those packages).
+However we already added these repositories to the system after configuring the network.
+In case you did not have a network setup at that time, it is now time to setup these repositories, but you can skip this if this has been done already.
First, run the yast command in the Linux command line (shell):
Inside yast, select Software -> Software Repositories
+==== "Configured Software Repositories" screen ====
-=== "Configured Software Repositories" screen ===
-
-If on this screen, you already see a table that has:
-
- * as configured repositories (in the "Name" column) - "openSUSE-DVD 11.0", "openSUSE-11.0-Non.Oss", "openSUSE-11.0-Debug" and "openSUSE-11.0-Oss" ...
- * ... and, at least "openSUSE-DVD 11.0" and "openSUSE-11.0-Oss" have an "x" in the "Enabled" column ...
- * ... then you may leave yast, as the required repositories have already been configured.
-
-If not, you'll have to add the "openSUSE-11.0-Oss" repository. Click on the "Add" button.
-
-=== "Media type" screen ===
-
-
-Click on the Specify URL... radio button.
+When on this screen, you already see a table that has:
-Click on the "Next" button.
+* as configured repositories (in the "Name" column)
+** "Updates for openSUSE 11.3 11.3-1.82"
+** "openSUSE-11.3 11.3-1.82"
+** "openSUSE-11.3-Debug"
+** "openSUSE-11.3-Non-Oss" "openSUSE-11.3-Oss" ...
+* at least the following repositories have an "x" in the "Enabled" column
+** "Updates for openSUSE 11.3 11.3-1.82"
+** "openSUSE-11.3-Oss"
+* you still have to add the folowing repositiory to this list
+** "openSUSE BuildService - devel:languages:perl"
+Press ALT+A to Add Repositories.
+==== "Media type" screen ====
-=== "Repository URL" screen ===
+Select Community Repositories by pressing ALT+I and apply Next (press ALT+X).
+You will see a message that data will be downloaded.
+After that you will get a list of Repositories and the above mentioned, but not yet available, will be in this list.
+Select the one you need by using the Arrow Keys and press Space to select (an x will appear in front of the Repository).
+After that apply OK. You may see some activity and you may get asked to import GnuPG keys, just do so.
-In the "Repository Name" textbox enter some descriptive text like:
-openSUSE 11.0 Official OSS Repository
-
-In the "URL" textbox enter:
-http://download.opensuse.org/distribution/11.0/repo/oss/
-
-
-Click on the "Next" button.
-
-
-=== "License Agreement" screen ===
+You may see the following screen.
+==== "License Agreement" screen ====
Check the "Yes, I Agree to the License Agreement" radio button.
Click on the "Next" button to return to the "Configured Software Repositories" screen.
+==== "Configured Software Repositories" screen ====
-=== "Configured Software Repositories" screen ===
-
-
-You should see now the "openSUSE 11 Official OSS Repository" listed as an entry.
+You should see now the "openSUSE 11.3-Oss" listed as an entry.
+You can Disable "openSUSE-11.3-Source" and its Autorefresh, if present.
-Click on the "Finish" button.
+Click on the "OK" button.
When you get sent back to the "Yast Control Center" click on the "Quit" button (to return to the shell).
+=== Install some useful / necessary programs ===
-==== Install some useful / necessary programs ===
-
-By this time, I'll install some of the programs I regularly use, by using yast:
-
-
- * To install locate:
-|--------------------
-# yast -i findutils-locate
-|--------------------
-A YaST screen may appear saying:
-|--------------------
-Starting the Package Manager.
-|--------------------
-If that screen appears, it will download some information from http://download.opensuse.org (and set several Software Repositories "behind the scenes)
-
-
- * To install ncftp (command-line ftp client):
-|--------------------
-# yast -i ncftp
-|--------------------
-
-
-Install some packages that are needed to install Koha:
-
- * To install make :
-|--------------------
-# yast -i make
-|--------------------
+By this time, you have to install some of the programs which are regularly used, by using zypper (the command line mode packet manager):
- * To install gcc :
+To install locate, ncftp (command-line ftp client), make and gcc you give the following command:
|--------------------
-# yast -i gcc
+# zypper install findutils-locate ncftp make gcc
|--------------------
-(this will also install some packages that gcc depend on, like glibc-devel).
-
+Zypper reports that it will install 18 packages; confirm with RETURN.
-==== Download Koha ====
+== Download Koha ==
|--------------------
# wget http://download.koha-community.org/koha-3.00.00.tar.gz
|--------------------
+You will receive 49,266,888 bytes.
-[FIXME: Check what will be the exact URL of the .tar.gz file for Koha 3]
-
-
-==== Extract Koha ====
+== Extract Koha ==
|--------------------
# tar -xzvf koha-3.00.00.tar.gz
|--------------------
-
-==== Set up Locale for root user ====
+== Set up Locale for root user ==
If you run the locale command, you'll probably get this output:
|--------------------
Leave "English (US)" selected as the option for Primary Language
-
Click on the "Details..." link
Change the Locale Settings for user root from the default option ("ctype Only") to "Yes"
Click on the OK button to return to the "Languages" screen
-Click on the "Accept" button.
-
-
+Click on the "OK" button.
When you get back to the "Yast2 Control Center" screen, click on the "Quit" button
+== Putty configuration to use Unicode (UTF-8 encoding) ==
-
-==== Putty configuration to use Unicode (UTF-8 encoding) ====
-
-If you use Putty, set up Putty to use UTF-8 encoding. To do this, click on the upper left corner of the PuTTy window,
-to expand the menu. Scroll down until you find the "Change Settings..." command and click on it.
+If you use Putty, set up Putty to use UTF-8 encoding.
+To do this, click on the upper left corner of the PuTTy window, to expand the menu.
+Scrol down until you find the "Change Settings..." command and click on it.
This should open the "PuTTy Reconfiguration" screen. Here expand the "Window" category and click on "Translation"
Click on the "Apply" button
+Now, it's a good time to SAVE this PuTTy session.
+To do this, click again on the upper left corner of the PuTTy window, to expand the menu, and click on the "Change Settings..." command like you did before.
-Now, it's a good time to SAVE this PuTTy session. To do this, click again on the upper left corner of the PuTTy window, to expand the menu, and click on the "Change Settings..." command like you did before.
-
-This should open the "PuTTy Reconfiguration" screen. Go to the right hand side of that screen and type a name in the "Saved Sessions" textbox (e.g: koha). Then click on the "Save" button and, after doing that, click on the "Apply" button.
-
+This should open the "PuTTy Reconfiguration" screen. Go to the right hand side of that screen and type a name in the "Saved Sessions" textbox (e.g: koha).
+Then click on the "Save" button and, after doing that, click on the "Apply" button.
IMPORTANT!!! Now it's the time to EXIT the login shell, by typing the exit command:
|--------------------
Now you'll reopen PuTTy, but when you do that, open the Saved Session that you have created in order to use the "UTF-8" configuration you have done.
+You may not need to do the above after the change, made earlier, in /etc/ssh/sshd_config. Check it and if so you can modify this wiki page.
After logging in again with the root user, type the locale command again. Now it should read like the following:
LC_ALL=
|--------------------
-
-==== Apache configuration (for UTF-8) ====
+== Apache configuration (for UTF-8) ==
Create a file called /etc/apache2/httpd.conf.local with vim (or your preferred text editor):
|--------------------
AddDefaultCharset UTF-8
|--------------------
-
-==== Configure Apache to start at boot time and start the service ====
+== Configure Apache to start at boot time and start the service ==
|--------------------
# chkconfig apache2 on
Go to a browser and type:
-http://192.168.0.2
+http://192.168.1.16
You should see a page that reads:
"It works!"
-
-
-==== MySQL configuration ====
+== MySQL configuration ==
1 - Configure MySQL to start at boot time and start the service:
|--------------------
# service mysql start
|--------------------
+The system will issue a warning that '--skip-locking' is deprecated, but for now we accept that.
2 - Change the password for the "root" user of MySQL:
|--------------------
# /usr/bin/mysqladmin -u root password 'chosenpassword'
|--------------------
+After starting MySQL also it is recommended to give the command:
+<tt> # /usr/bin/mysqladmin -u root -h koha-server.univ.org password 'chosenpassword'</tt>
+However this gives an error message. This is left for the more advanced MySQL administrator.
3 - Check the encoding variables of MySQL
-To check the encoding variables of MySQL, will type the
-show variables like 'char%'; command in a mysql prompt:
+To check the encoding variables of MySQL, will type the show variables like 'char%'; command in a mysql prompt:
|--------------------
# mysql -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 7
-Server version: 5.0.51a SUSE MySQL RPM
+Server version: 5.1.46-log SUSE MySQL RPM
+Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
+This software comes with ABSOLUTELY NO WARRANTY. This is free software,
+and you are welcome to modify and redistribute it under the GPL v2 license
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
+--------------------------+----------------------------+
| Variable_name | Value |
+--------------------------+----------------------------+
-| character_set_client | latin1 |
-| character_set_connection | latin1 |
-| character_set_database | latin1 |
+| character_set_client | utf8 |
+| character_set_connection | utf8 |
+| character_set_database | utf8 |
| character_set_filesystem | binary |
-| character_set_results | latin1 |
-| character_set_server | latin1 |
+| character_set_results | utf8 |
+| character_set_server | utf8 |
| character_set_system | utf8 |
| character_sets_dir | /usr/share/mysql/charsets/ |
+--------------------------+----------------------------+
Bye
|--------------------
+The above looks OK, so we can skip 1 and 2 and continue with 2a, but if not you can follow the following procedure.
+
We want to have utf8 in the above character_set_* variables above (and NOT latin1)!
In order to do this:
character-set-server = utf8
skip-character-set-client-handshake
|--------------------
+In openSUSE 11.3 and the provided mysql packet only the default-character-set can be set, the other 2 should not be added.
+
+2a - If you are unfamilar with SQL you should remove the #-character in front of safe-updates in that same section.
3 - Restart MySQL:
|--------------------
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 1
-Server version: 5.0.51a SUSE MySQL RPM
-
+Server version: 5.1.46-log SUSE MySQL RPM
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
Bye
|--------------------
-==== Create the Koha database ====
+== Create the Koha database ==
=== Create the koha database and user with associated privileges ===
|--------------------
|--------------------
(you may name the koha database something different from koha)
-
=== Grant privileges to a MySQL user to the koha database ===
Assuming that you want to have a MySQL user called "kohaadmin" to administer a database called "koha" with the password "kohapassword", you'd enter this:
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 3
-Server version: 5.0.51a SUSE MySQL RPM
+Server version: 5.1.46-log SUSE MySQL RPM
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
Bye
|--------------------
-
-==== Test your SAX Parser and correct where necessary ====
-
+== Test your SAX Parser and correct where necessary ==
* Install the XML::SAX and XML::LibXML perl Modules:
+
|--------------------
-# yast -i perl-XML-SAX
+# zypper install perl-XML-SAX perl-XML-LibXML
+Loading repository data...
+Reading installed packages...
+'perl-XML-SAX' is already installed.
+There is an update candidate for 'perl-XML-SAX', but it is from different vendor. Use 'zypper install perl-XML-SAX-0.96-13.1.x86_64' to install this candidate.
+'perl-XML-LibXML' is already installed.
+There is an update candidate for 'perl-XML-LibXML', but it is from different vendor. Use 'zypper install perl-XML-LibXML-1.70-6.1.x86_64' to install this candidate.
+Resolving package dependencies...
-# yast -i perl-XML-LibXML
+Nothing to do.
|--------------------
-You must be sure you're using the XML::LibXML SAX parser, not Expat or PurePerl, both of which have outstanding bugs with pre-composed characters. You can test your SAX parser by running:
+In the above you see that these two packets have been installed during system installation.
+You also installed a repository for the language perl.
+The message about a different vendor is about this repository.
+You have to use "zypper dup" to install the newer versions from this repository, but this outside this tutorial.
+
+You must be sure you're using the XML::LibXML SAX parser, not Expat or PurePerl, both of which have outstanding bugs (in 2008) with pre-composed characters. You can test your SAX parser by running:
|--------------------
# cd /root/koha-3.00.00/
|--------------------
If you're using PurePerl (you probably are) or Expat, you'll need to edit your ParserDetails.ini file to use the LibXML Parser.
-To find the ParserDetails.ini file, you may use locate. To do this, first update the locate database by running the updatedb command:
+To find the ParserDetails.ini file, you may use locate.
+To do this, first update the locate database by running the updatedb command:
|--------------------
# updatedb
|--------------------
Then find ParserDetails.ini using locate:
|--------------------
# locate ParserDetails.ini
-/usr/lib/perl5/vendor_perl/5.10.0/XML/SAX/ParserDetails.ini
+/usr/lib/perl5/vendor_perl/5.12.1/XML/SAX/ParserDetails.ini
|--------------------
OK. So, let's first do a backup of this ini file:
|--------------------
- # cd /usr/lib/perl5/vendor_perl/5.10.0/XML/SAX/
+# cd /usr/lib/perl5/vendor_perl/5.12.1/XML/SAX/
myhost:/usr/lib/perl5/vendor_perl/5.10.0/XML/SAX # cp ParserDetails.ini ParserDetails.ini.ORIG
|--------------------
[XML::LibXML::SAX::Parser]
|--------------------
-Run the /root/koha-3.00.00/misc/sax_parser_print.pl command again. This time, you should get the following output:
+Run the /root/koha-3.00.00/misc/sax_parser_print.pl command again.
+This time, you should get the following output:
|--------------------
XML::LibXML::SAX::Parser=HASH(0x8356e0c)
|--------------------
+== Install the Zebra package ==
+Zebra is already in the standard repository of openSUSE 11.3, so it seems better to install it.
+In the next chapter a question will be asked wether it is installed, so you better install it; no harm done.
+Because you may need the documentation, that will also be installed.
+Note that the package name is idzebra.
+|--------------------
+# zypper install idzebra idzebra-doc
+|--------------------
+You will notice that a few dependencies need to be resolved, so a few other packages are also installed.
-
-
-==== Run Koha's perl installer ====
+== Run Koha's perl installer ==
|--------------------
myhost:/usr/lib/perl5/vendor_perl/5.10.0/XML/SAX # cd /root/koha-3.00.00
|--------------------
-We will now run perl Makefile.PL to run the installer.
-
-My installation is a UNIMARC installation, so I'm answering unimarc to the "MARC format for Zebra indexing (marc21, unimarc) [marc21]" question below. If your Library uses the MARC21 format instead of UNIMARC, you should press ENTER to accept the default (which is marc21).
-
-Because my bibliographic catalog will have mainly records in Portuguese, and Portuguese is more similar to French than to English, I'm answering "fr" (French) to the "Primary language for Zebra indexing (en, fr) [en]" question below.
+After installation of a number of CPAN/perl packages we will run perl Makefile.PL to run the Koha installer.
+
+
+=== Using zypper to install CPAN modules ===
+
+The author of the openSUSE 11.0 version of this page did a trial run with the Makefile.PL module, which showed a lot of unstalled perl modules and other software packages.
+He used the names of these packages and installed the missing ones.
+I collected all the missing packets and put them in the list below to install these packages before running Makefile.PL.
+Doing the way he did provides more inside in the process, however it is tedious and I want to avoid that.
+You still can go [[Koha_3.0.0_on_openSUSE_11.0#Run_Koha's_perl_installer|there]] and learn from that experience.
+
+The commands show below need to be given one by one, because zypper will always ask for confirmation. However you can als also put more than one module name after the "zypper install" command.
+|--------------------
+# zypper install perl-Algorithm-CheckDigits
+# zypper install perl-Biblio-EndnoteStyle
+# zypper install perl-CGI-Session-Serialize-yaml
+# zypper install perl-CGI-Session
+# zypper install perl-Class-Accessor
+# zypper install perl-Class-Factory-Util
+# zypper install perl-DBD-mysql
+# zypper install perl-Data-ICal
+# zypper install perl-Date-Calc
+# zypper install perl-Date-ICal
+# zypper install perl-Date-Manip
+# zypper install perl-DublinCore-Record
+# zypper install perl-Email-Date
+# zypper install perl-GD
+# zypper install perl-GD-Barcode
+# zypper install perl-HTML-Scrubber
+# zypper install perl-HTML-Template-Pro
+# zypper install perl-Lingua-Stem
+# zypper install perl-MARC-Charset
+# zypper install perl-MARC-Crosswalk-DublinCore
+# zypper install perl-MARC-File-XML
+# zypper install perl-MARC-Record
+# zypper install perl-MIME-Lite
+# zypper install perl-Mail-Sendmail
+# zypper install perl-Net-LDAP
+# zypper install perl-Net-Z3950-ZOOM
+# zypper install perl-PDF-API2
+# zypper install perl-PDF-Reuse
+# zypper install perl-PDF-Reuse-Barcode
+# zypper install perl-POE
+# zypper install perl-32bit
+# zypper install perl-SMS-Send
+# zypper install perl-Schedule-At
+# zypper install perl-Text-CSV
+# zypper install perl-Text-Iconv
+# zypper install perl-XML-Dumper
+# zypper install perl-XML-LibXSLT
+# zypper install perl-XML-RSS
+# zypper install perl-Text-CSV_XS
+# zypper install perl-PerlMagick
+# zypper install perl-Carp-Assert
+# zypper install gd gd-devel
+# zypper install xorg-x11-libXpm-devel
+# zypper install libjpeg-devel
+# zypper install fontconfig-devel
+# zypper install libpng-devel
+# zypper install libyaz-devel
+|--------------------
+
+== Running the Makefile.PL module to configure Koha ==
+
+My installation is a UNIMARC installation, so I'm answering unimarc to the "MARC format for Zebra indexing (marc21, unimarc) [marc21]" question below.
+If your Library uses the MARC21 format instead of UNIMARC, you should press ENTER to accept the default (which is marc21).
+
+Because my bibliographic catalog will have mainly records in English and Arabic, I'm answering "en" (English) to the "Primary language for Zebra indexing (en, fr) [en]" question below.
Although I'm NOT using Zebra, I'm answering "yes" (the default choice) to the "Install the Zebra configuration files? (no, yes) [yes]" so I can set up Zebra later, if I decide to.
-OK. So here's the result of running the perl Makefile.PL command (including my answers to the several questions):
+Also note that Zebra has been installed in this case.
+Below is the result of running the "perl Makefile.PL" command (including my answers to the several questions):
|--------------------
myhost:~/koha-3.00.00 # perl Makefile.PL
in your PATH or in some of the usual places. If you haven't
installed Zebra yet, please do so and run Makefile.PL again.
-
Since you've chosen to use Zebra with Koha,
you must specify the primary MARC format of the
records to be indexed by Zebra.
Would you like to run the database-dependent test suite? (no, yes) [no]
-
-
-
Koha will be installed with the following configuration parameters:
AUTH_INDEX_MODE dom
ZEBRA_LOCK_DIR /var/lock/koha/zebradb
ZEBRA_RUN_DIR /var/run/koha/zebradb
-
To change any configuration setting, please run
perl Makefile.PL again. To override one of the target
directories, you can do so on the command line like this:
Checking if your kit is complete...
Looks good
-Warning: prerequisite Algorithm::CheckDigits 0.5 not found.
-Warning: prerequisite Biblio::EndnoteStyle 0.05 not found.
-[Tue Oct 14 23:40:25 2008] Makefile.PL: Warning: prerequisite CGI::Session 4.10 not found.
-[Tue Oct 14 23:40:25 2008] Makefile.PL: Warning: prerequisite Class::Accessor 0.3 not found.
-[Tue Oct 14 23:40:25 2008] Makefile.PL: Warning: prerequisite Class::Factory::Util 1.6 not found.
-[Tue Oct 14 23:40:25 2008] Makefile.PL: Warning: prerequisite DBD::mysql 4.004 not found.
-[Tue Oct 14 23:40:25 2008] Makefile.PL: Warning: prerequisite Data::ICal 0.13 not found.
-[Tue Oct 14 23:40:25 2008] Makefile.PL: Warning: prerequisite Date::Calc 5.4 not found.
-[Tue Oct 14 23:40:25 2008] Makefile.PL: Warning: prerequisite Date::ICal 1.72 not found.
-[Tue Oct 14 23:40:25 2008] Makefile.PL: Warning: prerequisite Date::Manip 5.44 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite Email::Date 1.103 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite GD 2.39 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite GD::Barcode::UPCE 1.1 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite HTML::Scrubber 0.08 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite HTML::Template::Pro 0.69 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite Lingua::Stem 0.82 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite List::MoreUtils 0.21 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite MARC::Charset 0.98 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite MARC::Crosswalk::DublinCore 0.02 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite MARC::File::XML 0.88 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite MARC::Record 2 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite MIME::Lite 3 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite Mail::Sendmail 0.79 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite Net::LDAP 0.33 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite Net::LDAP::Filter 0.14 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite Net::Z3950::ZOOM 1.16 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite PDF::API2 2 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite PDF::API2::Page 2 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite PDF::API2::Util 2 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite PDF::Reuse 0.33 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite PDF::Reuse::Barcode 0.05 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite POE 0.9999 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite SMS::Send 0.05 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite Schedule::At 1.06 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite Text::CSV 0.01 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite Text::CSV_XS 0.32 not found.
-[Tue Oct 14 23:40:26 2008] Makefile.PL: Warning: prerequisite Text::Iconv 1.7 not found.
-[Tue Oct 14 23:40:27 2008] Makefile.PL: Warning: prerequisite XML::Dumper 0.81 not found.
-[Tue Oct 14 23:40:27 2008] Makefile.PL: Warning: prerequisite XML::LibXSLT 1.59 not found.
-[Tue Oct 14 23:40:27 2008] Makefile.PL: Warning: prerequisite XML::RSS 1.31 not found.
-[Tue Oct 14 23:40:27 2008] Makefile.PL: Warning: prerequisite YAML::Syck 0.71 not found.
Writing Makefile for koha
-
myhost:~/koha-3.00.00 #
|--------------------
-OK... Lots of missing dependencies (Perl Modules). Let's build some of these modules in CPAN to fix this:
-
-
-==== CPAN Configuration ====
-If you don't already know, "CPAN is the Comprehensive Perl Archive Network, a large collection of Perl software and documentation". For additional info, you may browse the official CPAN web site is at http://www.cpan.org/
-
-Enter the "cpan" command to configure CPAN:
-|--------------------
-myhost:~/koha-3.00.00 # cpan
-
-
-CPAN is the world-wide archive of perl resources. It consists of about
-300 sites that all replicate the same contents around the globe. Many
-countries have at least one CPAN site already. The resources found on
-CPAN are easily accessible with the CPAN.pm module. If you want to use
-CPAN.pm, lots of things have to be configured. Fortunately, most of
-them can be determined automatically. If you prefer the automatic
-configuration, answer 'yes' below.
-
-If you prefer to enter a dialog instead, you can answer 'no' to this
-question and I'll let you configure in small steps one thing after the
-other. (Note: you can revisit this dialog anytime later by typing 'o
-conf init' at the cpan prompt.)
-Would you like me to configure as much as possible automatically? [yes]
-|--------------------
-
-[Just press ENTER here to set all CPAN settings to the default values.
-After doing this CPAN will scroll lots of messages with questions that
-it will automatically answer]
-
-[Let's now set up CPAN for Internet access to enable it to download packages.
-Because I live in Portugal, I'm choosing Portuguese mirrors here. Choose the
-mirrors that are nearer to you:]
-
-|--------------------
-cpan[2]> o conf init urllist
-You have no /root/.cpan/sources/MIRRORED.BY
- I'm trying to fetch one
-CPAN: LWP::UserAgent loaded ok (v5.810)
-
-I would like to connect to one of the following sites to get 'MIRRORED.BY':
-
- http://www.perl.org/CPAN/
- ftp://ftp.perl.org/pub/CPAN/
-
-Is it OK to try to connect to the Internet? [yes]
-Fetching with LWP:
- http://www.perl.org/CPAN/MIRRORED.BY
-
-
-Now we need to know where your favorite CPAN sites are located. Push
-a few sites onto the array (just in case the first on the array won't
-work). If you are mirroring CPAN to your local workstation, specify a
-file: URL.
-
-First, pick a nearby continent and country by typing in the number(s)
-in front of the item(s) you want to select. You can pick several of
-each, separated by spaces. Then, you will be presented with a list of
-URLs of CPAN mirrors in the countries you selected, along with
-previously selected URLs. Select some of those URLs, or just keep the
-old list. Finally, you will be prompted for any extra URLs -- file:,
-ftp:, or http: -- that host a CPAN mirror.
-
-(1) Africa
-(2) Asia
-(3) Central America
-(4) Europe
-(5) North America
-(6) Oceania
-(7) South America
-Select your continent (or several nearby continents) [] 4
-
-(1) Austria
-(2) Belgium
-(3) Bosnia and Herzegovina
-(4) Bulgaria
-(5) Croatia
-(6) Czech Republic
-(7) Denmark
-(8) Finland
-(9) France
-(10) Germany
-(11) Greece
-(12) Hungary
-(13) Iceland
-(14) Ireland
-(15) Italy
-(16) Latvia
-15 more items, hit RETURN to show them
-Select your country (or several nearby countries) []
-Sorry! since you don't have any existing picks, you must make a
-geographic selection.
-
-(17) Lithuania
-(18) Malta
-(19) Netherlands
-(20) Norway
-(21) Poland
-(22) Portugal
-(23) Romania
-(24) Russia
-(25) Slovakia
-(26) Slovenia
-(27) Spain
-(28) Sweden
-(29) Switzerland
-(30) Ukraine
-(31) United Kingdom
-Select your country (or several nearby countries) [] 22
-
-(1) ftp://cpan.ip.pt/pub/cpan/
-(2) ftp://ftp.dei.uc.pt/pub/CPAN
-(3) ftp://ftp.isr.ist.utl.pt/pub/CPAN/
-(4) ftp://ftp.nfsi.pt/pub/cpan/
-(5) ftp://neacm.fe.up.pt/pub/CPAN/
-(6) ftp://perl.di.uminho.pt/pub/CPAN/
-(7) http://cpan.dcc.fc.up.pt/
-Select as many URLs as you like (by number),
-put them on one line, separated by blanks, hyphenated ranges allowed
- e.g. '1 4 5' or '7 1-4 8' [] 3 2 6 4 5 7 1
-
-Enter another URL or RETURN to quit: []
-New set of picks:
- ftp://ftp.isr.ist.utl.pt/pub/CPAN/
- ftp://ftp.dei.uc.pt/pub/CPAN
- ftp://perl.di.uminho.pt/pub/CPAN/
- ftp://ftp.nfsi.pt/pub/cpan/
- ftp://neacm.fe.up.pt/pub/CPAN/
- http://cpan.dcc.fc.up.pt/
- ftp://cpan.ip.pt/pub/cpan/
-
-
-Please remember to call 'o conf commit' to make the config permanent!
-
-
-cpan[3]> o conf commit
-commit: wrote '/usr/lib/perl5/5.10.0/CPAN/Config.pm'
-
-cpan[4]> quit
-Lockfile removed.
-|--------------------
-
-==== Installing Prerequisite Modules ====
-|--------------------
-myhost:~/koha-3.00.00 # cpan
-CPAN: File::HomeDir loaded ok (v0.69)
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-|--------------------
-
-=== Install Algorithm::CheckDigits ===
-[Let's install the first package called "Algorithm::CheckDigits". Here I will leave the complete output. For the next installations, I will only show the prompts for dependencies and snip out the remaining output]:
-|--------------------
-cpan[1]> install Algorithm::CheckDigits
-CPAN: Storable loaded ok (v2.18)
-CPAN: LWP::UserAgent loaded ok (v5.810)
-CPAN: Time::HiRes loaded ok (v1.9711)
-Fetching with LWP:
- ftp://ftp.isr.ist.utl.pt/pub/CPAN/authors/01mailrc.txt.gz
-Going to read /root/.cpan/sources/authors/01mailrc.txt.gz
-CPAN: Compress::Zlib loaded ok (v2.008)
-............................................................................DONE
-Fetching with LWP:
- ftp://ftp.isr.ist.utl.pt/pub/CPAN/modules/02packages.details.txt.gz
-Going to read /root/.cpan/sources/modules/02packages.details.txt.gz
- Database was generated on Mon, 07 Jul 2008 04:02:45 GMT
-............................................................................DONE
-Fetching with LWP:
- ftp://ftp.isr.ist.utl.pt/pub/CPAN/modules/03modlist.data.gz
-Going to read /root/.cpan/sources/modules/03modlist.data.gz
-............................................................................DONE
-Going to write /root/.cpan/Metadata
-Running install for module 'Algorithm::CheckDigits'
-CPAN: Data::Dumper loaded ok (v2.121_14)
-'YAML' not installed, falling back to Data::Dumper and Storable to read prefs '/root/.cpan/prefs'
-Running make for M/MA/MAMAWE/Algorithm-CheckDigits-0.50.tar.gz
-Fetching with LWP:
- ftp://ftp.isr.ist.utl.pt/pub/CPAN/authors/id/M/MA/MAMAWE/Algorithm-CheckDigits-0.50.tar.gz
-CPAN: Digest::SHA loaded ok (v5.45)
-Fetching with LWP:
- ftp://ftp.isr.ist.utl.pt/pub/CPAN/authors/id/M/MA/MAMAWE/CHECKSUMS
-Checksum for /root/.cpan/sources/authors/id/M/MA/MAMAWE/Algorithm-CheckDigits-0.50.tar.gz ok
-Scanning cache /root/.cpan/build for sizes
-DONE
-Algorithm-CheckDigits-0.50/
-Algorithm-CheckDigits-0.50/t/
-Algorithm-CheckDigits-0.50/t/valid.data
-Algorithm-CheckDigits-0.50/t/valid.t
-Algorithm-CheckDigits-0.50/t/iban.t
-Algorithm-CheckDigits-0.50/t/isbn13.t
-Algorithm-CheckDigits-0.50/t/ecno.t
-Algorithm-CheckDigits-0.50/t/upc.t
-Algorithm-CheckDigits-0.50/t/imei.t
-Algorithm-CheckDigits-0.50/t/pod-coverage.t
-Algorithm-CheckDigits-0.50/t/pod.t
-Algorithm-CheckDigits-0.50/t/checkdigits.t
-Algorithm-CheckDigits-0.50/CheckDigits.pm
-Algorithm-CheckDigits-0.50/Changes
-Algorithm-CheckDigits-0.50/CheckDigits/
-Algorithm-CheckDigits-0.50/CheckDigits/MXX_005.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M10_005.pm
-Algorithm-CheckDigits-0.50/CheckDigits/MBase_002.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M97_001.pm
-Algorithm-CheckDigits-0.50/CheckDigits/MBase_003.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M10_006.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_012.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M10_010.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_015.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M07_001.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M10_002.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_008.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M23_001.pm
-Algorithm-CheckDigits-0.50/CheckDigits/MXX_004.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_001.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_003.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_013.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_009.pm
-Algorithm-CheckDigits-0.50/CheckDigits/MXX_002.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M10_001.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M09_001.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_006.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M16_001.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M10_003.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M10_008.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_002.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_016.pm
-Algorithm-CheckDigits-0.50/CheckDigits/MXX_003.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_011.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M23_002.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M43_001.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_017.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_007.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M10_011.pm
-Algorithm-CheckDigits-0.50/CheckDigits/MXX_006.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M89_001.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M10_004.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M97_002.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_004.pm
-Algorithm-CheckDigits-0.50/CheckDigits/MBase_001.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M11_010.pm
-Algorithm-CheckDigits-0.50/CheckDigits/M10_009.pm
-Algorithm-CheckDigits-0.50/CheckDigits/MXX_001.pm
-Algorithm-CheckDigits-0.50/META.yml
-Algorithm-CheckDigits-0.50/.perltidyrc
-Algorithm-CheckDigits-0.50/README
-Algorithm-CheckDigits-0.50/MANIFEST
-Algorithm-CheckDigits-0.50/Makefile.PL
-CPAN: File::Temp loaded ok (v0.18)
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
-
- CPAN.pm: Going to build M/MA/MAMAWE/Algorithm-CheckDigits-0.50.tar.gz
-
-Checking if your kit is complete...
-Looks good
-Writing Makefile for Algorithm::CheckDigits
-Could not read '/root/.cpan/build/Algorithm-CheckDigits-0.50-mL1o1L/META.yml'. Falling back to other methods to determine prerequisites
-cp CheckDigits/M11_001.pm blib/lib/Algorithm/CheckDigits/M11_001.pm
-cp CheckDigits/M11_010.pm blib/lib/Algorithm/CheckDigits/M11_010.pm
-cp CheckDigits/M97_002.pm blib/lib/Algorithm/CheckDigits/M97_002.pm
-cp CheckDigits/M23_001.pm blib/lib/Algorithm/CheckDigits/M23_001.pm
-cp CheckDigits/M97_001.pm blib/lib/Algorithm/CheckDigits/M97_001.pm
-cp CheckDigits/M16_001.pm blib/lib/Algorithm/CheckDigits/M16_001.pm
-cp CheckDigits/M10_006.pm blib/lib/Algorithm/CheckDigits/M10_006.pm
-cp CheckDigits/M11_013.pm blib/lib/Algorithm/CheckDigits/M11_013.pm
-cp CheckDigits/M07_001.pm blib/lib/Algorithm/CheckDigits/M07_001.pm
-cp CheckDigits/MXX_006.pm blib/lib/Algorithm/CheckDigits/MXX_006.pm
-cp CheckDigits/M10_008.pm blib/lib/Algorithm/CheckDigits/M10_008.pm
-cp CheckDigits/M11_017.pm blib/lib/Algorithm/CheckDigits/M11_017.pm
-cp CheckDigits/M10_003.pm blib/lib/Algorithm/CheckDigits/M10_003.pm
-cp CheckDigits/M11_016.pm blib/lib/Algorithm/CheckDigits/M11_016.pm
-cp CheckDigits/M11_003.pm blib/lib/Algorithm/CheckDigits/M11_003.pm
-cp CheckDigits/MXX_002.pm blib/lib/Algorithm/CheckDigits/MXX_002.pm
-cp CheckDigits/M10_001.pm blib/lib/Algorithm/CheckDigits/M10_001.pm
-cp CheckDigits/M10_004.pm blib/lib/Algorithm/CheckDigits/M10_004.pm
-cp CheckDigits/MXX_004.pm blib/lib/Algorithm/CheckDigits/MXX_004.pm
-cp CheckDigits/MBase_003.pm blib/lib/Algorithm/CheckDigits/MBase_003.pm
-cp CheckDigits/M43_001.pm blib/lib/Algorithm/CheckDigits/M43_001.pm
-cp CheckDigits/M10_005.pm blib/lib/Algorithm/CheckDigits/M10_005.pm
-cp CheckDigits/MXX_005.pm blib/lib/Algorithm/CheckDigits/MXX_005.pm
-cp CheckDigits/M11_006.pm blib/lib/Algorithm/CheckDigits/M11_006.pm
-cp CheckDigits/M11_004.pm blib/lib/Algorithm/CheckDigits/M11_004.pm
-cp CheckDigits/M11_012.pm blib/lib/Algorithm/CheckDigits/M11_012.pm
-cp CheckDigits/M09_001.pm blib/lib/Algorithm/CheckDigits/M09_001.pm
-cp CheckDigits/MXX_003.pm blib/lib/Algorithm/CheckDigits/MXX_003.pm
-cp CheckDigits/M11_008.pm blib/lib/Algorithm/CheckDigits/M11_008.pm
-cp CheckDigits/M89_001.pm blib/lib/Algorithm/CheckDigits/M89_001.pm
-cp CheckDigits/MBase_002.pm blib/lib/Algorithm/CheckDigits/MBase_002.pm
-cp CheckDigits/M11_011.pm blib/lib/Algorithm/CheckDigits/M11_011.pm
-cp CheckDigits/MBase_001.pm blib/lib/Algorithm/CheckDigits/MBase_001.pm
-cp CheckDigits/M10_009.pm blib/lib/Algorithm/CheckDigits/M10_009.pm
-cp CheckDigits/M11_002.pm blib/lib/Algorithm/CheckDigits/M11_002.pm
-cp CheckDigits.pm blib/lib/Algorithm/CheckDigits.pm
-cp CheckDigits/MXX_001.pm blib/lib/Algorithm/CheckDigits/MXX_001.pm
-cp CheckDigits/M10_011.pm blib/lib/Algorithm/CheckDigits/M10_011.pm
-cp CheckDigits/M11_007.pm blib/lib/Algorithm/CheckDigits/M11_007.pm
-cp CheckDigits/M11_015.pm blib/lib/Algorithm/CheckDigits/M11_015.pm
-cp CheckDigits/M23_002.pm blib/lib/Algorithm/CheckDigits/M23_002.pm
-cp CheckDigits/M10_002.pm blib/lib/Algorithm/CheckDigits/M10_002.pm
-cp CheckDigits/M11_009.pm blib/lib/Algorithm/CheckDigits/M11_009.pm
-cp CheckDigits/M10_010.pm blib/lib/Algorithm/CheckDigits/M10_010.pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_001.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_010.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M97_002.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M23_001.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M97_001.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M16_001.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M10_006.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_013.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M07_001.3pm
-Manifying blib/man3/Algorithm::CheckDigits::MXX_006.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M10_008.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_017.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M10_003.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_016.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_003.3pm
-Manifying blib/man3/Algorithm::CheckDigits::MXX_002.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M10_001.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M10_004.3pm
-Manifying blib/man3/Algorithm::CheckDigits::MXX_004.3pm
-Manifying blib/man3/Algorithm::CheckDigits::MBase_003.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M43_001.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M10_005.3pm
-Manifying blib/man3/Algorithm::CheckDigits::MXX_005.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_006.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_004.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_012.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M09_001.3pm
-Manifying blib/man3/Algorithm::CheckDigits::MXX_003.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_008.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M89_001.3pm
-Manifying blib/man3/Algorithm::CheckDigits::MBase_002.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_011.3pm
-Manifying blib/man3/Algorithm::CheckDigits::MBase_001.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M10_009.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M10_011.3pm
-Manifying blib/man3/Algorithm::CheckDigits::MXX_001.3pm
-Manifying blib/man3/Algorithm::CheckDigits.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_002.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_007.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_015.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M11_009.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M10_002.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M23_002.3pm
-Manifying blib/man3/Algorithm::CheckDigits::M10_010.3pm
- MAMAWE/Algorithm-CheckDigits-0.50.tar.gz
- /usr/bin/make -- OK
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
-Running make test
-PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
-t/checkdigits.....ok
-t/ecno............ok
-t/iban............ok
-t/imei............ok
-t/isbn13..........ok
-t/pod-coverage....skipped
- all skipped: Test::Pod::Coverage 1.00 required for testing POD coverage
-t/pod.............skipped
- all skipped: Test::Pod 1.00 required for testing POD
-t/upc.............ok
-t/valid...........ok
-All tests successful, 2 tests skipped.
-Files=9, Tests=448, 2 wallclock secs ( 0.35 cusr + 0.80 csys = 1.15 CPU)
- MAMAWE/Algorithm-CheckDigits-0.50.tar.gz
- /usr/bin/make test -- OK
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
-Running make install
-Prepending /root/.cpan/build/Algorithm-CheckDigits-0.50-mL1o1L/blib/arch /root/.cpan/build/Algorithm-CheckDigits-0.50-mL1o1L/blib/lib to PERL5LIB for 'install'
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_011.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/MBase_002.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/MXX_005.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_009.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M10_002.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/MXX_001.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/MXX_004.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M43_001.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M10_010.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M10_004.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_003.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/MBase_003.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/MXX_002.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_004.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_010.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_006.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M23_002.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M09_001.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_013.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_008.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_002.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M07_001.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M10_003.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M23_001.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/MBase_001.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_016.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_017.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_001.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M97_001.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_007.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M10_006.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M10_008.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M10_001.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_015.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M16_001.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/MXX_003.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M10_011.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M10_005.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M89_001.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M10_009.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/MXX_006.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M97_002.pm
-Installing /usr/lib/perl5/site_perl/5.10.0/Algorithm/CheckDigits/M11_012.pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_016.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::MXX_002.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M10_003.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::MBase_002.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::MXX_001.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_006.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::MBase_001.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_009.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_004.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_015.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M10_001.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M10_011.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M09_001.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_002.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_013.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M10_006.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M10_010.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::MBase_003.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_017.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M97_001.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::MXX_005.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M23_001.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::MXX_003.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M10_008.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M10_009.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::MXX_006.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M23_002.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M43_001.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M07_001.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_003.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M16_001.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_011.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M10_002.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M10_005.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_008.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_007.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_010.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M89_001.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_012.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M11_001.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M10_004.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::M97_002.3pm
-Installing /usr/share/man/man3/Algorithm::CheckDigits::MXX_004.3pm
-Writing /usr/lib/perl5/site_perl/5.10.0/i586-linux-thread-multi/auto/Algorithm/CheckDigits/.packlist
-Appending installation info to /usr/lib/perl5/5.10.0/i586-linux-thread-multi/perllocal.pod
- MAMAWE/Algorithm-CheckDigits-0.50.tar.gz
- /usr/bin/make install -- OK
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
-|--------------------
-
-
-=== Install Biblio::EndnoteStyle ===
-|--------------------
-cpan[2]> install Biblio::EndnoteStyle
-|--------------------
-
-
-
-
-=== Install the "CGI::Session::Serialize::yaml" Perl Module ===
-
-[Install CGI::Session::Serialize::yaml "instead" of CGI::Session to avoid problems related to JSON::Syck when installing CGI::Session. Don't worry: by installing CGI::Session::Serialize::yaml you are also installing CGI::Session]:
-|--------------------
-cpan[3]> install CGI::Session::Serialize::yaml
-
-[...]
-CGI-Session-Serialize-yaml-4.24/README
-CGI-Session-Serialize-yaml-4.24/Build.PL
-CGI-Session-Serialize-yaml-4.24/Makefile.PL
-CPAN: File::Temp loaded ok (v0.18)
-CPAN: Module::Build loaded ok (v0.280801)
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
-
- CPAN.pm: Going to build R/RS/RSAVAGE/CGI-Session-Serialize-yaml-4.24.tgz
-
-Checking whether your kit is complete...
-Looks good
-
-Checking prerequisites...
- - ERROR: Test::Pod is not installed
- - ERROR: CGI::Session is not installed
- - ERROR: CGI::Session::ErrorHandler is not installed
-
-ERRORS/WARNINGS FOUND IN PREREQUISITES. You may wish to install the versions
-of the modules indicated above before proceeding with this installation
-
-Creating new 'Build' script for 'CGI-Session-Serialize-yaml' version '4.24'
-Could not read '/root/.cpan/build/CGI-Session-Serialize-yaml-4.24-YmsZPx/META.yml'. Falling back to other methods to determine prerequisites
----- Unsatisfied dependencies detected during ----
----- RSAVAGE/CGI-Session-Serialize-yaml-4.24.tgz ----
- CGI::Session [requires]
- CGI::Session::ErrorHandler [requires]
- Test::Pod [build_requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-[...]
-
-Checking prerequisites...
- - ERROR: Test::Pod is not installed
-
-ERRORS/WARNINGS FOUND IN PREREQUISITES. You may wish to install the versions
-of the modules indicated above before proceeding with this installation
-
-Creating new 'Build' script for 'CGI-Session' version '4.38'
-Could not read '/root/.cpan/build/CGI-Session-4.38-RYliaM/META.yml'. Falling back to other methods to determine prerequisites
----- Unsatisfied dependencies detected during ----
----- MARKSTOS/CGI-Session-4.38.tar.gz ----
- Test::Pod [build_requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-[...]
-All tests successful, 1 test skipped.
-Files=11, Tests=19, 2 wallclock secs ( 0.83 cusr + 1.08 csys = 1.91 CPU)
- PETDANCE/Test-Pod-1.26.tar.gz
- /usr/bin/make test -- OK
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
-Running make install
-P/PE/PETDANCE/Test-Pod-1.26.tar.gz is just needed temporarily during building or testing. Do you want to install it permanently? (Y/n) [yes]
-
-cpan[4]> quit
-Lockfile removed.
-|--------------------
-
-
-=== Install some "Class" Perl Modules ===
-To install the Class::Accessor Perl Module we'll use the available software package in openSUSE 11.0 (using yast) instead of downloading it from CPAN:
-|--------------------
-myhost:~/Koha-3.00.00 # yast -i perl-Class-Accessor
-|--------------------
-
-[this will also install a dependency: perl-Carp-Assert]
-
-|--------------------
-myhost:~/Koha-3.00.00 # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install Class::Factory::Util
-
-cpan[2]> quit
-Lockfile removed.
-|--------------------
-
-
-
-=== Install DBD::MySQL ===
-|--------------------
-myhost:~/koha-3.00.00 # yast -i perl-DBD-mysql
-|--------------------
-[this will also install a dependency: perl-Data-Showtable]
-
-=== Install some "Data" Perl Modules ===
-|--------------------
-myhost:~/koha-3.00.00 # cpan
-CPAN: File::HomeDir loaded ok (v0.69)
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install Data::ICal
-
-CPAN: File::Temp loaded ok (v0.18)
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
-
- CPAN.pm: Going to build J/JE/JESSE/Data-ICal-0.13.tar.gz
-
-*** Module::AutoInstall version 1.03
-*** Checking for Perl dependencies...
-[Core Features]
-- Test::More ...loaded. (0.72)
-- Test::Warn ...missing.
-- Test::NoWarnings ...missing.
-- Test::LongString ...missing.
-- Class::Accessor ...loaded. (0.31)
-- Text::vFile::asData ...missing.
-- MIME::QuotedPrint ...loaded. (3.07)
-- Class::ReturnValue ...missing.
-==> Auto-install the 5 mandatory module(s) from CPAN? [y]
-
-*** Since we're running under CPANPLUS, I'll just let it take care
- of the dependency's installation later.
-*** Module::AutoInstall configuration finished.
-Checking if your kit is complete...
-Looks good
-Warning: prerequisite Class::ReturnValue 0 not found.
-Warning: prerequisite Test::LongString 0 not found.
-Warning: prerequisite Test::NoWarnings 0 not found.
-Warning: prerequisite Test::Warn 0 not found.
-Warning: prerequisite Text::vFile::asData 0 not found.
-Writing Makefile for Data::ICal
-Could not read '/root/.cpan/build/Data-ICal-0.13-X1jsxc/META.yml'. Falling back to other methods to determine prerequisites
----- Unsatisfied dependencies detected during ----
----- JESSE/Data-ICal-0.13.tar.gz ----
- Test::LongString [requires]
- Class::ReturnValue [requires]
- Test::NoWarnings [requires]
- Text::vFile::asData [requires]
- Test::Warn [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
----- Unsatisfied dependencies detected during ----
----- JESSE/Class-ReturnValue-0.55.tar.gz ----
- Devel::StackTrace [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-Warning: prerequisite Test::Tester 0.103 not found.
-Writing Makefile for Test::NoWarnings
-Could not read '/root/.cpan/build/Test-NoWarnings-0.084-DMJBk3/META.yml'. Falling back to other methods to determine
-
-prerequisites
----- Unsatisfied dependencies detected during ----
----- FDALY/Test-NoWarnings-0.084.tar.gz ----
- Test::Tester [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-Running install for module 'Text::vFile::asData'
-'YAML' not installed, falling back to Data::Dumper and Storable to read prefs '/root/.cpan/prefs'
----- Unsatisfied dependencies detected during ----
----- RCLAMP/Text-vFile-asData-0.05.tar.gz ----
- Class::Accessor::Chained [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-
-Warning: prerequisite Array::Compare 0 not found.
-Warning: prerequisite Sub::Uplevel 0.12 not found.
-Warning: prerequisite Test::Exception 0 not found.
-Warning: prerequisite Tree::DAG_Node 0 not found.
-Writing Makefile for Test::Warn
-Could not read '/root/.cpan/build/Test-Warn-0.10-9ekdi2/META.yml'. Falling back to other methods to determine prerequisites
----- Unsatisfied dependencies detected during ----
----- CHORNY/Test-Warn-0.10.tar.gz ----
- Test::Exception [requires]
- Sub::Uplevel [requires]
- Array::Compare [requires]
- Tree::DAG_Node [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-
----- Unsatisfied dependencies detected during ----
----- ADIE/Test-Exception-0.27.tar.gz ----
- Sub::Uplevel [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-
-cpan[2]> quit
-Lockfile removed.
-|--------------------
-
-
-
-=== Install some "Date" Perl Modules ===
-|--------------------
-myhost:~/koha-3.00.00 # yast -i perl-Date-Calc
-|--------------------
-[This will also install 2 other dependencies: perl-Carp-Clan and perl-Bit-Vector]
-
-|--------------------
-myhost:~/koha-3.00.00 # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install Date::ICal
-
-
-Warning: prerequisite Date::Leapyear 1.03 not found.
-Writing Makefile for Date::ICal
----- Unsatisfied dependencies detected during ----
----- RBOW/Date-ICal-1.72.tar.gz ----
- Date::Leapyear [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-
-cpan[2]> quit
-Lockfile removed.
-
-myhost:~/koha-3.00.00 # yast -i perl-DateManip
-|--------------------
-
-
-=== Install the "Email::Date" Perl Module ===
-|--------------------
-myhost:~/koha-3.00.00 # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install Email::Date
-
-
-Warning: prerequisite Email::Abstract 2.10 not found.
-Warning: prerequisite Email::Date::Format 1.000 not found.
-Writing Makefile for Email::Date
-Could not read '/root/.cpan/build/Email-Date-1.103-LsgMdE/META.yml'. Falling back to other methods to determine prerequisites
----- Unsatisfied dependencies detected during ----
----- RJBS/Email-Date-1.103.tar.gz ----
- Email::Abstract [requires]
- Email::Date::Format [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-Warning: prerequisite Email::Simple 1.91 not found.
-Writing Makefile for Email::Abstract
-Could not read '/root/.cpan/build/Email-Abstract-2.134-zLB1QI/META.yml'. Falling back to other methods to determine prerequisites
----- Unsatisfied dependencies detected during ----
----- RJBS/Email-Abstract-2.134.tar.gz ----
- Email::Simple [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-cpan[2]> quit
-Lockfile removed.
-|--------------------
-
-=== Install the "GD" Perl Module ===
-|--------------------
-myhost:~/koha-3.00.00 # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install GD
-
-[many lines scroll by...]
-
-**UNRECOVERABLE ERROR**
-Could not find gdlib-config in the search path. Please install libgd 2.0.28 or higher.
-If you want to try to compile anyway, please rerun this script with the option --ignore_missing_gd.
-Warning: No success on command[/usr/bin/perl Makefile.PL]
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
- LDS/GD-2.41.tar.gz
- /usr/bin/perl Makefile.PL -- NOT OK
-Running make test
- Make had some problems, won't test
-Running make install
- Make had some problems, won't install
-Could not read '/root/.cpan/build/GD-2.41-4ZLPXP/META.yml'. Falling back to other methods to determine prerequisites
-Failed during this command:
- LDS/GD-2.41.tar.gz : writemakefile NO '/usr/bin/perl Makefile.PL' returned status 512
-
-cpan[2]> quit
-Lockfile removed.
-|--------------------
-
-OK. It seems that we need to install the GD software packages. Let's do that:
-
-|--------------------
-myhost:~/koha-3.00.00 # yast -i gd
-
-myhost:~/koha-3.00.00 # yast -i gd-devel
-|--------------------
-
-And now let's try again to install the "GD" Perl Module
-|--------------------
-myhost:~/koha-3.00.00 # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install GD
-
-[many lines scroll by...]
-
-/usr/lib/gcc/i586-suse-linux/4.3/../../../../i586-suse-linux/bin/ld: cannot find -lXpm
-collect2: ld returned 1 exit status
-make: *** [blib/arch/auto/GD/GD.so] Error 1
- LDS/GD-2.41.tar.gz
- /usr/bin/make -- NOT OK
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
-Running make test
- Can't test without successful make
-Running make install
- Make had returned bad status, install seems impossible
-Failed during this command:
- LDS/GD-2.41.tar.gz : make NO
-
-cpan[2]> quit
-Lockfile removed.
-|--------------------
-
-OK. We got another error, mentioning "-lXpm". Apparently, this is related to libXpm (the "X.Org Xpm Library"). Let's install the "xorg-x11-libXpm-devel" software package:
-
-|--------------------
-myhost:~/koha-3.00.00 # yast -i xorg-x11-libXpm-devel
-|--------------------
-
-[This will also install 9 other xorg-x11-....-devel software packages: xorg-x11-proto-devel, xorg-x11-xtrans-devel, xorg-x11-libXdmcp-devel ...]
-
-If you'd try now to install again the "GD" perl module, you'd get another error, now concerning "ljpeg" (and in other attempt to "lfontconfig"... and yet in another to "lpng12"). So, let's first install the "libjpeg-devel", "fontconfig-devel" and "libpng-devel" software packages:
-
-|--------------------
-myhost:~/koha-3.00.00 # yast -i libjpeg-devel
-
-myhost:~/koha-3.00.00 # yast -i fontconfig-devel
-
-myhost:~/koha-3.00.00 # yast -i libpng-devel
-|--------------------
-
-[Installing fontconfig-devel will also install some other dependencies: zlib-devel, libexpat-devel and freetype2-devel]
-
-And now, finally, we can install the "GD" Perl Module:
-|--------------------
-myhost:~/koha-3.00.00 # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install GD
-
-cpan[2]> quit
-Lockfile removed.
-|--------------------
-
-=== Install the "GD::Barcode::UPCE" Perl Module ===
-|--------------------
-myhost:~/Koha # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install GD::Barcode::UPCE
-|--------------------
-
-=== Install the "HTML::Template::Pro" Perl Module ===
-
-In the same CPAN prompt, type the following command:
-|--------------------
-cpan[2]> install HTML::Template::Pro
-
-cpan[3]> quit
-Lockfile removed.
-|--------------------
-
-
-
-
-
-=== Install the "Lingua::Stem" Perl Module ===
-|--------------------
-myhost:~ # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install Lingua::Stem
-
-
-Checking prerequisites...
- - ERROR: Lingua::PT::Stemmer is not installed
- - ERROR: Lingua::Stem::It is not installed
- - ERROR: Lingua::Stem::Snowball::No is not installed
- - ERROR: Text::German is not installed
- - ERROR: Lingua::Stem::Snowball::Se is not installed
- - ERROR: Lingua::Stem::Fr is not installed
- - ERROR: Lingua::GL::Stemmer is not installed
- - ERROR: Lingua::Stem::Snowball::Da is not installed
- - ERROR: Lingua::Stem::Ru is not installed
-
-ERRORS/WARNINGS FOUND IN PREREQUISITES. You may wish to install the versions
-of the modules indicated above before proceeding with this installation
-
-Creating new 'Build' script for 'Lingua-Stem' version '0.83'
-Could not read '/root/.cpan/build/Lingua-Stem-0.83-cmPLcK/META.yml'. Falling back to other methods to determine prerequisites
----- Unsatisfied dependencies detected during ----
----- SNOWHARE/Lingua-Stem-0.83.tar.gz ----
- Lingua::PT::Stemmer [requires]
- Lingua::Stem::It [requires]
- Lingua::Stem::Snowball::No [requires]
- Text::German [requires]
- Lingua::Stem::Snowball::Se [requires]
- Lingua::Stem::Fr [requires]
- Lingua::GL::Stemmer [requires]
- Lingua::Stem::Snowball::Da [requires]
- Lingua::Stem::Ru [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-|--------------------
-
-
-=== Install the "HTML::Scrubber" Perl Module ===
-In the same CPAN prompt, type the following command:
-|--------------------
-cpan[2]> install HTML::Scrubber
-
-
-cpan[3]> quit
-Lockfile removed.
-|--------------------
-
-=== Install the "List::MoreUtils" Perl Module ===
-|--------------------
-myhost:~ # yast -i perl-List-MoreUtils
-|--------------------
-(If the above command does not work, you probably did not set up the "Official openSUSE 11.0 OSS Repository". See the "Configure Software Repositories" section earlier in this document that explains how you set up it inside yast).
-
-
-
-=== Install some "MARC" Perl Modules ===
-|--------------------
-myhost:~ # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install MARC::Charset
-MARC::Charset is up to date (1.0).
-
-cpan[2]> install MARC::Crosswalk::DublinCore
-
-
-Checking prerequisites...
- - ERROR: DublinCore::Record is not installed
- - ERROR: MARC::Record is not installed
-
-ERRORS/WARNINGS FOUND IN PREREQUISITES. You may wish to install the versions
-of the modules indicated above before proceeding with this installation
-
-Creating new 'Build' script for 'MARC-Crosswalk-DublinCore' version '0.02'
-Could not read '/root/.cpan/build/MARC-Crosswalk-DublinCore-0.02-xrMlqr/META.yml'. Falling back to other methods to determine
-
-prerequisites
----- Unsatisfied dependencies detected during ----
----- BRICAS/MARC-Crosswalk-DublinCore-0.02.tar.gz ----
- DublinCore::Record [requires]
- MARC::Record [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-
-cpan[3]> install MARC::File::XML
-
-
-cpan[4]> install MARC::Record
-MARC::Record is up to date (2.0.0).
-
-
-cpan[3]> quit
-Lockfile removed.
-|--------------------
-
-
-=== Install the "MIME::Lite" Perl Module ===
-|--------------------
-myhost:~/Koha-3.00.00 # yast -i perl-MIME-Lite
-|--------------------
-
-=== Install the "Mail::Sendmail" Perl Module ===
-|--------------------
-myhost:~ # yast -i perl-Mail-Sendmail
-|--------------------
-(If the above command does not work, you probably did not set up the "Official openSUSE 11.0 OSS Repository". See the "Configure Software Repositories" section earlier in this document that explains how you set up it inside yast).
-
-
-=== Install some "Net" Perl Modules ===
-|--------------------
-myhost:~ # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install Net::LDAP
-
-
-*** Module::AutoInstall version 1.03
-*** Checking for Perl dependencies...
-[Core Features]
-- Convert::ASN1 ...missing. (would need 0.07)
-==> Auto-install the 1 mandatory module(s) from CPAN? [y]
-[SASL authentication]
-- Authen::SASL ...missing. (would need 2.00)
-==> Auto-install the 1 optional module(s) from CPAN? [n]
-[LDAP URLs]
-- URI::ldap ...loaded. (1.11 >= 1.1)
-[LDAPS]
-- IO::Socket::SSL ...missing. (would need 0.81)
-==> Auto-install the 1 optional module(s) from CPAN? [n]
-[Read/Write DSML files]
-- MIME::Base64 ...loaded. (3.07_01)
-- XML::SAX::Writer ...missing.
-==> Auto-install the 1 optional module(s) from CPAN? [n]
-[Read/Write LDIF files]
-- MIME::Base64 ...loaded. (3.07_01)
-
-*** Since we're running under CPANPLUS, I'll just let it take care
- of the dependency's installation later.
-*** Module::AutoInstall configuration finished.
-
-*** Since we're running under CPANPLUS, I'll just let it take care
- of the dependency's installation later.
-Checking if your kit is complete...
-Looks good
-Warning: prerequisite Convert::ASN1 0.07 not found.
-Writing Makefile for Net::LDAP
-Could not read '/root/.cpan/build/perl-ldap-0.36-gUbl59/META.yml'. Falling back to other methods to determine prerequisites
----- Unsatisfied dependencies detected during ----
----- GBARR/perl-ldap-0.36.tar.gz ----
- Convert::ASN1 [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-
-cpan[16]> install Net::LDAP::Filter
-Net::LDAP::Filter is up to date (0.15).
-
-
-cpan[7]> install Net::Z3950::ZOOM
-Running install for module 'Net::Z3950::ZOOM'
-'YAML' not installed, falling back to Data::Dumper and Storable to read prefs '/root/.cpan/prefs'
-Running make for M/MI/MIRK/Net-Z3950-ZOOM-1.21.tar.gz
-Fetching with LWP:
- ftp://ftp.isr.ist.utl.pt/pub/CPAN/authors/id/M/MI/MIRK/Net-Z3950-ZOOM-1.21.tar.gz
-Checksum for /root/.cpan/sources/authors/id/M/MI/MIRK/Net-Z3950-ZOOM-1.21.tar.gz ok
-Net-Z3950-ZOOM-1.21/
-Net-Z3950-ZOOM-1.21/samples/
-Net-Z3950-ZOOM-1.21/samples/zoom/
-Net-Z3950-ZOOM-1.21/samples/zoom/trivial-async.pl
-Net-Z3950-ZOOM-1.21/samples/zoom/zdump.pl
-Net-Z3950-ZOOM-1.21/samples/zoom/async.pl
-Net-Z3950-ZOOM-1.21/samples/zoom/zoomscan.pl
-Net-Z3950-ZOOM-1.21/samples/zoom/zhello.pl
-Net-Z3950-ZOOM-1.21/samples/zoom/zoomtst1.pl
-Net-Z3950-ZOOM-1.21/samples/zoom/zselect
-Net-Z3950-ZOOM-1.21/samples/zoom/update.pl
-Net-Z3950-ZOOM-1.21/samples/zoom/zoomtst3.pl
-Net-Z3950-ZOOM-1.21/samples/README
-Net-Z3950-ZOOM-1.21/samples/net-z3950/
-Net-Z3950-ZOOM-1.21/samples/net-z3950/zoomtst1.pl
-Net-Z3950-ZOOM-1.21/samples/records/
-Net-Z3950-ZOOM-1.21/samples/records/esdd0006.grs
-Net-Z3950-ZOOM-1.21/samples/ccl/
-Net-Z3950-ZOOM-1.21/samples/ccl/default.bib
-Net-Z3950-ZOOM-1.21/samples/cql/
-Net-Z3950-ZOOM-1.21/samples/cql/pqf.properties
-Net-Z3950-ZOOM-1.21/samples/net-z3950-zoom/
-Net-Z3950-ZOOM-1.21/samples/net-z3950-zoom/async.pl
-Net-Z3950-ZOOM-1.21/samples/net-z3950-zoom/zoomtst1.pl
-Net-Z3950-ZOOM-1.21/samples/net-z3950-zoom/zoomtst3.pl
-Net-Z3950-ZOOM-1.21/README
-Net-Z3950-ZOOM-1.21/Changes
-Net-Z3950-ZOOM-1.21/META.yml
-Net-Z3950-ZOOM-1.21/MANIFEST
-Net-Z3950-ZOOM-1.21/ZOOM.xs
-Net-Z3950-ZOOM-1.21/MANIFEST.SKIP
-Net-Z3950-ZOOM-1.21/Makefile.PL
-Net-Z3950-ZOOM-1.21/t/
-Net-Z3950-ZOOM-1.21/t/29-events.t
-Net-Z3950-ZOOM-1.21/t/11-option-callback.t
-Net-Z3950-ZOOM-1.21/t/15-scan.t
-Net-Z3950-ZOOM-1.21/t/16-packages.t
-Net-Z3950-ZOOM-1.21/t/13-resultset.t
-Net-Z3950-ZOOM-1.21/t/24-sorting.t
-Net-Z3950-ZOOM-1.21/t/17-logging.t
-Net-Z3950-ZOOM-1.21/t/20-options.t
-Net-Z3950-ZOOM-1.21/t/12-query.t
-Net-Z3950-ZOOM-1.21/t/10-options.t
-Net-Z3950-ZOOM-1.21/t/1-Net-Z3950-ZOOM.t
-Net-Z3950-ZOOM-1.21/t/22-query.t
-Net-Z3950-ZOOM-1.21/t/27-logging.t
-Net-Z3950-ZOOM-1.21/t/25-scan.t
-Net-Z3950-ZOOM-1.21/t/19-events.t
-Net-Z3950-ZOOM-1.21/t/14-sorting.t
-Net-Z3950-ZOOM-1.21/t/28-charset.t
-Net-Z3950-ZOOM-1.21/t/23-resultset.t
-Net-Z3950-ZOOM-1.21/t/26-packages.t
-Net-Z3950-ZOOM-1.21/t/18-charset.t
-Net-Z3950-ZOOM-1.21/t/2-ZOOM.t
-Net-Z3950-ZOOM-1.21/t/21-option-callback.t
-Net-Z3950-ZOOM-1.21/typemap
-Net-Z3950-ZOOM-1.21/lib/
-Net-Z3950-ZOOM-1.21/lib/ZOOM.pm
-Net-Z3950-ZOOM-1.21/lib/ZOOM.pod
-Net-Z3950-ZOOM-1.21/lib/Net/
-Net-Z3950-ZOOM-1.21/lib/Net/Z3950/
-Net-Z3950-ZOOM-1.21/lib/Net/Z3950/ZOOM.pm
-Net-Z3950-ZOOM-1.21/lib/Net/Z3950.pm
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
-
- CPAN.pm: Going to build M/MI/MIRK/Net-Z3950-ZOOM-1.21.tar.gz
-
-ERROR: Unable to call script: yaz-config
-If you are using a YAZ installation from the Debian package "yaz", you
-will also need to install "libyaz-dev" in order to build this module.
-Warning: No success on command[/usr/bin/perl Makefile.PL]
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
- MIRK/Net-Z3950-ZOOM-1.21.tar.gz
- /usr/bin/perl Makefile.PL -- NOT OK
-Running make test
- Make had some problems, won't test
-Running make install
- Make had some problems, won't install
-Could not read '/root/.cpan/build/Net-Z3950-ZOOM-1.21-gHBrEl/META.yml'. Falling back to other methods to determine
-
-prerequisites
-Failed during this command:
- MIRK/Net-Z3950-ZOOM-1.21.tar.gz : writemakefile NO '/usr/bin/perl Makefile.PL' returned status 512
-|--------------------
-
-== Installing libyaz, libyaz-devel and yaz for Net::Z3950::ZOOM ==
-
-OK... So we ran through a problem with a missing "yaz-config" while installing Net::Z3950::ZOOM. To solve this, let's first install the libyaz package:
-
- * Install the libyaz package:
-|--------------------
-# yast -i libyaz
-|--------------------
-[This will also install 1 dependency: libxslt]
-
-We also have to install another package:libyaz-devel. libyaz-devel is NOT available in the openSUSE 11 DVD but it is available in the Official openSUSE 11 OSS Repository. If you have skipped that step, add that repository in yast first.
-
- * Install the libyaz-devel package:
-|--------------------
-# yast -i libyaz-devel
-|--------------------
-(If the above command does not work, you probably did not set up the "Official openSUSE 11.0 OSS Repository". See the "Configure Software Repositories" section earlier in this document that explains how you set up it inside yast).
-
-Installing libyaz-devel will also add some other packages that libyaz-devel depends on, namely:
-zlib-devel, tcpd-devel, tack, libgpg-error-devel, ncurses-devel, libopenssl-devel, libgcrypt-devel, readline-devel, libxml2-devel and libxslt-devel.
-
- * Install the yaz package:
-|--------------------
-# yast -i yaz
-|--------------------
-
-(//15-Jul-2008: Thanks to Bob Ewart for catching this missing step of installing yaz//)
-
-
-Let's now install the Net::Z3950::ZOOM Perl Module:
-
-|--------------------
-myhost:~ # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install Net::Z3950::ZOOM
-cpan[2]> quit
-Lockfile removed.
-|--------------------
-
-
-
-
-=== Install some "PDF" Perl Modules ===
-
-|--------------------
-myhost:~ # yast -i perl-PDF-API2
-
-myhost:~ # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install PDF::API2::Page
-PDF::API2::Page is up to date (2.001).
-
-cpan[2]> install PDF::API2::Util
-PDF::API2::Util is up to date (2.000).
-
-
-cpan[3]> install PDF::Reuse
-
-Warning: prerequisite Font::TTF 0 not found.
-Warning: prerequisite Text::PDF::TTFont0 0 not found.
-Writing Makefile for PDF::Reuse
-Could not read '/root/.cpan/build/PDF-Reuse-0.35-rBhjys/META.yml'. Falling back to other methods to determine prerequisites
----- Unsatisfied dependencies detected during ----
----- LARSLUND/PDF-Reuse-0.35.tar.gz ----
- Text::PDF::TTFont0 [requires]
- Font::TTF [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-
-cpan[4]> install PDF::Reuse::Barcode
-
-Warning: prerequisite Barcode::Code128 0 not found.
-Writing Makefile for PDF::Reuse::Barcode
----- Unsatisfied dependencies detected during ----
----- LARSLUND/PDF-Reuse-Barcode-0.05.tar.gz ----
- Barcode::Code128 [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-[...]
-
-Barcode-Code128-2.01/lib/Barcode/
-Barcode-Code128-2.01/lib/Barcode/Code128.pm
-Barcode-Code128-2.01/META.yml
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
-
- CPAN.pm: Going to build W/WR/WRW/Barcode-Code128-2.01.tar.gz
-
-Checking if your kit is complete...
-Looks good
-Writing Makefile for Barcode::Code128
-Could not read '/root/.cpan/build/Barcode-Code128-2.01-1g3s6u/META.yml'. Falling back to other methods to determine prerequisites
-cp lib/Barcode/Code128.pm blib/lib/Barcode/Code128.pm
-Manifying blib/man3/Barcode::Code128.3pm
- WRW/Barcode-Code128-2.01.tar.gz
- /usr/bin/make -- OK
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
-Running make test
-PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
-t/barcode....ok
-t/gif........ok 1/0skipped
- all skipped: no reason given
-t/png........FAILED test 2
- Failed 1/2 tests, 50.00% okay
-Failed Test Stat Wstat Total Fail List of Failed
--------------------------------------------------------------------------------
-t/png.t 2 1 2
-1 test skipped.
-Failed 1/3 test scripts. 0/4 subtests failed.
-Files=3, Tests=4, 1 wallclock secs ( 0.17 cusr + 0.27 csys = 0.44 CPU)
-Failed 1/3 test programs. 0/4 subtests failed.
-make: *** [test_dynamic] Error 255
- WRW/Barcode-Code128-2.01.tar.gz
- /usr/bin/make test -- NOT OK
-//hint// to see the cpan-testers results for installing this module, try:
- reports WRW/Barcode-Code128-2.01.tar.gz
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
-Running make install
- make test had returned bad status, won't install without force
-Running make for L/LA/LARSLUND/PDF-Reuse-Barcode-0.05.tar.gz
- Has already been unwrapped into directory /root/.cpan/build/PDF-Reuse-Barcode-0.05-xyOb8t
-
- CPAN.pm: Going to build L/LA/LARSLUND/PDF-Reuse-Barcode-0.05.tar.gz
-
-Warning: Prerequisite 'Barcode::Code128 => 0' for 'L/LA/LARSLUND/PDF-Reuse-Barcode-0.05.tar.gz' failed when processing 'W/WR/WRW/Barcode-Code128-2.01.tar.gz' with 'make_test => NO'. Continuing, but chances to succeed are limited.
-cp Barcode.pm blib/lib/PDF/Reuse/Barcode.pm
-Manifying blib/man3/PDF::Reuse::Barcode.3pm
- LARSLUND/PDF-Reuse-Barcode-0.05.tar.gz
- /usr/bin/make -- OK
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
-Running make test
-PERL_DL_NONLAZY=1 /usr/bin/perl "-Iblib/lib" "-Iblib/arch" test.pl
-1..15
-# Running under perl version 5.010000 for linux
-# Current time local: Mon Dec 1 23:33:14 2008
-# Current time GMT: Mon Dec 1 23:33:14 2008
-# Using Test.pm version 1.25
-ok 1
-ok 2
-ok 3
-ok 4
-ok 5
-ok 6
-ok 7
-ok 8
-ok 9
-ok 10
-ok 11
-ok 12
-ok 13
-Can't find Barcode::Code128 - can't produce those barcodes
-not ok 14
-# Failed test 14 in test.pl at line 18
-# test.pl line 18 is: ok(find('Barcode::Code128'));
-ok 15
- LARSLUND/PDF-Reuse-Barcode-0.05.tar.gz
-Tests succeeded but one dependency not OK (Barcode::Code128)
-Warning (usually harmless): 'YAML' not installed, will not store persistent state
- LARSLUND/PDF-Reuse-Barcode-0.05.tar.gz
- [dependencies] -- NA
-Running make install
- make test had returned bad status, won't install without force
-Failed during this command:
- WRW/Barcode-Code128-2.01.tar.gz : make_test NO
- LARSLUND/PDF-Reuse-Barcode-0.05.tar.gz : make_test NO one dependency not OK (Barcode::Code128)
-
-|--------------------
-
-
-**01-Dec-2008**: Oh well... So, it seems that the installation of PDF::Reuse::Barcode failed due to a Perl Module dependency - "Barcode::Code128" - that, in turn, fails to install when doing some PNG related tests. According to Galen Charlton (from LibLime) - http://lists.katipo.co.nz/public/koha/2007-December/012843.html - "There seem to be various problems with Barcode::Code128 on various platforms, particularly with its test suite. The barcode generation functionality is used in only a couple places in Koha, so for quick-and-dirty testing, doing a force install of that module should be OK."
-
-On a related note, this "Barcode::Code128" installation bug is being tracked at:
-
-#28369: test result negative maybe due to library skew
- http://rt.cpan.org/Public/Bug/Display.html?id=28369
-
-OK. So, let's do then a "force install" of the Barcode::Code128 Perl Module in the same CPAN prompt:
-
-|--------------------
-cpan[5]> force install "Barcode::Code128"
-|--------------------
-
-And still in the same CPAN prompt, let's now try again to install "PDF::Reuse::Barcode":
-|--------------------
-cpan[6]> install PDF::Reuse::Barcode
-|--------------------
-
-=== Install the "POE" Perl Module ===
-In the same CPAN prompt, type the following command:
-|--------------------
-cpan[5]> install POE
-
-
-Some of POE's tests require a functional network.
-You can skip these tests if you'd like.
-
-Would you like to skip the network tests? [n]
-
-*** Some optional features may not be available:
-*** Curses 1.08 could not be loaded.
-*** Event 1 could not be loaded.
-*** Gtk 0.7009 could not be loaded.
-*** IO::Pty 1.02 could not be loaded.
-*** Socket6 0.14 could not be loaded.
-*** Tk 800.027 could not be loaded.
-Checking if your kit is complete...
-Looks good
-Warning: prerequisite POE::Test::Loops 1.002 not found.
-Writing Makefile for POE
-Could not read '/root/.cpan/build/POE-1.003-0euNum/META.yml'. Falling back to other methods to determine prerequisites
----- Unsatisfied dependencies detected during ----
----- RCAPUTO/POE-1.003.tar.gz ----
- POE::Test::Loops [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-|--------------------
-
-
-=== Install the "SMS::Send" Perl Module ===
-
-In the same CPAN prompt, type the following command:
-|--------------------
-cpan[6]> install SMS::Send
-
-Checking if your kit is complete...
-Looks good
-Warning: prerequisite Class::Adapter 1.00 not found.
-Warning: prerequisite Params::Util 0.14 not found.
-Writing Makefile for SMS::Send
-Could not read '/root/.cpan/build/SMS-Send-0.05-xGdd7H/META.yml'. Falling back to other methods to determine prerequisites
----- Unsatisfied dependencies detected during ----
----- ADAMK/SMS-Send-0.05.tar.gz ----
- Params::Util [requires]
- Class::Adapter [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-cpan[7]> quit
-Lockfile removed.
-
-|--------------------
-
-=== Install the "Schedule::At" Perl Module ===
-
- * Install "at":
-|--------------------
-# yast -i at
-|--------------------
- * Install the Schedule::At Perl module:
-|--------------------
-myhost:~ # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-cpan[1]> install Schedule::At
-|--------------------
-
-=== Install some "Text" Perl Modules ===
-In the same CPAN prompt, type the following command:
-|--------------------
-cpan[2]> install Text::CSV
-
-
-cpan[3]> install Text::CSV_XS
-
-
-cpan[4]> install Text::Iconv
-
-cpan[5]> quit
-Lockfile removed.
-|--------------------
-
-
-
-=== Install some "XML" Perl Modules ===
-|--------------------
-myhost:~ # yast -i perl-XML-Dumper
-
-myhost:~ # yast -i perl-XML-LibXSLT
-
-
-myhost:~ # cpan
-
-cpan shell -- CPAN exploration and modules installation (v1.9205)
-ReadLine support enabled
-
-
-cpan[1]> install XML::RSS
-
-Warning: prerequisite DateTime 0 not found.
-Warning: prerequisite DateTime::Format::Mail 0 not found.
-Warning: prerequisite DateTime::Format::W3CDTF 0 not found.
-Warning: prerequisite Test::Manifest 0.9 not found.
-Writing Makefile for XML::RSS
-Could not read '/root/.cpan/build/XML-RSS-1.32-7BXl7q/META.yml'. Falling back to other methods to determine prerequisites
----- Unsatisfied dependencies detected during ----
----- SHLOMIF/XML-RSS-1.32.tar.gz ----
- DateTime [requires]
- DateTime::Format::W3CDTF [requires]
- Test::Manifest [requires]
- DateTime::Format::Mail [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-Warning: prerequisite DateTime::Locale 0.4 not found.
-Warning: prerequisite DateTime::TimeZone 0.59 not found.
-Warning: prerequisite Params::Validate 0.76 not found.
-Writing Makefile for DateTime
-Could not read '/root/.cpan/build/DateTime-0.4302-YXqzkk/META.yml'. Falling back to other methods to determine prerequisites
----- Unsatisfied dependencies detected during ----
----- DROLSKY/DateTime-0.4302.tar.gz ----
- DateTime::Locale [requires]
- DateTime::TimeZone [requires]
- Params::Validate [requires]
- Time::y2038 [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-
-Checking prerequisites...
- - ERROR: Params::Validate is not installed
-
-ERRORS/WARNINGS FOUND IN PREREQUISITES. You may wish to install the versions
-of the modules indicated above before proceeding with this installation
-
-Creating new 'Build' script for 'DateTime-Locale' version '0.4001'
-Could not read '/root/.cpan/build/DateTime-Locale-0.4001-ThLGMW/META.yml'. Falling back to other methods to determine
-
-prerequisites
----- Unsatisfied dependencies detected during ----
----- DROLSKY/DateTime-Locale-0.4001.tar.gz ----
- Params::Validate [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-
-Checking prerequisites...
- - ERROR: Class::Singleton is not installed
-
-ERRORS/WARNINGS FOUND IN PREREQUISITES. You may wish to install the versions
-of the modules indicated above before proceeding with this installation
-
-Creating new 'Build' script for 'DateTime-TimeZone' version '0.77'
-Could not read '/root/.cpan/build/DateTime-TimeZone-0.77-MPrKnn/META.yml'. Falling back to other methods to determine
-
-prerequisites
----- Unsatisfied dependencies detected during ----
----- DROLSKY/DateTime-TimeZone-0.77.tar.gz ----
- Class::Singleton [requires]
-Shall I follow them and prepend them to the queue
-of modules we are processing right now? [yes]
-
-[...]
-
-B/BD/BDFOY/Test-Manifest-1.22.tar.gz is just needed temporarily during building or testing. Do you want to install it permanently? (Y/n) [yes]
-
-cpan[2]> quit
-Lockfile removed.
-|--------------------
-
-=== Install the "YAML::Syck" Perl Module ===
-|--------------------
-myhost:~ # yast -i perl-YAML-Syck
-|--------------------
-
-
-==== Create the Koha User and Group ====
+== Create the Koha User and Group ==
|--------------------
# useradd koha
# groupadd koha
|--------------------
-
-
-==== Run make test ====
+== Run make test ==
|--------------------
myhost:~/Koha # make test
cp koha-tmpl/opac-tmpl/prog/famfamfam/silk/error_go.png blib/OPAC_TMPL_DIR/prog/famfamfam/silk/error_go.png
cp opac/opac-changelanguage.pl blib/OPAC_CGI_DIR/opac/opac-changelanguage.pl
-cp koha-tmpl/intranet-tmpl/prog/img/itemtypeimg/liblime-kids/card.gif
-
-blib/INTRANET_TMPL_DIR/prog/img/itemtypeimg/liblime-kids/card.gif
+cp koha-tmpl/intranet-tmpl/prog/img/itemtypeimg/liblime-kids/card.gif blib/INTRANET_TMPL_DIR/prog/img/itemtypeimg/liblime-kids/card.gif
cp koha-tmpl/opac-tmpl/prog/famfamfam/mini/note.gif blib/OPAC_TMPL_DIR/prog/famfamfam/mini/note.gif
-|--------------------
+
[many more lines beginning with "cp" should appear...]
-|--------------------
-t/Amazon....................ok
-t/Barcodes_PrinterConfig....ok
-t/Bookfund..................ok
-t/Bookseller................ok
-t/Boolean...................ok
-t/Branch....................ok
-t/Calendar..................ok
-t/Charset...................ok
-t/Debug.....................# BEFORE use: $debug is not defined
+t/Amazon.t .................. ok
+t/Barcodes_PrinterConfig.t .. ok
+t/Bookfund.t ................ ok
+t/Bookseller.t .............. ok
+t/Boolean.t ................. ok
+t/Branch.t .................. ok
+t/Calendar.t ................ ok
+t/Charset.t ................. ok
+t/Debug.t ................... # BEFORE use: $debug is not defined
# BEFORE use: $cgi_debug is not defined
-t/Debug.....................ok 1/3# AFTER use: $debug is 0
+t/Debug.t ................... 1/3 # AFTER use: $debug is 0
# AFTER use: $cgi_debug is 0
# Done.
-t/Debug.....................ok
-t/dummy.....................ok
-t/Input.....................ok
-t/Koha......................ok
-t/Languages.................ok
-t/Maintainance..............ok
-t/Output....................ok
-t/Record....................ok
-t/Review....................ok
-t/Scrubber..................ok 1/10# Note: scrubber test output will have whitespace collapsed for readability
+t/Debug.t ................... ok
+t/dummy.t ................... ok
+t/Input.t ................... ok
+t/Koha.t .................... ok
+t/Languages.t ............... ok
+t/Maintainance.t ............ ok
+t/Output.t .................. ok
+t/Record.t .................. ok
+t/Review.t .................. ok
+t/Scrubber.t ................ 1/10 # Note: scrubber test output will have whitespace collapsed for readability
# done.
-t/Scrubber..................ok
-t/Stats.....................ok
+t/Scrubber.t ................ ok
+t/Stats.t ................... ok
All tests successful.
-Files=19, Tests=47, 21 wallclock secs ( 4.82 cusr + 5.55 csys = 10.37 CPU)
+Files=19, Tests=47, 3 wallclock secs ( 0.06 usr 0.08 sys + 2.12 cusr 0.25 csys = 2.51 CPU)
+Result: PASS
|--------------------
+So here it shows all is OK. I don't expect any problems to appear, otherwise you may need to read the document on installing Koha on openSUSE 11.0.
-
-=== Run "make install" ===
+== Run "make install" ==
Now, we will run make install:
|--------------------
[Several lines starting with "Manifying" and many lines starting with "Installing" will scroll by...]
|--------------------
-Installing /usr/share/koha/man/man3/reports::catalogue_out.3pm
-Installing /usr/share/koha/man/man3/reports::dictionary.3pm
-Installing /usr/share/koha/man/man3/C4::Search::PazPar2.3pm
-Installing /usr/share/koha/man/man3/C4::Scrubber.3pm
-Installing /usr/share/koha/man/man3/reports::itemslost.3pm
-Installing /usr/share/koha/man/man3/C4::Barcodes::PrinterConfig.3pm
+Installing /usr/share/koha/man/man3/serials::serial-issues.3pm
+Installing /usr/share/koha/man/man3/C4::Context.3pm
+Installing /usr/share/koha/man/man3/cataloguing::value_builder::unimarc_field_123f.3pm
+Installing /usr/share/koha/man/man3/cataloguing::addbiblio.3pm
+Installing /usr/share/koha/man/man3/cataloguing::value_builder::unimarc_field_128c.3pm
+Installing /usr/share/koha/man/man3/tools::viewlog.3pm
+Installing /usr/share/koha/man/man3/admin::branches.3pm
Koha's files have now been installed.
myhost:/etc #
|--------------------
-==== Create /etc/bash.bashrc.local ====
+== Create /etc/bash.bashrc.local ==
Create a file called bash.bashrc.local in the /etc directory:
|--------------------
myhost:/etc # vim /etc/bash.bashrc.local
|--------------------
-add these 2 lines in the file:
+Add these 2 lines in the file:
|--------------------
export KOHA_CONF=/etc/koha/koha-conf.xml
export PERL5LIB=/usr/share/koha/lib
|--------------------
-- EXIT THE SHELL AND LOG BACK IN.
+Exit the shell and log back in.
|--------------------
myhost:/etc # exit
|--------------------
PERL5LIB=/usr/share/koha/lib
|--------------------
-=== Koha's Web Installer ===
+== Koha's Web Installer ==
Access Koha's web installer at:
-http://192.168.0.2:8080/
+http://192.168.1.16:8080/
Your browser will probably say that:
|--------------------
-" The server at 192.168.0.2 is taking too long to respond."
+" The server at 192.168.1.16 is taking too long to respond."
|--------------------
-OK... It seems that we have to do some things yet.
-
+OK... It seems that we have still have to do something.
== Create a symbolic link to /etc/koha/koha-httpd.conf ==
-Let's create a symbolic link to the /etc/koha/koha-httpd.conf file in the /etc/apache2/vhosts.d directory:
+Let's create a symbolic link to the /etc/koha/koha-httpd.conf file in the /etc/apache2/vhosts.d directory
+:
|--------------------
myhost:~ # cd /etc/apache2/vhosts.d/
|--------------------
myhost:/etc/apache2/conf.d # service apache2 restart
Syntax error on line 28 of /etc/apache2/conf.d/koha-httpd.conf:
-Invalid command 'RewriteEngine', perhaps misspelled or defined by a module not included in the server configuration
+Invalid command 'RewriteEngine', perhaps misspelled or defined by a module
+not included in the server configuration
|--------------------
+== Enable the mod_rewrite Apache module ==
-
-== Enable the mod_rewrite and mod_deflate Apache modules ==
-
-OK... It seems that we need to enable the mod_rewrite and the mod_deflate Apache module:
+OK... It seems that we need to enable the mod_rewrite Apache module:
|--------------------
-myhost:/etc/sysconfig # a2enmod rewrite deflate
+myhost:/etc/sysconfig # a2enmod rewrite
|--------------------
-[If the above command seems NOT to work, for some reason, do this - edit /etc/sysconfig/apache2 and add the words "rewrite" -and "deflate"- (without the quotes) at the end of the APACHE_MODULES line, right before the right quote]
+If the above command seems NOT to work, for some reason, do this - edit /etc/sysconfig/apache2 and add the word "rewrite" (without the quotes) at the end of the APACHE_MODULES line, right before the right quote
|--------------------
myhost:/etc/sysconfig # service apache2 restart
Syntax OK
Starting httpd2 (prefork) done
|--------------------
-
== Change koha-httpd.conf ==
-If you browsed again to http://192.168.0.2:8080 you would still get no answer. This is because we still have to do some changes to the koha-httpd.conf file.
+If you browsed again to http://192.168.1.16:8080 you would still get no answer. This is because we still have to do some changes to the koha-httpd.conf file. Unless you did not follow this tutorial and port 8080 is not open. Look back in this page to find out how.
First, let's create a backup of this file:
|--------------------
myhost:/etc/apache2/vhosts.d # cp koha-httpd.conf koha-httpd.conf.ORIG
-
myhost:/etc/koha # vim koha-httpd.conf
|--------------------
In that file, you should find two VirtualHost sections: one for the OPAC area of Koha and the other one for the Intranet.
If the two virtualHost directives - the lines that start with <nowiki><VirtualHost</nowiki> - in that file are set for the IP Address 127.0.0.2, replace them by the correct IP address of your server.
-That file will have 2 ServerName directives (one for each of the 2 VirtualHosts). In those directives, you should have the IP of your server -or- the FQDN of your server (example: ServerName www.koha.test).
+That file will have 2 ServerName directives (one for each of the 2 VirtualHosts).
+In those directives, you should have the IP of your server -or- the FQDN of your server (example: ServerName koha-server.univ.org).
Now, restart again Apache:
|--------------------
Starting httpd2 (prefork) done
|--------------------
-
Try to access the web page:
-http://192.168.0.2/
+http://192.168.1.16/
If you get again the "It Works!" web page, you'll probably have to Refresh/Reload the page in your browser (press the F5 key).
You don't have permission to access / on this server.
-Additionally, a 403 Forbidden error was encountered while trying to use an ErrorDocument to handle the request.
-Apache/2.2.4 (Linux/SUSE) Server at 192.168.0.2 Port 8080
+Additionally, a 403 Forbidden error was encountered while trying to use an
+ErrorDocument to handle the request.
+Apache/2.2.4 (Linux/SUSE) Server at 192.168.1.16 Port 8080
|--------------------
OK. Let's add then the following directive at the end of the koha-httpd.conf file:
|--------------------
<Directory /usr/share/koha>
- Order allow,deny
- Allow from all
+ Order allow,deny
+ Allow from all
</Directory>
|--------------------
OK. Load again the following page in your web browser:
-http://192.168.0.2
+http://192.168.1.16
+
After some seconds you should be redirected to:
http://192.168.0.2/cgi-bin/koha/maintenance.pl
-
-and see a Koha page saying:
-|--------------------
-"System Maintenance ... we'll be back soon! If you have any questions, please contact the Site Administrator"
-|--------------------
+and see a Koha page with the following text:
+"System Maintenance... we'll be back soon! If you have any questions, please contact the Site Administrator"
This is actually GOOD NEWS! :) It's now time to set up Koha in the Intranet interface.
-
To do that, browse to:
-
http://192.168.0.2:8080
+You should see a page with the title "Welcome to the Koha Web Installer", and with a "Username" and a "Password" textboxes.
-== Enable port 8080 in the firewall ==
-
-After a while the page will probably time out. This is because we now have to allow the 8080 port in the firewall.
-
-Let's run yast and do that:
-|--------------------
-myhost:/etc/apache2/vhosts.d # yast
-|--------------------
-Inside yast, go to "Security and Users" -> "Firewall"
-
-Scroll down to "Allowed Services" on the left side and press ENTER
-
-Press TAB several times until you reach the "Apache2" allowed service on the right side. When you do that,
-press Alt+d to click the "Advanced..." button.
-
-A new window should open. Press Alt+T to go to the "TCP Ports" text box and enter the following values in that box:
-80 8080
-
-Press Alt+O to click the OK button. That will send you back to the "Firewall Configuration:Allowed Services"
-screen. Press Alt+N to click the "Next" button.
-
-You should now be in the "Firewall Configuration: Summary" screen. Press "Alt+F" to Finish.
-
-You should now be again in the "YaST Control Center" screen. Press "Alt+Q" to quit yast.
-
-
-Go again to:
-
-http://192.168.0.2:8080/
-
-... you should get redirected to:
-
-http://192.168.0.2:8080/cgi-bin/koha/installer/install.pl
-
-... and see a page with the Koha Logo and the heading: "Welcome to the Koha Web Installer"! :)
+If not you may have forgotten to open the 8080 port.
You may now login with your koha administrator username and password and reply to the several questions you will be asked.
UPGRADE
=======
+If you are running in another language other than english, please
+switch to english before doing the upgrade, the templating system has
+changed and the templates will need to be regenerated.
+Once you have upgraded, please regenerate your templates in your
+chosen languages.
+
If you are upgrading from a previous installation of Koha 3.x, you can
use the following:
UPGRADE
=======
+If you are running in another language other than english, please
+switch to english before doing the upgrade, the templating system has
+changed and the templates will need to be regenerated.
+Once you have upgraded, please regenerate your templates in your
+chosen languages.
+
If you are upgrading from a previous installation of Koha 3.x, you can
use the following:
to them they will do as instructed. A very basic robots.txt follow as an
example:
+-------------------------------------------
# go away
User-agent: *
Disallow: /
+-------------------------------------------
This tells every search engine that cares (User-agent: *) to not index the site
(Disallow everything past /).
+Another slightly more intelligent robots.txt file example allows for some bot indexing (good for your site in google, etc), but also stops your Koha from getting thrashing by ignoring URLs that cause heavy search load
+
+-------------------------------------------
+# do some indexing, but dont index search URLs
+User-agent: *
+Disallow: /cgi-bin/koha/opac-search.pl
+-------------------------------------------
+
If you have installed Koha to /usr/local/koha3 then this file would be placed
in the directory /usr/local/koha3/opac/htdocs/. This should prevent search
engines from browsing every biblio record, and every view of each record, on
"biblioitems.publishercode" => $$orderinfo{publishercode} ? $$orderinfo{publishercode} : "",
"biblioitems.publicationyear" => $$orderinfo{publicationyear} ? $$orderinfo{publicationyear}: "",
"biblio.copyrightdate" => $$orderinfo{publicationyear} ? $$orderinfo{publicationyear}: "",
+ "biblioitems.itemtype" => $$orderinfo{itemtype} ? $$orderinfo{itemtype} : "",
});
# create the record in catalogue, with framework ''
$op = q{};
}
+my $confirm_pref= C4::Context->preference("BasketConfirmations") || '1';
+$template->param( skip_confirm_reopen => 1) if $confirm_pref eq '2';
+
if ( $op eq 'delete_confirm' ) {
my $basketno = $query->param('basketno');
DelBasket($basketno);
print GetBasketAsCSV($query->param('basketno'));
exit;
} elsif ($op eq 'close') {
- my $confirm = $query->param('confirm');
+ my $confirm = $query->param('confirm') || $confirm_pref eq '2';
if ($confirm) {
my $basketno = $query->param('basketno');
my $booksellerid = $query->param('booksellerid');
if ($basket->{closedate} && haspermission({ flagsrequired => { acquisition => 'group_manage'} })) {
$basketgroups = GetBasketgroups($basket->{booksellerid});
for my $bg ( @{$basketgroups} ) {
- if ($basket->{basketgroupid} == $bg->{id}){
+ if ($basket->{basketgroupid} && $basket->{basketgroupid} == $bg->{id}){
$bg->{default} = 1;
}
}
my $contract = &GetContract($basket->{contractnumber});
my @orders = GetOrders($basketno);
+
+ my $borrower= GetMember('borrowernumber' => $loggedinuser);
+ my $budgets = GetBudgetHierarchy(q{},$borrower->{branchcode},$borrower->{borrowernumber});
+ my $has_budgets = 0;
+ foreach my $r (@{$budgets}) {
+ if (!defined $r->{budget_amount} || $r->{budget_amount} == 0) {
+ next;
+ }
+ $has_budgets = 1;
+ last;
+ }
+
$template->param(
basketno => $basketno,
basketname => $basket->{'basketname'},
basketgroups => $basketgroups,
grouped => $basket->{basketgroupid},
unclosable => @orders ? 0 : 1,
+ has_budgets => $has_budgets,
);
}
# Build the combobox to select the billing place
my @billingplaceloop;
for (sort keys %$branches) {
- my $selected = 1 if $_ eq $billingplace;
- my %row = (
+ push @billingplaceloop, {
value => $_,
- selected => $selected,
+ selected => $_ eq $billingplace,
branchname => $branches->{$_}->{branchname},
- );
- push @billingplaceloop, \%row;
+ };
}
$template->param( billingplaceloop => \@billingplaceloop );
# Build the combobox to select the delivery place
my @deliveryplaceloop;
for (sort keys %$branches) {
- my $selected = 1 if $_ eq $deliveryplace;
- my %row = (
+ push @deliveryplaceloop, {
value => $_,
- selected => $selected,
+ selected => $_ eq $deliveryplace,
branchname => $branches->{$_}->{branchname},
- );
- push @deliveryplaceloop, \%row;
+ };
}
$template->param( deliveryplaceloop => \@deliveryplaceloop );
}
);
-my $from_iso = C4::Dates->new($input->param('from'))->output('iso') if $input->param('from');
-my $to_iso = C4::Dates->new($input->param('to'))->output('iso') if $input->param('iso');
+my ( $from_iso, $to_iso, $d );
+if ( $d = $input->param('from') ) {
+ $from_iso = C4::Dates->new($d)->output('iso');
+}
+if ( $d = $input->param('iso') ) {
+ $to_iso = C4::Dates->new($d)->output('iso');
+}
+
my ( $order_loop, $total_qty, $total_price, $total_qtyreceived ) =
- &GetHistory( $title, $author, $name, $from_iso, $to_iso );
-
+ GetHistory( $title, $author, $name, $from_iso, $to_iso );
+
$template->param(
suggestions_loop => $order_loop,
total_qty => $total_qty,
my $input = new CGI;
my $booksellerid = $input->param('booksellerid'); # FIXME: else ERROR!
-my $budget_id = $input->param('budget_id') || 0; # FIXME: else ERROR!
+my $budget_id = $input->param('budget_id') || 0;
my $title = $input->param('title');
my $author = $input->param('author');
my $publicationyear = $input->param('publicationyear');
my ($marcrecord, $encoding) = MARCfindbreeding($params->{'breedingid'});
die("Could not find the selected record in the reservoir, bailing") unless $marcrecord;
+ # Remove all the items (952) from the imported record
+ foreach my $item ($marcrecord->field('952')) {
+ $marcrecord->delete_field($item);
+ }
+
my $duplicatetitle;
#look for duplicates
($biblionumber,$duplicatetitle) = FindDuplicate($marcrecord);
$template->param(items => \@itemloop);
}
+# Get the item types list, but only if item_level_itype is YES. Otherwise, it will be in the item, no need to display it in the biblio
+my @itemtypes = C4::ItemType->all unless C4::Context->preference('item-level_itypes');
# fill template
$template->param(
budget_loop => $budget_loop,
isbn => $data->{'isbn'},
seriestitle => $data->{'seriestitle'},
+ itemtypeloop => \@itemtypes,
quantity => $data->{'quantity'},
quantityrec => $data->{'quantity'},
rrp => $data->{'rrp'},
);
}
- my $budget_period_total = $num->format_price($$period{budget_period_total}) if $$period{budget_period_total};
+ my $budget_period_total;
+ if ( $period->{budget_period_total} ) {
+ $budget_period_total =
+ $num->format_price( $period->{budget_period_total} );
+ }
$template->param(
else => 1,
budget => \@loop,
if ( $op eq 'add_form' ) {
$template->param( add_form => 1 );
- # if contractnumber exists, it's a modify action, so read values to modify...
- my $contract = @{GetContract( { contractnumber => $contractnumber } )}[0] if $contractnumber;
-
- $template->param(
- contractnumber => $$contract{contractnumber},
- contractname => $$contract{contractname},
- contractdescription => $$contract{contractdescription},
- contractstartdate => format_date( $$contract{contractstartdate} ),
- contractenddate => format_date( $$contract{contractenddate} ),
- DHTMLcalendar_dateformat => C4::Dates->DHTMLcalendar,
- );
+ # if contractnumber exists, it's a modify action, so read values to modify...
+ if ($contractnumber) {
+ my $contract =
+ @{ GetContract( { contractnumber => $contractnumber } ) }[0];
+
+ $template->param(
+ contractnumber => $contract->{contractnumber},
+ contractname => $contract->{contractname},
+ contractdescription => $contract->{contractdescription},
+ contractstartdate => format_date( $contract->{contractstartdate} ),
+ contractenddate => format_date( $contract->{contractenddate} ),
+ DHTMLcalendar_dateformat => C4::Dates->DHTMLcalendar,
+ );
+ } else {
+ $template->param(
+ contractnumber => undef,
+ contractname => undef,
+ contractdescription => undef,
+ contractstartdate => undef,
+ contractenddate => undef,
+ DHTMLcalendar_dateformat => C4::Dates->DHTMLcalendar,
+ );
+ }
# END $OP eq ADD_FORM
}
});
# get authtype list
-my $authtypes = getauthtypes;
-my @authtypesloop;
-foreach my $thisauthtype (keys %$authtypes) {
- my $selected = 1 if $thisauthtype eq $authtypecode;
- my %row =(value => $thisauthtype,
- selected => $selected,
- authtypetext => $authtypes->{$thisauthtype}->{'authtypetext'},
- );
- push @authtypesloop, \%row;
+my $authtypes = getauthtypes;
+my @authtypesloop = ();
+foreach my $thisauthtype ( keys %{$authtypes} ) {
+ push @authtypesloop,
+ { value => $thisauthtype,
+ selected => $thisauthtype eq $authtypecode,
+ authtypetext => $authtypes->{$thisauthtype}->{'authtypetext'},
+ };
}
my $sth;
elsif ( $op eq 'delete_category' ) {
# if the user has pressed the "delete branch" button.
- my $message = "MESSAGE8" if CheckBranchCategorycode($categorycode);
- if ($message) {
+ if ( CheckBranchCategorycode($categorycode) ) {
$template->param( else => 1 );
- default($message,$template);
- }
- else {
+ default( 'MESSAGE8', $template );
+ } else {
$template->param( delete_category => 1 );
$template->param( categorycode => $categorycode );
}
#---- if primkey exists, it's a modify action, so read values to modify...
my $data;
if ($cityid) {
- my $sth=$dbh->prepare("select cityid,city_name,city_zipcode from cities where cityid=?");
+ my $sth=$dbh->prepare("select cityid,city_name,city_state,city_zipcode,city_country from cities where cityid=?");
$sth->execute($cityid);
$data=$sth->fetchrow_hashref;
}
$template->param(
city_name => $data->{'city_name'},
- city_zipcode => $data->{'city_zipcode'});
+ city_state => $data->{'city_state'},
+ city_zipcode => $data->{'city_zipcode'},
+ city_country => $data->{'city_country'});
# END $OP eq ADD_FORM
################## ADD_VALIDATE ##################################
# called by add_form, used to insert/modify data in DB
my $sth;
if ($input->param('cityid') ){
- $sth=$dbh->prepare("UPDATE cities SET city_name=?,city_zipcode=? WHERE cityid=?");
- $sth->execute($input->param('city_name'),$input->param('city_zipcode'),$input->param('cityid'));
+ $sth=$dbh->prepare("UPDATE cities SET city_name=?,city_state=?,city_zipcode=?,city_country=? WHERE cityid=?");
+ $sth->execute($input->param('city_name'),$input->param('city_state'),$input->param('city_zipcode'),$input->param('city_country'),$input->param('cityid'));
}
else{
- $sth=$dbh->prepare("INSERT INTO cities (city_name,city_zipcode) values (?,?)");
- $sth->execute($input->param('city_name'),$input->param('city_zipcode'));
+ $sth=$dbh->prepare("INSERT INTO cities (city_name,city_state,city_zipcode,city_country) values (?,?,?,?)");
+ $sth->execute($input->param('city_name'),$input->param('city_state'),$input->param('city_zipcode'),$input->param('city_country'));
}
print $input->redirect($script_name);
exit;
# called by default form, used to confirm deletion of data in DB
} elsif ($op eq 'delete_confirm') {
$template->param(delete_confirm => 1);
- my $sth=$dbh->prepare("select cityid,city_name,city_zipcode from cities where cityid=?");
+ my $sth=$dbh->prepare("select cityid,city_name,city_state,city_zipcode,city_country from cities where cityid=?");
$sth->execute($cityid);
my $data=$sth->fetchrow_hashref;
$template->param(
city_name => $data->{'city_name'},
+ city_state => $data->{'city_state'},
city_zipcode => $data->{'city_zipcode'},
+ city_country => $data->{'city_country'},
);
################## DELETE_CONFIRMED ##################################
# called by delete_confirm, used to effectively confirm deletion of data in DB
my $branches = GetBranches();
my @branchloop;
for my $thisbranch (sort { $branches->{$a}->{branchname} cmp $branches->{$b}->{branchname} } keys %$branches) {
- my $selected = 1 if $thisbranch eq $branch;
- my %row =(value => $thisbranch,
- selected => $selected,
- branchname => $branches->{$thisbranch}->{'branchname'},
- );
- push @branchloop, \%row;
+ push @branchloop, {
+ value => $thisbranch,
+ selected => $thisbranch eq $branch,
+ branchname => $branches->{$thisbranch}->{'branchname'},
+ };
}
my $sth=$dbh->prepare("SELECT description,categorycode FROM categories ORDER BY description");
$entry->{unlimited_maxissueqty} = 1 unless defined($entry->{maxissueqty});
}
-my @sorted_row_loop = sort by_category_and_itemtype @row_loop;
+@sorted_row_loop = sort by_category_and_itemtype @row_loop;
my $sth_branch_item;
if ($branch eq "*") {
my $marcsubjctsarray = GetMarcSubjects( $record, $marcflavour );
my $marcseriesarray = GetMarcSeries ($record,$marcflavour);
my $marcurlsarray = GetMarcUrls ($record,$marcflavour);
- my @items = &GetItemsInfo( $biblionumber, 'opac' );
+ my @items = GetItemsInfo( $biblionumber );
my $hasauthors = 0;
if($dat->{'author'} || @$marcauthorsarray) {
my $marcauthorsarray = GetMarcAuthors( $record, $marcflavour );
my $marcsubjctsarray = GetMarcSubjects( $record, $marcflavour );
- my @items = &GetItemsInfo( $biblionumber, 'opac' );
+ my @items = GetItemsInfo( $biblionumber );
my $hasauthors = 0;
if($dat->{'author'} || @$marcauthorsarray) {
my $itemtypes = GetItemTypes();
my $dbh = C4::Context->dbh;
-# 'intra' param included, even though it's not respected in GetItemsInfo currently
-my @all_items= GetItemsInfo($biblionumber, 'intra');
+my @all_items = GetItemsInfo( $biblionumber );
my @items;
for my $itm (@all_items) {
push @items, $itm unless ( $itm->{itemlost} && GetHideLostItemsPreference($borrowernumber) && !$showallitems);
my $biblionumber = $query->param('biblionumber');
# change back when ive fixed request.pl
-my @items = GetItemsInfo( $biblionumber, $type );
+my @items = GetItemsInfo( $biblionumber );
my $norequests = 1;
foreach my $itm (@items) {
$norequests = 0 unless $itm->{'notforloan'};
use C4::Output;
use C4::Biblio;
use CGI;
-use C4::Auth;
+
+
my $query = new CGI;
+my ( $template, $loggedinuser, $cookie ) = get_template_and_user({
+ template_name => "tools/export.tt",
+ query => $query,
+ type => "intranet",
+ authnotrequired => 0,
+ flagsrequired => { tools => 'export_catalog' },
+ debug => 1,
+ });
+
my $op=$query->param("op");
my $format=$query->param("format");
if ($op eq "export") {
$template->param(outer_sup_servers_loop => $secondary_servers_loop,);
# set the default sorting
- my $default_sort_by = C4::Context->preference('defaultSortField')."_".C4::Context->preference('defaultSortOrder')
- if (C4::Context->preference('OPACdefaultSortField') && C4::Context->preference('OPACdefaultSortOrder'));
- $template->param($default_sort_by => 1);
+ if ( C4::Context->preference('OPACdefaultSortField')
+ && C4::Context->preference('OPACdefaultSortOrder') ) {
+ my $default_sort_by =
+ C4::Context->preference('defaultSortField') . '_'
+ . C4::Context->preference('defaultSortOrder');
+ $template->param( $default_sort_by => 1 );
+ }
# determine what to display next to the search boxes (ie, boolean option
# shouldn't appear on the first one, scan indexes should, adding a new
# sort by is used to sort the query
# in theory can have more than one but generally there's just one
my @sort_by;
-my $default_sort_by = C4::Context->preference('defaultSortField')."_".C4::Context->preference('defaultSortOrder')
- if (C4::Context->preference('defaultSortField') && C4::Context->preference('defaultSortOrder'));
+my $default_sort_by;
+if ( C4::Context->preference('defaultSortField')
+ && C4::Context->preference('defaultSortOrder') ) {
+ $default_sort_by =
+ C4::Context->preference('defaultSortField') . '_'
+ . C4::Context->preference('defaultSortOrder');
+}
@sort_by = split("\0",$params->{'sort_by'}) if $params->{'sort_by'};
$sort_by[0] = $default_sort_by unless $sort_by[0];
for my $this_cgi ( split('&',$query_cgi) ) {
next unless $this_cgi;
- $this_cgi =~ m/(.?)=(.*)/;
+ $this_cgi =~ m/(.*?)=(.*)/;
my $input_name = $1;
my $input_value = $2;
push @query_inputs, { input_name => $input_name, input_value => $input_value };
# default page number
my $current_page_number = 1;
$current_page_number = ($offset / $results_per_page + 1) if $offset;
- my $previous_page_offset = $offset - $results_per_page unless ($offset - $results_per_page <0);
+ my $previous_page_offset;
+ if ( $offset >= $results_per_page ) {
+ $previous_page_offset = $offset - $results_per_page;
+ }
my $next_page_offset = $offset + $results_per_page;
# If we're within the first 10 pages, keep it simple
#warn "current page:".$current_page_number;
my $this_offset = (($i*$results_per_page)-$results_per_page);
# the page number for this page
my $this_page_number = $i;
- # it should only be highlighted if it's the current page
- my $highlight = 1 if ($this_page_number == $current_page_number);
# put it in the array
- push @page_numbers, { offset => $this_offset, pg => $this_page_number, highlight => $highlight, sort_by => join " ",@sort_by };
+ push @page_numbers,
+ { offset => $this_offset,
+ pg => $this_page_number,
+ # it should only be highlighted if it's the current page
+ highlight => $this_page_number == $current_page_number,
+ sort_by => join ' ', @sort_by
+ };
}
for (my $i=$current_page_number; $i<=($current_page_number + 20 );$i++) {
my $this_offset = ((($i-9)*$results_per_page)-$results_per_page);
my $this_page_number = $i-9;
- my $highlight = 1 if ($this_page_number == $current_page_number);
- if ($this_page_number <= $pages) {
- push @page_numbers, { offset => $this_offset, pg => $this_page_number, highlight => $highlight, sort_by => join " ",@sort_by };
+ if ( $this_page_number <= $pages ) {
+ push @page_numbers,
+ { offset => $this_offset,
+ pg => $this_page_number,
+ highlight => $this_page_number == $current_page_number,
+ sort_by => join ' ', @sort_by
+ };
}
}
}
my @params = $input->param();
$record = TransformHtmlToMarc( \@params , $input );
# check for a duplicate
- my ($duplicatebiblionumber,$duplicatetitle) = FindDuplicate($record) if (!$is_a_modif);
+ my ( $duplicatebiblionumber, $duplicatetitle );
+ if ( !$is_a_modif ) {
+ ( $duplicatebiblionumber, $duplicatetitle ) = FindDuplicate($record);
+ }
my $confirm_not_duplicate = $input->param('confirm_not_duplicate');
# it is not a duplicate (determined either by Koha itself or by user checking it's not a duplicate)
if ( !$duplicatebiblionumber or $confirm_not_duplicate ) {
$year = substr($year, -2);
$query = "SELECT MAX(CAST(SUBSTRING(barcode,-4) AS signed)) AS number FROM items WHERE barcode REGEXP ?";
my $sth = $dbh->prepare($query);
- $sth->execute("^[a-zA-Z]{1,}$year");
+ $sth->execute("^[-a-zA-Z]{1,}$year");
while (my ($count)= $sth->fetchrow_array) {
$nextnum = $count if $count;
$nextnum = 0 if $nextnum == 9999; # this sequence only allows for cataloging 10000 books per month
use C4::Search;
use C4::Output;
+use constant FIXLEN_DATA_ELTS => '|| aca||aabn | a|a d';
+use constant PREF_008 => 'MARCAuthorityControlField008';
+
=head1 DESCRIPTION
plugin_parameters : other parameters added when the plugin is called by the dopop function
$year +=1900; $mon +=1;
my $dateentered = substr($year,2,2).sprintf ("%0.2d", $mon).sprintf ("%0.2d",$mday);
+my $defaultval = Field008();
+
sub plugin_parameters {
my ($dbh,$record,$tagslib,$i,$tabloop) = @_;
return "";
function Focus$function_name(subfield_managed) {
if (!document.getElementById(\"$field_number\").value) {
- document.getElementById(\"$field_number\").value='$dateentered' + '|| aca||aabn | a|a d';
+ var authtype=document.forms['f'].elements['authtypecode'].value;
+ var fieldval='$dateentered$defaultval';
+ if(authtype && (authtype == 'TOPIC_TERM' || authtype == 'GENRE/FORM' || authtype == 'CHRON_TERM')) {
+ fieldval= fieldval.substr(0,14)+'b'+fieldval.substr(15);
+ }
+ document.getElementById(\"$field_number\").value=fieldval;
}
return 1;
}
}
function Clic$function_name(i) {
+ var authtype=document.forms['f'].elements['authtypecode'].value;
defaultvalue=document.getElementById(\"$field_number\").value;
- newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_field_008_authorities.pl&index=$field_number&result=\"+defaultvalue,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
+ newin=window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=marc21_field_008_authorities.pl&index=$field_number&result=\"+defaultvalue+\"&authtypecode=\"+authtype,\"tag_editor\",'width=1000,height=600,toolbar=false,scrollbars=yes');
}
//]]>
my ($input) = @_;
my $index= $input->param('index');
my $result= $input->param('result');
-
+ my $authtype= $input->param('authtypecode')||'';
+ substr($defaultval,14-6,1)='b' if $authtype=~ /TOPIC_TERM|GENRE.FORM|CHRON_TERM/;
my $dbh = C4::Context->dbh;
flagsrequired => {editcatalogue => '*'},
debug => 1,
});
- $result = "$dateentered".'|| aca||aabn | a|a d' unless $result;
+ $result = "$dateentered$defaultval" unless $result;
my $f1 = substr($result,0,6);
my $f6 = substr($result,6,1);
my $f7 = substr($result,7,1);
my $f28 = substr($result,28,1);
my $f29 = substr($result,29,1);
my $f31 = substr($result,31,1);
- my $f32 = substr($result,32,2);
+ my $f32 = substr($result,32,1);
my $f33 = substr($result,33,1);
my $f38 = substr($result,38,1);
my $f39 = substr($result,39,1);
output_html_with_http_headers $input, $cookie, $template->output;
}
+sub Field008 {
+ my $pref= C4::Context->preference(PREF_008);
+ if(!$pref) {
+ return FIXLEN_DATA_ELTS;
+ }
+ elsif(length($pref)<34) {
+ warn "marc21_field_008_authorities.pl: Syspref ".PREF_008." should be 34 characters long ";
+ return FIXLEN_DATA_ELTS;
+ }
+ return substr($pref,0,34); #ignore remainder
+}
+
1;
my $branchcode = C4::Context->userenv->{'branch'};
- $query = "SELECT MAX(CAST(SUBSTRING_INDEX(stocknumber,'_',-1) AS SIGNED)) FROM items WHERE homebranch = ?";
+ $query = "SELECT MAX(CAST(SUBSTRING_INDEX(stocknumber,'_',-1) AS SIGNED))+1 FROM items WHERE homebranch = ? AND stocknumber LIKE ?";
my $sth=$dbh->prepare($query);
- $sth->execute($branchcode);
- while (my ($count)= $sth->fetchrow_array) {
- $nextnum = $count;
- }
- $nextnum++;
+ $sth->execute($branchcode,$branchcode."_%");
+ my ($nextnum) = $sth->fetchrow;
my $nextnum = $branchcode.'_'.$nextnum;
my $scr = <<END_OF_JS;
my $dbh = C4::Context->dbh;
my $len = 0;
- my $sth = $dbh->prepare('SELECT publishercode FROM biblioitems WHERE isbn LIKE ? OR isbn LIKE ? LIMIT 1');
+ my $sth = $dbh->prepare('SELECT publishercode FROM biblioitems WHERE REPLACE(isbn, "-", "") LIKE ? OR isbn LIKE ? LIMIT 1');
$isbn =~ s/-//g;
if (length ($isbn) == 13){
}
defaultvalue = document.getElementById(\"$field_number\").value;
- window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=unimarc_field_225a.pl&index=\"+index+\"&result=\"+defaultvalue+\"&editor_found=\"+editor_found,\"unimarc225a\",'width=500,height=200,toolbar=false,scrollbars=no');
+ window.open(\"../cataloguing/plugin_launcher.pl?plugin_name=unimarc_field_225a.pl&index=\"+index+\"&result=\"+defaultvalue+\"&editor_found=\"+editor_found,\"unimarc225a\",'width=500,height=400,toolbar=false,scrollbars=no');
}
</script>
0 , $borrower->{'enrolmentperiod'});
}
# if the expiry date is before today ie they have expired
- if ( $warning_year*$warning_month*$warning_day==0
+ if ( !$borrower->{'dateexpiry'} || $warning_year*$warning_month*$warning_day==0
|| Date_to_Days($today_year, $today_month, $today_day )
> Date_to_Days($warning_year, $warning_month, $warning_day) )
{
$template->param(
flagged => "1",
noissues => "1",
- expired => format_date($borrower->{dateexpiry}),
+ expired => "1",
renewaldate => format_date("$renew_year-$renew_month-$renew_day")
);
}
$template->param(
waiting_holds => $waiting_holds,
holdsborrowernumber => $borrower->{'borrowernumber'},
+ holdsfirstname => $borrower->{'firstname'},
+ holdssurname => $borrower->{'surname'},
);
}
}
--- /dev/null
+In order to build .deb packages, following debian packages need to be present
+(installed):
+devscripts
+pbuilder
+dh-make
+fakeroot
+
+As root (or sudo) execute:
+pbuilder create
+
+Executing build-git-snapshot without any arguments will leave package and the
+rest in some pbuilder dir, eg. /var/cache/pbuilder/result It is highly
+recommended that --buildresult option is used.
-#!/bin/sh
+#!/usr/bin/perl
+
+# 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.
#
-# This script will build a .deb from a git snapshot of koha.
-# Don't use it for building actual versions for uploading to Debian.
+# 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.
#
-# To use:
-# - commit any changes into git
-# - run this script
+# 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.
+
+# Written by Robin Sheat <robin@catalyst.net.nz> and
+# Srdjan Jankovic <srdjan@catalyst.net.nz>
+# Based on an sh version by Lars Wirzenius.
+
+use strict;
+use warnings;
+
+use Getopt::Long;
+use POSIX qw/strftime/;
+
+my $buildresult;
+my $distribution='squeeze-dev';
+my $git_checks='all';
+my $version='3.5-1~git';
+my $auto_version=1;
+my $need_help;
+my $debug;
+
+GetOptions(
+ 'buildresult|r=s' => \$buildresult,
+ 'distribution|D=s' => \$distribution,
+ 'git-checks|g=s' => \$git_checks,
+ 'version|v=s' => \$version,
+ 'autoversion!' => \$auto_version,
+ 'help|h' => \$need_help,
+ 'debug|d' => \$debug,
+);
+
+help_and_exit() if $need_help;
+
-set -e
+sub sys_command_output {
+ my ($command) = @_;
-die()
-{
- echo "$@"
- exit 1
+ print "$command\n" if $debug;
+ my $command_output;
+ open($command_output, "-|", "$command ")
+ or die qq{Cannot execute "$command": $!"};
+ return map { chomp; $_ } <$command_output>;
}
-everything_is_commited()
-{
- if git status --short | grep -q '^'
- then
- return 1
- else
- return 0
- fi
+sub everything_is_committed {
+ my $filter;
+ for ($git_checks) {
+ $_ eq "none"
+ and return 1;
+
+ $_ eq "modified"
+ and $filter = "no",
+ last;
+
+ $_ eq "all"
+ and $filter = "normal",
+ last;
+
+ help_and_exit("$0: --git-checks/-g must be one of 'all', 'modified', or 'none'");
+ }
+ my $has_changes = grep /^xxx/, sys_command_output("git status --porcelain -u${filter}");
+
+ return !$has_changes;
}
-latest_sha1() {
- git rev-parse --short=8 HEAD
+sub help_and_exit {
+ my $msg = shift;
+ if ($msg) {
+ print "$msg\n\n";
+ }
+ print <<EOH;
+This builds Koha deb packages, from a git snapshot. It's not suitable for
+making upstreamable verions, but handy for your own local packages.
+
+Options:
+ --buildresult, -r
+ the location that the resulting .deb, .changes, etc. will be placed in.
+ Default is whatever pdebuild uses.
+ --distribution, -D
+ the distribution value to set in the changelog when editing it. Default
+ is 'squeeze-dev'.
+ --git-checks, -g
+ what level of git checks are run to determine if the working copy is
+ clean enough. One of 'all' (any changes are bad), 'modified' (only
+ tracked files with untracked changes will cause an error), and 'none'
+ (checking git status is skipped totally.) Default is 'all'.
+ --version, -v
+ the version string for the resulting package. Default is '3.5-1~git'.
+ --(no)autoversion
+ whether or not to use the date and git commit ID in the version value.
+ Default is to include it.
+ --debug, -d
+EOH
+ exit;
}
-newversion() {
- printf '3.5-1~git%s.%s' $(date +%Y%m%d%H%M%S) $(latest_sha1)
+sub latest_sha1 {
+ return sys_command_output("git rev-parse --short=8 HEAD");
}
-adjust_debian_changelog() {
- dch --force-distribution -D squeeze-dev -v "$1" \
- "Building git snapshot."
- dch -r "Building git snapshot."
+sub adjust_debian_changelog {
+ my ($newversion) = @_;
+
+ sys_command_output( qq{dch --force-distribution -D "$distribution" -v "$newversion" "Building git snapshot."} );
+ sys_command_output( qq{dch -r "Building git snapshot."} );
}
-reset_debian_changelog() {
- git checkout -- debian/changelog
+sub reset_debian_changelog {
+ sys_command_output( qq{git checkout -- debian/changelog} );
}
-build_package() {
- git archive --format=tar --prefix="koha-$1/" HEAD |
- gzip -9 > "../koha_$1.tar.gz"
- pdebuild $2
+sub build_package {
+ my ($newversion) = @_;
+ sys_command_output( qq{git archive --format=tar --prefix="koha-$newversion/" HEAD | gzip -9 > "../koha_$newversion.tar.gz"} );
+
+ my $pdebuildopts = $buildresult ? "--buildresult $buildresult" : "";
+ sys_command_output( "pdebuild $pdebuildopts" );
}
-if ! everything_is_commited
-then
- die "cannot build: uncommited changes"
-fi
-
-version="$(newversion)"
-if [ -n "$1" ]
-then
- pdebuildopts="--buildresult $1"
-fi
-adjust_debian_changelog "$version"
-build_package "$version" "$pdebuildopts"
-reset_debian_changelog
+everything_is_committed() or die "cannot build: uncommited changes";
+
+my $newversion = $auto_version
+ ? sprintf ('%s%s.%s', $version, strftime("+%Y%m%d%H%M%S", localtime), latest_sha1())
+ : $version;
+
+adjust_debian_changelog( $newversion );
+build_package( $newversion );
+reset_debian_changelog();
+
#
do_start()
{
+ # We insure all required directories exist, including disabled ones.
+ koha-create-dirs $(koha-list)
koha-start-zebra $(koha-list --enabled)
}
set -e
+usage="Usage: $0 [--create-db|--request-db|--populate-db] \
+ [--marcflavor marc21|normarc|unimarc] \
+ [--zebralang en|nb|fr] \
+ [--defaultsql /path/to/some.sql] \
+ [--configfile /path/to/config] instancename"
die() {
echo "$@" 1>&2
exit 1
}
-
generate_config_file() {
touch "$2"
chown "root:$username" "$2"
-e "s/__OPACSERVER__/$domain/g" \
-e "s/__INTRASERVER__/$intradomain/g" \
-e "s/__ZEBRA_PASS__/$zebrapwd/g" \
+ -e "s/__ZEBRA_MARC_FORMAT__/$ZEBRA_MARC_FORMAT/g" \
+ -e "s/__ZEBRA_LANGUAGE__/$ZEBRA_LANGUAGE/g" \
-e "s/__DB_NAME__/$mysqldb/g" \
-e "s/__DB_HOST__/$mysqlhost/g" \
-e "s/__DB_USER__/$mysqluser/g" \
"/etc/koha/sites/$1/koha-conf.xml"
}
-
# Set defaults and read config file, if it exists.
DOMAIN=""
INTRAPORT="8080"
INTRAPREFIX=""
INTRASUFFIX=""
DEFAULTSQL=""
+ZEBRA_MARC_FORMAT="marc21"
+ZEBRA_LANGUAGE="en"
if [ -e /etc/koha/koha-sites.conf ]
then
. /etc/koha/koha-sites.conf
fi
+[ $# -ge 2 ] && [ $# -le 10 ] || die $usage
+
+TEMP=`getopt -o crpm:l:d:f: -l create-db,request-db,populate-db,marcflavor:,zebralang:,defaultsql:,configfile: \
+ -n "$0" -- "$@"`
+
+# Note the quotes around `$TEMP': they are essential!
+eval set -- "$TEMP"
+
+# Temporary variables for the command line options
+CLO_ZEBRA_MARC_FORMAT=""
+CLO_ZEBRA_LANGUAGE=""
+CLO_DEFAULTSQL=""
+
+while true ; do
+ case "$1" in
+ -c|--create-db) op=create ; shift ;;
+ -r|--request-db) op=request ; shift ;;
+ -p|--populate-db) op=populate ; shift ;;
+ -m|--marcflavor) CLO_ZEBRA_MARC_FORMAT="$2" ; shift 2 ;;
+ -l|--zebralang) CLO_ZEBRA_LANGUAGE="$2" ; shift 2 ;;
+ -d|--defaultsql) CLO_DEFAULTSQL="$2" ; shift 2 ;;
+ -f|--configfile) configfile="$2" ; shift 2 ;;
+ --) shift ; break ;;
+ *) die "Internal error processing command line arguments" ;;
+ esac
+done
+
+# Load the configfile given on the command line
+if [ -e "$configfile" ]
+then
+ . "$configfile"
+else
+ die "$configfile does not exist.";
+fi
+
+# Make sure options from the command line get the highest precedence
+if [ "$CLO_ZEBRA_MARC_FORMAT" != "" ]
+then
+ ZEBRA_MARC_FORMAT="$CLO_ZEBRA_MARC_FORMAT"
+fi
+if [ "$CLO_ZEBRA_LANGUAGE" != "" ]
+then
+ ZEBRA_LANGUAGE="$CLO_ZEBRA_LANGUAGE"
+fi
+if [ "$CLO_DEFAULTSQL" != "" ]
+then
+ DEFAULTSQL="$CLO_DEFAULTSQL"
+fi
-# Parse command line.
-[ "$#" = 2 ] ||
- die "Usage: $0 [--create-db|--request-db|--populate-db] instancename"
-case "$1" in
- --create-db) op=create ;;
- --request-db) op=request ;;
- --populate-db) op=populate ;;
- *) die "Usage: $0 [--create-db|--request-db|--populate-db] instancename" ;;
-esac
+name="$1"
-name="$2"
domain="$name$DOMAIN"
if [ "$INTRAPORT" = 80 ] || [ "$INTRAPORT" = "" ]
then
# $Id: zebra.cfg,v 1.1.2.2 2006/05/09 12:03:16 rangi Exp $
#
# Where are the config files located?
-profilePath:/etc/koha/zebradb/authorities/etc:/etc/koha/zebradb/etc:/etc/koha/zebradb/marc_defs/marc21/authorities:/etc/koha/zebradb/lang_defs/en:/etc/koha/zebradb/xsl
+profilePath:/etc/koha/zebradb/authorities/etc:/etc/koha/zebradb/etc:/etc/koha/zebradb/marc_defs/__ZEBRA_MARC_FORMAT__/authorities:/etc/koha/zebradb/lang_defs/__ZEBRA_LANGUAGE__:/etc/koha/zebradb/xsl
encoding: UTF-8
# modulePath - where to look for loadable zebra modules
# $Id: zebra.cfg,v 1.1.2.2 2006/05/09 12:03:16 rangi Exp $
#
# Where are the config files located?
-profilePath:/etc/koha/zebradb/authorities/etc:/etc/koha/zebradb/etc:/etc/koha/zebradb/marc_defs/marc21/authorities:/etc/koha/zebradb/lang_defs/en
+profilePath:/etc/koha/zebradb/authorities/etc:/etc/koha/zebradb/etc:/etc/koha/zebradb/marc_defs/__ZEBRA_MARC_FORMAT__/authorities:/etc/koha/zebradb/lang_defs/__ZEBRA_LANGUAGE__
encoding: UTF-8
# modulePath - where to look for loadable zebra modules
# $Id: zebra.cfg,v 1.1.2.2 2006/05/09 12:03:16 rangi Exp $
#
# Where are the config files located?
-profilePath:/etc/koha/zebradb/biblios/etc:/etc/koha/zebradb/etc:/etc/koha/zebradb/marc_defs/marc21/biblios:/etc/koha/zebradb/lang_defs/en
+profilePath:/etc/koha/zebradb/biblios/etc:/etc/koha/zebradb/etc:/etc/koha/zebradb/marc_defs/__ZEBRA_MARC_FORMAT__/biblios:/etc/koha/zebradb/lang_defs/__ZEBRA_LANGUAGE__
# modulePath - where to look for loadable zebra modules
modulePath: /usr/lib/idzebra-2.0/modules
May 22 2011 Koha 3.4.1 released releases
June 1 2011 Fridolyn Somers becomes the 143rd developer to have a patch pushed
June 3 2011 Elliott Davis becomes the 144th developer to have a patch pushed
-
+June 15 2011 First ever global sign off day
+June 17 2011 Jeremy Crabtree becomes the 145th developer to have a patch pushed
+July 5 2011 Francois Marier becomes the 146th developer to have a patch pushed
+July 28 2011 John Seymour becomes the 147th developer to have a patch pushed
att 1045 Record-control-number
att 1062 stocknumber
att 1079 Subject-topical
+att 1096 Title-later
# Koha Local-Use Biblio Indexes
melm 100$9 Cross-Reference:w,Koha-Auth-Number
melm 100$a Author,Author:p,Author:s,Editor,Author-personal-bibliography,Author-personal-bibliography:p,Author-personal-bibliography:s
-melm 100 Author,Author-title,Author-name-personal,Name,Name-and-title,Personal-name
+melm 100 Author,Author:p,Author:s,Author-title,Author-name-personal,Name,Name-and-title,Personal-name
melm 110$9 Koha-Auth-Number
-melm 110 Author,Author-title,Author-name-corporate,Name,Name-and-title,Corporate-name
+melm 110 Author,Author:p,Author:s,Author-title,Author-name-corporate,Name,Name-and-title,Corporate-name
melm 111$9 Koha-Auth-Number
-melm 111 Author,Author-title,Author-name-corporate,Name,Name-and-title,Conference-name
+melm 111 Author,Author:p,Author:s,Author-title,Author-name-corporate,Name,Name-and-title,Conference-name
melm 130$n Thematic-number
melm 130$r Music-key
melm 130$9 Koha-Auth-Number
-melm 130 Title,Title-uniform
+melm 130 Title,Title:p,Title-uniform
-melm 210 Title,Title-abbreviated
-melm 211 Title,Title-abbreviated
-melm 212 Title,Title-other-variant
-melm 214 Title,Title-expanded
-melm 222 Title,Title-key
+melm 210 Title,Title:p,Title-abbreviated
+melm 211 Title,Title:p,Title-abbreviated
+melm 212 Title,Title:p,Title-other-variant
+melm 214 Title,Title:p,Title-expanded
+melm 222 Title,Title:p,Title-key
melm 240$r Music-key
melm 240$n Thematic-number
melm 240 Title:w,Title:p,Title-uniform
melm 700$r Music-key
#melm 700$t author,Author-title,Name-and-title,Title,Title-uniform
melm 700$t Author-title,Name-and-title,Title,Title-uniform
-melm 700 Author,Author-name-corporate,Author-name-personal,Name,Editor,Personal-name
+melm 700 Author,Author:p,Author-name-personal,Name,Editor,Personal-name
#melm 710$t author,Author-title,Name-and-title,Title,Title-uniform
melm 710$t Author-title,Name-and-title,Title,Title-uniform
#melm 710$a author,author:p,Name-and-title
melm 710$a Name-and-title
melm 710$9 Koha-Auth-Number
-melm 710 Author,Corporate-name,Name
+melm 710 Author,Author:p,Corporate-name,Name
melm 711$a Name-and-title
#melm 711$t author,Author-title,Title,Title-uniform
melm 711$t Author-title,Title,Title-uniform
melm 711$9 Koha-Auth-Number
#melm 711 author,Author-name-corporate,Name,Conference-name
-melm 711 Author-name-corporate,Name,Conference-name
+melm 711 Author,Author:p,Author-name-corporate,Name,Conference-name
melm 730$n Thematic-number
melm 730$r Music-key
melm 730$9 Koha-Auth-Number
-melm 730 Title,Title-uniform
-melm 740 Title,Title-other-variant
+melm 730 Title,Title:p,Title-uniform
+melm 740 Title,Title:p,Title-other-variant
melm 751$a Name-geographic
melm 751$9 Koha-Auth-Number
melm 751 Name-geographic
melm 777$w Record-control-number
melm 780$t Title
melm 780$w Record-control-number
-melm 780 Title,Title-former,Related-periodical
+melm 780 Title,Title:p,Title-former,Related-periodical
melm 785$w Record-control-number
-melm 785 Related-periodical
+melm 785 Title,Title:p,Title-later,Related-periodical
melm 787$w Record-control-number
melm 800$a Name-and-title
+++ /dev/null
-apt-get install \
-apache2 \
-apache2-mpm-worker \
-at \
-bzip2 \
-daemon \
-gcc \
-gettext \
-idzebra-2.0-common \
-idzebra-2.0-doc \
-idzebra-2.0 \
-idzebra-2.0-utils \
-libalgorithm-checkdigits-perl \
-libbiblio-endnotestyle-perl \
-libbusiness-isbn-perl \
-libcgi-session-perl \
-libcgi-session-serialize-yaml-perl \
-libclass-accessor-perl \
-libclass-factory-util-perl \
-libdata-ical-perl \
-libdate-calc-perl \
-libdate-ical-perl \
-libdate-manip-perl \
-libdatetime-format-mail-perl \
-libdatetime-format-strptime-perl \
-libdatetime-format-w3cdtf-perl \
-libdatetime-locale-perl \
-libdatetime-perl \
-libdatetime-timezone-perl \
-libdbd-mysql-perl \
-libdbd-sqlite2-perl \
-libdbi-perl \
-libdigest-sha-perl \
-libemail-date-perl \
-libgcrypt11-dev \
-libgcrypt11 \
-libgd2-xpm-dev \
-libgd-barcode-perl \
-libgd-gd2-perl \
-libhtml-scrubber-perl \
-libhtml-template-pro-perl \
-libidzebra-2.0-dev \
-libidzebra-2.0 \
-libidzebra-2.0-mod-alvis \
-libidzebra-2.0-mod-grs-marc \
-libidzebra-2.0-mod-grs-regx \
-libidzebra-2.0-mod-grs-xml \
-libidzebra-2.0-mod-text \
-libidzebra-2.0-modules \
-libgraphics-magick-perl \
-libjson-perl \
-libjson-xs-perl \
-liblingua-ispell-perl \
-liblingua-stem-perl \
-liblist-moreutils-perl \
-liblocale-gettext-perl \
-liblocale-po-perl \
-libmail-sendmail-perl \
-libmarc-charset-perl \
-libmarc-crosswalk-dublincore-perl \
-libmarc-record-perl \
-libmarc-xml-perl \
-libmime-lite-perl \
-libmodule-install-perl \
-libmysqlclient15-dev \
-libnet-ldap-perl \
-libnet-z3950-zoom-perl \
-libnet-server-perl \
-libnumber-format-perl \
-libpdf-api2-perl \
-libpdf-reuse-barcode-perl \
-libpdf-reuse-perl \
-libpdf-table-perl \
-libpoe-perl \
-libschedule-at-perl \
-libtemplate-perl \
-libtext-charwidth-perl \
-libtext-csv-perl \
-libtext-iconv-perl \
-libtext-wrapi18n-perl \
-libtimedate-perl \
-libtime-duration-perl \
-libtime-format-perl \
-libunix-syslog-perl \
-libxml2-dev \
-libxml2 \
-libxml2-utils \
-libxml-dom-perl \
-libxml-dumper-perl \
-libxml-libxml-perl \
-libxml-libxslt-perl \
-libxml-namespacesupport-perl \
-libxml-parser-perl \
-libxml-perl \
-libxml-regexp-perl \
-libxml-rss-perl \
-libxml-sax-writer-perl \
-libxml-simple-perl \
-libxml-xslt-perl \
-libxslt1.1 \
-libxslt1-dev \
-libyaml-perl \
-libyaml-syck-perl \
-libyaz-dev \
-libyaz3 \
-make \
-mysql-server \
-yaz-doc \
-yaz
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ReturnLog',1,'If ON, enables the circulation (returns) log',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('reviewson',1,'If ON, enables patron reviews of bibliographic records in the OPAC','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewer',1,'If ON, name of reviewer will be shown above comments in OPAC','','YesNo');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewerPhoto',1,'If ON, photo of reviewer will be shown beside comments in OPAC','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SpecifyDueDate',1,'Define whether to display \"Specify Due Date\" form in Circulation','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionHistory','simplified','Define the display preference for serials issue history in OPAC','simplified|full','Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionLog',1,'If ON, enables subscriptions log',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Number of returned items to show on the check-in page',NULL,'Integer');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines). Requires accruefines cronjob.','off|test|production','Choice');
-INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat','Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat|libsuite8','Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPACViewOthersSuggestions',0,'If ON, allows all suggestions to be displayed in the OPAC',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('AlternateHoldingsField','','The MARC field/subfield that contains alternate holdings information for bibs taht do not have items attached (e.g. 852abchi for libraries converting from MARC Magician).',NULL,'free');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('AlternateHoldingsSeparator','','The string to use to separate subfields in alternate holdings displays.',NULL,'free');
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacHiddenItems' ,'','This syspref allows to define custom rules for hiding specific items at opac. See docs/opac/O pacHiddenItems.txt for more informations.','','Textarea');
-INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('numSearchRSSResults',50,'Specify the maximum number of results to display on a RSS page of results',NULL,'Integer');
\ No newline at end of file
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('numSearchRSSResults',50,'Specify the maximum number of results to display on a RSS page of results',NULL,'Integer');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('OpacRenewalBranch','checkoutbranch','Choose how the branch for an OPAC renewal is recorded in statistics','itemhomebranch|patronhomebranch|checkoutbranch|null','Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('BasketConfirmations', '1', 'When closing or reopening a basket,', 'always ask for confirmation.|do not ask for confirmation.', 'Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('MARCAuthorityControlField008', '|| aca||aabn | a|a d', NULL, NULL, 'Textarea');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpenLibraryCovers',0, 'If ON Openlibrary book covers will be show',NULL,'YesNo');
+
LOCK TABLES `creator_layouts` WRITE;
/*!40000 ALTER TABLE `creator_layouts` DISABLE KEYS */;
-INSERT INTO `creator_layouts` VALUES (17,'CODE39',1,'BIBBAR','Label Test',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, callnumber','<opt></opt>','Labels'),(18,'CODE39',1,'BAR','DEFAULT',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, callnumber','<opt></opt>','Labels'),(19,'CODE39',1,'BAR','DEFAULT',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, callnumber','<opt></opt>','Labels'),(20,'CODE39',1,'BAR','Test Layout',0,'TR',10,'POINT',0,'L','barcode','<opt page_side="F" units="POINT">
+INSERT INTO `creator_layouts` VALUES (17,'CODE39',1,'BIBBAR','Label Test',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, itemcallnumber','<opt></opt>','Labels'),(18,'CODE39',1,'BAR','DEFAULT',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, itemcallnumber','<opt></opt>','Labels'),(19,'CODE39',1,'BAR','DEFAULT',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, itemcallnumber','<opt></opt>','Labels'),(20,'CODE39',1,'BAR','Test Layout',0,'TR',10,'POINT',0,'L','barcode','<opt page_side="F" units="POINT">
<images name="image_1" Dx="72" Ox="0" Oy="0" Sx="0" Sy="0" Tx="4.5" Ty="63">
<data_source image_name="none" image_source="patronimages" />
</images>
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ReturnLog',1,'If ON, enables the circulation (returns) log',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('reviewson',1,'If ON, enables patron reviews of bibliographic records in the OPAC','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewer',1,'If ON, name of reviewer will be shown above comments in OPAC','','YesNo');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewerPhoto',1,'If ON, photo of reviewer will be shown beside comments in OPAC','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SpecifyDueDate',1,'Define whether to display \"Specify Due Date\" form in Circulation','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionHistory','simplified','Define the display preference for serials issue history in OPAC','simplified|full','Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionLog',1,'If ON, enables subscriptions log',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('AlternateHoldingsSeparator','','The string to use to separate subfields in alternate holdings displays.',NULL,'free');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OpacHiddenItems','','This syspref allows to define custom rules for hiding specific items at opac. See docs/opac/OpacHiddenItems.txt for more informations.','','Textarea');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numSearchRSSResults',50,'Specify the maximum number of results to display on a RSS page of results',NULL,'Integer');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('OpacRenewalBranch','checkoutbranch','Choose how the branch for an OPAC renewal is recorded in statistics','itemhomebranch|patronhomebranch|checkoutbranch|null','Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('BasketConfirmations', '1', 'When closing or reopening a basket,', 'always ask for confirmation.|do not ask for confirmation.', 'Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('MARCAuthorityControlField008', '|| aca||aabn | a|a d', NULL, NULL, 'Textarea');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpenLibraryCovers',0,'If ON Openlibrary book covers will be show',NULL,'YesNo');
LOCK TABLES `creator_layouts` WRITE;
/*!40000 ALTER TABLE `creator_layouts` DISABLE KEYS */;
-INSERT INTO `creator_layouts` VALUES (17,'CODE39',1,'BIBBAR','Label Test',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, callnumber','<opt></opt>','Labels'),(18,'CODE39',1,'BAR','DEFAULT',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, callnumber','<opt></opt>','Labels'),(19,'CODE39',1,'BAR','DEFAULT',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, callnumber','<opt></opt>','Labels'),(20,'CODE39',1,'BAR','Test Layout',0,'TR',10,'POINT',0,'L','barcode','<opt page_side="F" units="POINT">
+INSERT INTO `creator_layouts` VALUES (17,'CODE39',1,'BIBBAR','Label Test',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, itemcallnumber','<opt></opt>','Labels'),(18,'CODE39',1,'BAR','DEFAULT',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, itemcallnumber','<opt></opt>','Labels'),(19,'CODE39',1,'BAR','DEFAULT',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, itemcallnumber','<opt></opt>','Labels'),(20,'CODE39',1,'BAR','Test Layout',0,'TR',10,'POINT',0,'L','barcode','<opt page_side="F" units="POINT">
<images name="image_1" Dx="72" Ox="0" Oy="0" Sx="0" Sy="0" Tx="4.5" Ty="63">
<data_source image_name="none" image_source="patronimages" />
</images>
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ReturnLog', '0', 'Activer ce paramètre pour enregistrer les actions sur la circulation (les retours)', '', 'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('reviewson', '1', 'Active ou non les commentaires sur notice à l''OPAC', '', 'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewer',1,'If ON, name of reviewer will be shown above comments in OPAC','','YesNo');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewerPhoto',1,'If ON, photo of reviewer will be shown beside comments in OPAC','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SessionStorage', 'mysql', 'Utiliser mySQL ou un fichier temporaire pour stocker les informations de session. mySQL pose problème dans certains cas en France. Si vous avez des problèmes de perte d''identifiant, choisissez tmp', 'mysql|tmp', 'Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionHistory', 'simplified', 'Ce paramètre définit la vue par défaut de l''état de collection, pour les abonnements. Habituellement, c''est "simplified". Choisissez "full" pour avoir l''état de collection complet par défaut', 'simplified|full', 'Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionLog', '0', 'Activer ce paramètre pour enregistrer les actions sur le bulletinage', '', 'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'Si activé, envoie un mail à la bibliothèque lorsqu''une réservation est posée',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Nombre d''exemplaires rendus à afficher sur la page de retour',NULL,'Integer');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choisissez un mode pour le calcul des amendes : Test ou Production.','test|production','Choice');
-INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','Si activé, permet de définir le format des codes à barre','whitespace|T-prefix|cuecat','Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','Si activé, permet de définir le format des codes à barre','whitespace|T-prefix|cuecat|libsuite8','Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Activer s''il n''y a qu''une seule bibliothèque sur ce catalogue, cela cache le sélecteur de bibliothèque inutile',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Texte à afficher dans l''ancre du logo de l''OPAC',NULL,'free');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPACViewOthersSuggestions',0,'Si activé, toutes les suggestions sont affichées à l''OPAC',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('AlternateHoldingsField','','The MARC field/subfield that contains alternate holdings information for bibs taht do not have items attached (e.g. 852abchi for libraries converting from MARC Magician).',NULL,'free');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('AlternateHoldingsSeparator','','The string to use to separate subfields in alternate holdings displays.',NULL,'free');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OpacHiddenItems','','This syspref allows to define custom rules for hiding specific items at opac. See docs/opac/OpacHiddenItems.txt for more informations.','','Textarea');
-INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('numSearchRSSResults',50,'Specify the maximum number of results to display on a RSS page of results',NULL,'Integer');
\ No newline at end of file
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('numSearchRSSResults',50,'Specify the maximum number of results to display on a RSS page of results',NULL,'Integer');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('OpacRenewalBranch','checkoutbranch','Choose how the branch for an OPAC renewal is recorded in statistics','itemhomebranch|patronhomebranch|checkoutbranch|null','Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('BasketConfirmations', '1', 'When closing or reopening a basket,', 'always ask for confirmation.|do not ask for confirmation.', 'Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('MARCAuthorityControlField008', '|| aca||aabn | a|a d', NULL, NULL, 'Textarea');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpenLibraryCovers',0,'If ON Openlibrary book covers will be show',NULL,'YesNo');
+
insert into `message_attributes`
(`message_attribute_id`, message_name, `takes_days`)
values
-(1, 'Item DUE', 0),
-(2, 'Advance Notice', 1),
-(4, 'Hold Filled', 0),
-(5, 'Item Check-in', 0),
-(6, 'Item Checkout', 0);
-
+(1, 'Item_Due', 0),
+(2, 'Advance_Notice', 1),
+(4, 'Hold_Filled', 0),
+(5, 'Item_Check_in', 0),
+(6, 'Item_Checkout', 0);
SET FOREIGN_KEY_CHECKS=1;
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('IssueLog','0','','Se ON, logga le attività di prestito.','YesNo');
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('IssuingInProcess','0','','Se ON, disattiva le multe se l’utente prendendo un prestito farebbe dei debiti con la biblioteca.','YesNo');
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('item-level_itypes','1','','Se ON, abilita la gestione della circolazione a livello di copia, usado le tipologie di copia (Itemtype) e le regole di prestito (Issuing Rules)','YesNo');
-insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('itemBarcodeInputFilter','whitespace','whitespace|T-prefix|cuecat','Se configurata, permette di definire un filtro su quanto legge il lettore di barcode','Choice');
+insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('itemBarcodeInputFilter','whitespace','whitespace|T-prefix|cuecat|libsuite8','Se configurata, permette di definire un filtro su quanto legge il lettore di barcode','Choice');
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('itemcallnumber','676a','','Il campo/sottocampo MARC usato per calcolare la stringa di collocazione (per la Dewey sarebbe 082ab o 092ab; LOC 050ab o 090ab) potrebbe essere 852hi da un record MARC21 Holding.','free');
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('KohaAdminEmailAddress','koha@cilea.it','','Definisce l’indirizzo email dove vengono spedite le richieste di modifica utente. ','free');
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('LabelMARCView','standard','standard|economical','Per definire la modalità di visualizzazione di un record MARC','Choice');
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('ReturnLog','1','','Se su ON, abilita i log delle restituzioni dal prestito.','YesNo');
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('reviewson','1','','Se ON, abilita la possibilità per gli utenti a inserire recensioni di record bibliografici nell\'OPAC.','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewer',1,'If ON, name of reviewer will be shown above comments in OPAC','','YesNo');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewerPhoto',1,'If ON, photo of reviewer will be shown beside comments in OPAC','','YesNo');
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('RoutingSerials','1','','Se ON, il serial routing è attivato.','YesNo');
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('SearchMyLibraryFirst','0','','Se ON, le ricerche in OPAC restituiranno risultati limitatamente alla biblioteca impostata di default dell’utente se questi si è loggato.','YesNo');
insert into `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) values('SessionStorage','mysql','mysql|Pg|tmp','Per usare un database o un file temporaneo per l\'archiviazione dei dati della sessione.','Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('AlternateHoldingsSeparator','','The string to use to separate subfields in alternate holdings displays.',NULL,'free');
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacHiddenItems','','This syspref allows to define custom rules for hiding specific items at opac. See docs/opac/O pacHiddenItems.txt for more informations.','','Textarea');
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('numSearchRSSResults',50,'Specify the maximum number of results to display on a RSS page of results',NULL,'Integer');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('OpacRenewalBranch','checkoutbranch','Choose how the branch for an OPAC renewal is recorded in statistics','itemhomebranch|patronhomebranch|checkoutbranch|null','Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('BasketConfirmations', '1', 'When closing or reopening a basket,', 'always ask for confirmation.|do not ask for confirmation.', 'Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('MARCAuthorityControlField008', '|| aca||aabn | a|a d', NULL, NULL, 'Textarea');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpenLibraryCovers',0,'If ON Openlibrary book covers will be show',NULL,'YesNo');
+
CREATE TABLE `cities` (
`cityid` int(11) NOT NULL auto_increment,
`city_name` varchar(100) NOT NULL default '',
+ `city_state` VARCHAR( 100 ) NULL DEFAULT NULL,
+ `city_country` VARCHAR( 100 ) NULL DEFAULT NULL,
`city_zipcode` varchar(20) default NULL,
PRIMARY KEY (`cityid`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ReturnBeforeExpiry',0,'If ON, checkout will be prevented if returndate is after patron card expiry',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ReturnLog',1,'If ON, enables the circulation (returns) log',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('reviewson',1,'If ON, enables patron reviews of bibliographic records in the OPAC','','YesNo');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewerPhoto',1,'If ON, photo of reviewer will be shown beside comments in OPAC','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SpecifyDueDate',1,'Define whether to display \"Specify Due Date\" form in Circulation','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionHistory','simplified','Define the display preference for serials issue history in OPAC','simplified|full','Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionLog',1,'If ON, enables subscriptions log',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OpacFavicon','','Enter a complete URL to an image to replace the default Koha favicon on the OPAC','','free');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('IntranetFavicon','','Enter a complete URL to an image to replace the default Koha favicon on the Staff client','','free');
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('TraceSubjectSubdivisions', '0', 'Create searches on all subdivisions for subject tracings.','1','YesNo');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('BasketConfirmations', '1', 'When closing or reopening a basket,', 'always ask for confirmation.|do not ask for confirmation.', 'Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('MARCAuthorityControlField008', '|| aca||aabn | a|a d', NULL, NULL, 'Textarea');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpenLibraryCovers',0,'If ON Openlibrary book covers will be show',NULL,'YesNo');
LOCK TABLES `creator_layouts` WRITE;
/*!40000 ALTER TABLE `creator_layouts` DISABLE KEYS */;
-INSERT INTO `creator_layouts` VALUES (17,'CODE39',1,'BIBBAR','Label Test',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, callnumber','<opt></opt>','Labels'),(18,'CODE39',1,'BAR','DEFAULT',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, callnumber','<opt></opt>','Labels'),(19,'CODE39',1,'BAR','DEFAULT',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, callnumber','<opt></opt>','Labels'),(20,'CODE39',1,'BAR','Test Layout',0,'TR',10,'POINT',0,'L','barcode','<opt page_side="F" units="POINT">
+INSERT INTO `creator_layouts` VALUES (17,'CODE39',1,'BIBBAR','Label Test',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, itemcallnumber','<opt></opt>','Labels'),(18,'CODE39',1,'BAR','DEFAULT',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, itemcallnumber','<opt></opt>','Labels'),(19,'CODE39',1,'BAR','DEFAULT',0,'TR',3,'POINT',0,'L','title, author, isbn, issn, itemtype, barcode, itemcallnumber','<opt></opt>','Labels'),(20,'CODE39',1,'BAR','Test Layout',0,'TR',10,'POINT',0,'L','barcode','<opt page_side="F" units="POINT">
<images name="image_1" Dx="72" Ox="0" Oy="0" Sx="0" Sy="0" Tx="4.5" Ty="63">
<data_source image_name="none" image_source="patronimages" />
</images>
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ReturnLog',1,'If ON, enables the circulation (returns) log',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('reviewson',1,'If ON, enables patron reviews of bibliographic records in the OPAC','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewer',1,'If ON, name of reviewer will be shown above comments in OPAC','','YesNo');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewerPhoto',1,'If ON, photo of reviewer will be shown beside comments in OPAC','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SpecifyDueDate',1,'Define whether to display \"Specify Due Date\" form in Circulation','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionHistory','simplified','Define the display preference for serials issue history in OPAC','simplified|full','Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionLog',1,'If ON, enables subscriptions log',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('numReturnedItemsToShow','20','Number of returned items to show on the check-in page',NULL,'Integer');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines). Requires accruefines cronjob.','off|test|production','Choice');
-INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat','Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat|libsuite8','Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPACViewOthersSuggestions',0,'If ON, allows all suggestions to be displayed in the OPAC',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('AlternateHoldingsField','','The MARC field/subfield that contains alternate holdings information for bibs taht do not have items attached (e.g. 852abchi for libraries converting from MARC Magician).',NULL,'free');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('AlternateHoldingsSeparator','','The string to use to separate subfields in alternate holdings displays.',NULL,'free');
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacHiddenItems','','This syspref allows to define custom rules for hiding specific items at opac. See docs/opac/OpacHiddenItems.txt for more informations.','','Textarea');
-INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('numSearchRSSResults',50,'Specify the maximum number of results to display on a RSS page of results',NULL,'Integer');
\ No newline at end of file
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('numSearchRSSResults',50,'Specify the maximum number of results to display on a RSS page of results',NULL,'Integer');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('OpacRenewalBranch','checkoutbranch','Choose how the branch for an OPAC renewal is recorded in statistics','itemhomebranch|patronhomebranch|checkoutbranch|null','Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('BasketConfirmations', '1', 'When closing or reopening a basket,', 'always ask for confirmation.|do not ask for confirmation.', 'Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('MARCAuthorityControlField008', '|| aca||aabn | a|a d', NULL, NULL, 'Textarea');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpenLibraryCovers',0, 'If ON Openlibrary book covers will be show',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ReturnLog',1,'If ON, enables the circulation (returns) log',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('reviewson',1,'If ON, enables patron reviews of bibliographic records in the OPAC','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewer',1,'If ON, name of reviewer will be shown above comments in OPAC','','YesNo');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewerPhoto',1,'If ON, photo of reviewer will be shown beside comments in OPAC','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SpecifyDueDate',1,'Define whether to display \"Specify Due Date\" form in Circulation','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionHistory','simplified','Define the display preference for serials issue history in OPAC','simplified|full','Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionLog',1,'If ON, enables subscriptions log',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('noItemTypeImages',0,'If ON, disables item-type images',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines). Requires accruefines cronjob.','off|test|production','Choice');
-INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat','Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat|libsuite8','Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPACViewOthersSuggestions',0,'If ON, allows all suggestions to be displayed in the OPAC',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('OverduesBlockCirc','noblock','When checking out an item should overdues block checkout, generate a confirmation dialogue, or allow checkout','noblock|confirmation|block','Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('DisplayMultiPlaceHold','1','Display the ability to place multiple holds or not','','YesNo');
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('IntranetUserCSS','','Add CSS to be included in the intranet in an embedded <style> tag.',NULL,'free');
-INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OPACNoResultsFound','','Display this HTML when no results are found for a search in the OPAC','70|10','Textare a');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OPACNoResultsFound','','Display this HTML when no results are found for a search in the OPAC','70|10','Textarea');
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacPublic',1,'Turn on/off public OPAC',NULL,'YesNo');
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('ShelfBrowserUsesLocation','1','Use the item location when finding items for the shelf browser.','1','YesNo');
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('ShelfBrowserUsesHomeBranch','1','Use the item home branch when finding items for the shelf browser.','1','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('AlternateHoldingsField','','The MARC field/subfield that contains alternate holdings information for bibs taht do not have items attached (e.g. 852abchi for libraries converting from MARC Magician).',NULL,'free');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('AlternateHoldingsSeparator','','The string to use to separate subfields in alternate holdings displays.',NULL,'free');
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacHiddenItems','','This syspref allows to define custom rules for hiding specific items at opac. See docs/opac/OpacHiddenItems.txt for more informations.','','Textarea');
-INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('numSearchRSSResults',50,'Specify the maximum number of results to display on a RSS page of results',NULL,'Integer');
\ No newline at end of file
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('numSearchRSSResults',50,'Specify the maximum number of results to display on a RSS page of results',NULL,'Integer');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('OpacRenewalBranch','checkoutbranch','Choose how the branch for an OPAC renewal is recorded in statistics','itemhomebranch|patronhomebranch|checkoutbranch|null','Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('BasketConfirmations', '1', 'When closing or reopening a basket,', 'always ask for confirmation.|do not ask for confirmation.', 'Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('MARCAuthorityControlField008', '|| aca||aabn | a|a d', NULL, NULL, 'Textarea');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpenLibraryCovers',0,'If ON Openlibrary book covers will be show',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ReturnLog',1,'If ON, enables the circulation (returns) log',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('reviewson',1,'If ON, enables patron reviews of bibliographic records in the OPAC','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewer',1,'If ON, name of reviewer will be shown above comments in OPAC','','YesNo');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewerPhoto',1,'If ON, photo of reviewer will be shown beside comments in OPAC','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SpecifyDueDate',1,'Define whether to display \"Specify Due Date\" form in Circulation','','YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionHistory','simplified','Define the display preference for serials issue history in OPAC','simplified|full','Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SubscriptionLog',1,'If ON, enables subscriptions log',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('noItemTypeImages',0,'If ON, disables item-type images',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('emailLibrarianWhenHoldIsPlaced',0,'If ON, emails the librarian whenever a hold is placed',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('finesMode','test','Choose the fines mode, \'off\', \'test\' (emails admin report) or \'production\' (accrue overdue fines). Requires accruefines cronjob.','off|test|production','Choice');
-INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat','Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('itemBarcodeInputFilter','','If set, allows specification of a item barcode input filter','whitespace|T-prefix|cuecat|libsuite8','Choice');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('singleBranchMode',0,'Operate in Single-branch mode, hide branch selection in the OPAC',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('URLLinkText','','Text to display as the link anchor in the OPAC',NULL,'free');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OPACViewOthersSuggestions',0,'If ON, allows all suggestions to be displayed in the OPAC',NULL,'YesNo');
INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('AlternateHoldingsSeparator','','The string to use to separate subfields in alternate holdings displays.',NULL,'free');
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacHiddenItems','','This syspref allows to define custom rules for hiding specific items at opac. See docs/opac/O pacHiddenItems.txt for more informations.','','Textarea');
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('numSearchRSSResults',50,'Specify the maximum number of results to display on a RSS page of results',NULL,'Integer');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('OpacRenewalBranch','checkoutbranch','Choose how the branch for an OPAC renewal is recorded in statistics','itemhomebranch|patronhomebranch|checkoutbranch|null','Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('BasketConfirmations', '1', 'When closing or reopening a basket,', 'always ask for confirmation.|do not ask for confirmation.', 'Choice');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('MARCAuthorityControlField008', '|| aca||aabn | a|a d', NULL, NULL, 'Textarea');
+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpenLibraryCovers',0, 'If ON Openlibrary book covers will be show',NULL,'YesNo');
+
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
$dbh->do("INSERT INTO systempreferences (variable,value,options,explanation,type)VALUES('HidePatronName', '0', '', 'If this is switched on, patron''s cardnumber will be shown instead of their name on the holds and catalog screens', 'YesNo')");
SetVersion ($DBversion);
- print "Upgrade to $DBversion done (added a preference to hide the patrons name in the staff catalog)";
+ print "Upgrade to $DBversion done (added a preference to hide the patrons name in the staff catalog)\n";
}
$DBversion = "3.01.00.046";
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
");
- SetVersion ($DBversion);
+ SetVersion ($DBversion);print "Upgrade to $DBversion done (Created table fieldmapping)\n";print "Upgrade to 3.01.00.064 done (Version number skipped: nothing done)\n";
}
$DBversion = '3.01.00.065';
$DBversion = "3.01.00.068";
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
$dbh->do("ALTER TABLE issuingrules ADD COLUMN `finedays` int(11) default NULL AFTER `fine` ");
- print "Upgrade done (Adding finedays in issuingrules table)\n";
+ print "Upgrade to $DBversion done (Adding finedays in issuingrules table)\n";
SetVersion ($DBversion);
}
SEARCHHIST
$dbh->do($create);
- print "Upgrade done (added OPAC search history preference and table)\n";
+ print "Upgrade to $DBversion done (added OPAC search history preference and table)\n";
}
$DBversion = "3.01.00.070";
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
$dbh->do("ALTER TABLE authorised_values ADD COLUMN `lib_opac` VARCHAR(80) default NULL AFTER `lib`");
- print "Upgrade done (Added a lib_opac field in authorised_values table)\n";
+ print "Upgrade to $DBversion done (Added a lib_opac field in authorised_values table)\n";
}
$DBversion = "3.01.00.071";
ADD itemtype VARCHAR(30) default NULL
;
SUGGESTIONS
- print "Upgrade to $DBversion done Suggestions";
+ print "Upgrade to $DBversion done (Suggestions)\n";
SetVersion ($DBversion);
}
$DBversion = "3.01.00.087";
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
$dbh->do("ALTER table aqbudgets drop column budget_amount_sublevel;");
- print "Upgrade to $DBversion done drop column budget_amount_sublevel from aqbudgets\n";
+ print "Upgrade to $DBversion done (Drop column budget_amount_sublevel from aqbudgets)\n";
SetVersion ($DBversion);
}
$DBversion = "3.01.00.100";
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
$dbh->do("INSERT INTO `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) VALUES ('casAuthentication', '0', '', 'Enable or disable CAS authentication', 'YesNo'), ('casLogout', '1', '', 'Does a logout from Koha should also log out of CAS ?', 'YesNo'), ('casServerUrl', 'https://localhost:8443/cas', '', 'URL of the cas server', 'Free')");
- print "Upgrade done (added CAS authentication system preferences)\n";
+ print "Upgrade to $DBversion done (added CAS authentication system preferences)\n";
SetVersion ($DBversion);
}
$dbh->do(
"UPDATE permissions set description = 'Edit catalog (Modify bibliographic/holdings data)' where module_bit = 9 and code = 'edit_catalogue'"
);
- print "Upgrade done (fixed spelling error in edit_catalogue permission)\n";
+ print "Upgrade to $DBversion done (fixed spelling error in edit_catalogue permission)\n";
SetVersion ($DBversion);
}
$DBversion = "3.01.00.103";
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
$dbh->do("INSERT INTO permissions (module_bit, code, description) VALUES (13, 'moderate_tags', 'Moderate patron tags')");
- print "Upgrade done (adding patron permissions for tags tool)\n";
+ print "Upgrade to $DBversion done (adding patron permissions for tags tool)\n";
SetVersion ($DBversion);
}
$DBversion = "3.01.00.106";
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
$dbh->do("INSERT INTO `systempreferences` (variable,value,options,explanation,type) VALUES ( 'OpacAddMastheadLibraryPulldown', '0', '', 'Adds a pulldown menu to select the library to search on the opac masthead.', 'YesNo' )");
- print "Upgrade done (added OpacAddMastheadLibraryPulldown system preferences)\n";
+ print "Upgrade to $DBversion done (added OpacAddMastheadLibraryPulldown system preferences)\n";
SetVersion ($DBversion);
}
ADD `field_separator` VARCHAR( 2 ) NOT NULL AFTER `csv_separator` ,
ADD `subfield_separator` VARCHAR( 2 ) NOT NULL AFTER `field_separator`
});
- print "Upgrade done (added separators for csv export)\n";
+ print "Upgrade to $DBversion done (added separators for csv export)\n";
SetVersion ($DBversion);
}
$dbh->do(qq{
ALTER TABLE `export_format` ADD `encoding` VARCHAR(255) NOT NULL AFTER `subfield_separator`
});
- print "Upgrade done (added encoding for csv export)\n";
+ print "Upgrade to $DBversion done (added encoding for csv export)\n";
SetVersion ($DBversion);
}
$DBversion = '3.01.00.110';
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
$dbh->do('ALTER TABLE `categories` ADD COLUMN `enrolmentperioddate` DATE NULL DEFAULT NULL AFTER `enrolmentperiod`');
- print "Upgrade done (Add enrolment period date support)\n";
+ print "Upgrade to $DBversion done (Add enrolment period date support)\n";
SetVersion ($DBversion);
}
$DBversion = '3.01.00.111';
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
- print "Upgrade done (mark DBrev for 3.2-alpha release)\n";
+ print "Upgrade to $DBversion done (mark DBrev for 3.2-alpha release)\n";
SetVersion ($DBversion);
}
$DBversion = '3.01.00.112';
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
$dbh->do("INSERT INTO `systempreferences` (variable,value,options,explanation,type) VALUES ('SpineLabelShowPrintOnBibDetails', '0', '', 'If turned on, a \"Print Label\" link will appear for each item on the bib details page in the staff interface.', 'YesNo');");
- print "Upgrade done ( added Show Spine Label Printer on Bib Items Details preferences )\n";
+ print "Upgrade to $DBversion done ( added Show Spine Label Printer on Bib Items Details preferences )\n";
SetVersion ($DBversion);
}
$dbh->do(
"INSERT INTO systempreferences (variable,value,type)
VALUES('OPACXSLTDetailsDisplay',?,'YesNo')", {}, $value ? 1 : 0);
- print "Upgrade done (added two new syspref: OPACXSLTResultsDisplay and OPACXSLTDetailDisplay). You may have to go in Admin > System preference to tweak XSLT related syspref both in OPAC and Search tabs.\n ";
+ print "Upgrade to $DBversion done (added two new syspref: OPACXSLTResultsDisplay and OPACXSLTDetailDisplay). You may have to go in Admin > System preference to tweak XSLT related syspref both in OPAC and Search tabs.\n";
SetVersion ($DBversion);
}
if (C4::Context->preference('OrderPdfFormat') eq 'pdfformat::example'){
$dbh->do("UPDATE `systempreferences` set value='pdfformat::layout2pages' WHERE variable='OrderPdfFormat'");
}
- print "Upgrade done ( corrected default OrderPdfFormat value if still set wrong )\n";
+ print "Upgrade to $DBversion done (corrected default OrderPdfFormat value if still set wrong )\n";
SetVersion ($DBversion);
}
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
$dbh->do("UPDATE `permissions` SET `code` = 'items_batchdel' WHERE `permissions`.`module_bit` =13 AND `permissions`.`code` = 'batchdel' LIMIT 1 ;");
$dbh->do("UPDATE `permissions` SET `code` = 'items_batchmod' WHERE `permissions`.`module_bit` =13 AND `permissions`.`code` = 'batchmod' LIMIT 1 ;");
- print "Upgrade done (Change permissions names for item batch modification / deletion)\n";
+ print "Upgrade to $DBversion done (Change permissions names for item batch modification / deletion)\n";
SetVersion ($DBversion);
}
$DBversion = "3.01.00.130";
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
$dbh->do("UPDATE reserves SET expirationdate = NULL WHERE expirationdate = '0000-00-00'");
- print "Upgrade done (change reserves.expirationdate values of 0000-00-00 to NULL (bug 1532)";
+ print "Upgrade to $DBversion done (change reserves.expirationdate values of 0000-00-00 to NULL (bug 1532)\n";
SetVersion ($DBversion);
}
$DBversion = '3.01.00.134';
if (C4::Context->preference('Version') < TransformToNum($DBversion)){
$dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('DisplayMultiPlaceHold','1','Display the ability to place multiple holds or not','','YesNo')");
- print "Upgrade to $DBversion done adding syspref DisplayMultiPlaceHold to control whether multiple holds can be placed from the search results page";
+ print "Upgrade to $DBversion done (adding syspref DisplayMultiPlaceHold to control whether multiple holds can be placed from the search results page)\n";
SetVersion ($DBversion);
}
INSERT INTO `letter` (module, code, name, title, content) VALUES
('reserves', 'HOLD_PRINT', 'Hold Available for Pickup (print notice)', 'Hold Available for Pickup (print notice)', '<<branches.branchname>>\r\n<<branches.branchaddress1>>\r\n<<branches.branchaddress2>>\r\n\r\n\r\nChange Service Requested\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n<<borrowers.firstname>> <<borrowers.surname>>\r\n<<borrowers.address>>\r\n<<borrowers.city>> <<borrowers.zipcode>>\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n<<borrowers.firstname>> <<borrowers.surname>> <<borrowers.cardnumber>>\r\n\r\nYou have a hold available for pickup as of <<reserves.waitingdate>>:\r\n\r\nTitle: <<biblio.title>>\r\nAuthor: <<biblio.author>>\r\nCopy: <<items.copynumber>>\r\n')
");
- print "Upgrade to $DBversion done (bug 4377: added HOLD_PRINT message template)";
+ print "Upgrade to $DBversion done (bug 4377: added HOLD_PRINT message template)\n";
SetVersion ($DBversion);
}
$dbh->do(qq{
INSERT INTO permissions (module_bit, code, description) VALUES
( 9, 'edit_items', 'Edit Items');});
- print "Upgrade to $DBversion done Adding a new permission to edit items";
+ print "Upgrade to $DBversion done (Adding a new permission to edit items)\n";
SetVersion ($DBversion);
}
(15, 'renew_subscription', 'Renew a subscription'),
(15, 'routing', 'Routing');
");
- print "Upgrade to $DBversion done (adding granular permissions for serials)";
+ print "Upgrade to $DBversion done (adding granular permissions for serials)\n";
SetVersion ($DBversion);
}
$DBversion = "3.01.00.138";
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
$dbh->do("DELETE FROM systempreferences WHERE variable = 'GranularPermissions'");
- print "Upgrade to $DBversion done (bug 4896: removing GranularPermissions syspref; use of granular permissions is now the default)";
+ print "Upgrade to $DBversion done (bug 4896: removing GranularPermissions syspref; use of granular permissions is now the default)\n";
SetVersion ($DBversion);
}
if (C4::Context->preference('Version') < TransformToNum($DBversion)){
$dbh->do(qq{DELETE FROM message_attributes WHERE message_attribute_id=3;});
$dbh->do(qq{DELETE FROM letter WHERE code='EVENT' AND title='Upcoming Library Event';});
- print "Upgrade to $DBversion done Remove upcoming events messaging option (bug 2434)";
+ print "Upgrade to $DBversion done Remove upcoming events messaging option (bug 2434)\n";
SetVersion ($DBversion);
}
$DBversion = '3.01.00.142';
if (C4::Context->preference('Version') < TransformToNum($DBversion)){
$dbh->do(qq{DELETE FROM message_transports WHERE message_attribute_id=3;});
- print "Upgrade to $DBversion done Remove upcoming events messaging option part 2 (bug 2434)";
+ print "Upgrade to $DBversion done (Remove upcoming events messaging option part 2 (bug 2434))\n";
SetVersion ($DBversion);
}
if (C4::Context->preference('Version') < TransformToNum($DBversion)){
$dbh->do(qq{CREATE INDEX auth_value_idx ON authorised_values (authorised_value)});
$dbh->do(qq{CREATE INDEX auth_val_cat_idx ON borrower_attribute_types (authorised_value_category)});
- print "Create index on authorised_values and borrower_attribute_types (bug 4139)";
+ print "Upgrade to $DBversion done (Create index on authorised_values and borrower_attribute_types (bug 4139))\n";
SetVersion ($DBversion);
}
$DBversion = '3.01.00.144';
if (C4::Context->preference('Version') < TransformToNum($DBversion)){
$dbh->do(qq{UPDATE systempreferences SET value='normal' where value='default' and variable='IntranetBiblioDefaultView'});
- print "Update the 'default' to 'normal' for the IntranetBiblioDefaultView syspref (bug 5007)";
+ print "Upgrade to $DBversion done (Update the 'default' to 'normal' for the IntranetBiblioDefaultView syspref (bug 5007))\n";
SetVersion ($DBversion);
}
$DBversion = '3.03.00.008';
if (C4::Context->preference('Version') < TransformToNum($DBversion)){
$dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('OPACNoResultsFound','','Display this HTML when no results are found for a search in the OPAC','70|10','Textarea')");
- print "Upgrade to $DBversion done adding syspref OPACNoResultsFound to control what displays when no results are found for a search in the OPAC.";
+ print "Upgrade to $DBversion done (adding syspref OPACNoResultsFound to control what displays when no results are found for a search in the OPAC.)\n";
SetVersion ($DBversion);
}
}
$DBversion = '3.03.00.042';
-if (C4::Context->preference("Version") < TransformToNum($DBversion) && $original_version < TransformToNum("3.02.06.001")) {
- $dbh->do("ALTER TABLE `items` DROP INDEX `itemsstocknumberidx`;");
- $dbh->do("ALTER TABLE items ADD INDEX itemstocknumberidx (stocknumber);");
- print "Upgrade to $DBversion done (Change items.stocknumber to be not unique)\n";
+if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
+ stocknumber_checker();
+ print "Upgrade to $DBversion done (5860 Index itemstocknumber)\n";
SetVersion ($DBversion);
}
+sub stocknumber_checker { #code reused later on
+ my @row;
+ #drop the obsolete itemSStocknumber idx if it exists
+ @row = $dbh->selectrow_array("SHOW INDEXES FROM items WHERE key_name='itemsstocknumberidx'");
+ $dbh->do("ALTER TABLE `items` DROP INDEX `itemsstocknumberidx`;") if @row;
+
+ #check itemstocknumber idx; remove it if it is unique
+ @row = $dbh->selectrow_array("SHOW INDEXES FROM items WHERE key_name='itemstocknumberidx' AND non_unique=0");
+ $dbh->do("ALTER TABLE `items` DROP INDEX `itemstocknumberidx`;") if @row;
+
+ #add itemstocknumber index non-unique IF it still not exists
+ @row = $dbh->selectrow_array("SHOW INDEXES FROM items WHERE key_name='itemstocknumberidx'");
+ $dbh->do("ALTER TABLE items ADD INDEX itemstocknumberidx (stocknumber);") unless @row;
+}
+
$DBversion = "3.03.00.043";
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
SetVersion($DBversion);
}
+$DBversion = '3.05.00.002';
+if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
+ #follow up fix 5860: some installs already past 3.3.0.42
+ stocknumber_checker();
+ print "Upgrade to $DBversion done (Fix for stocknumber index)\n";
+ SetVersion ($DBversion);
+}
+
+$DBversion = "3.05.00.003";
+if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) {
+ $dbh->do(qq{
+ INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('OpacRenewalBranch','checkoutbranch','Choose how the branch for an OPAC renewal is recorded in statistics','itemhomebranch|patronhomebranch|checkoutbranch|null','Choice');
+ });
+ print "Upgrade to $DBversion done (Adds New System preference OpacRenewalBranch)\n";
+ SetVersion($DBversion);
+}
+
+$DBversion = "3.05.00.004";
+if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
+ $dbh->do("INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ShowReviewerPhoto',1,'If ON, photo of reviewer will be shown beside comments in OPAC',NULL,'YesNo');");
+ print "Upgrade to $DBversion done (Add syspref ShowReviewerPhoto)\n";
+ SetVersion($DBversion);
+}
+
+$DBversion = "3.05.00.005";
+if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) {
+ $dbh->do("INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('BasketConfirmations', '1', 'When closing or reopening a basket,', 'always ask for confirmation.|do not ask for confirmation.', 'Choice');");
+ print "Upgrade to $DBversion done (Adds pref BasketConfirmations)\n";
+ SetVersion($DBversion);
+}
+
+$DBversion = "3.05.00.006";
+if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
+ $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('MARCAuthorityControlField008', '|| aca||aabn | a|a d', NULL, NULL, 'Textarea')");
+ print "Upgrade to $DBversion done (Add syspref MARCAuthorityControlField008)\n";
+ SetVersion ($DBversion);
+}
+
+$DBversion = "3.05.00.007";
+if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
+ $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpenLibraryCovers',0,'If ON Openlibrary book covers will be show',NULL,'YesNo');");
+ print "Upgrade to $DBversion done (Add syspref OpenLibraryCovers)\n";
+ SetVersion($DBversion);
+}
+
+$DBversion = "3.05.00.008";
+if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
+ $dbh->do("ALTER TABLE `cities` ADD `city_state` VARCHAR( 100 ) NULL DEFAULT NULL AFTER `city_name`;");
+ $dbh->do("ALTER TABLE `cities` ADD `city_country` VARCHAR( 100 ) NULL DEFAULT NULL AFTER `city_zipcode`;");
+ print "Add state and country to cities table corresponding to new columns in borrowers\n";
+ SetVersion($DBversion);
+}
+
=head1 FUNCTIONS
=head2 DropAllForeignKeys($table)
color : #669ACC;
}
-a.overdue,.overdue {
+a.overdue,
+.overdue,
+.debit {
color : #cc0000;
}
padding:0.3em 0;
}
+div.yui-b fieldset.brief fieldset {
+ margin : 0 .3em;
+ padding : .5em;
+}
+
+div.yui-b fieldset.brief fieldset legend {
+ font-size : 85%;
+}
+
fieldset.rows {
border-width : 1px;
border-bottom : 1px solid #666;
div.message ul+h4 {
margin-top : .7em;
}
+
+div.note {
+ background: #f4f6fa;
+ background-repeat : no-repeat;
+ background-position : left center;
+ background-image : url("../../img/note.png");
+ background-image: url("../../img/note.png"), -moz-linear-gradient(top, #f4f6fa 0%, #e8edf6 100%); /* FF3.6+ */
+ background-image: url("../../img/note.png"), -webkit-gradient(linear, left top, left bottom, color-stop(0%,#f4f6fa), color-stop(100%,#e8edf6)); /* Chrome,Safari4+ */
+ background-image: url("../../img/note.png"), -webkit-linear-gradient(top, #f4f6fa 0%,#e8edf6 100%); /* Chrome10+,Safari5.1+ */
+ background-image: url("../../img/note.png"), -o-linear-gradient(top, #f4f6fa 0%,#e8edf6 100%); /* Opera11.10+ */
+ background-image: url("../../img/note.png"), -ms-linear-gradient(top, #f4f6fa 0%,#e8edf6 100%); /* IE10+ */
+ filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#f4f6fa', endColorstr='#e8edf6',GradientType=0 ); /* IE6-9 */
+ background-image: url("../../img/note.png"), linear-gradient(top, #f4f6fa 0%,#e8edf6 100%); /* W3C */
+ border : 1px solid #BCBCBC;
+ padding : .5em .5em .5em 20px;
+ margin : .5em 0;
+}
div.results {
padding : .7em 0;
tr.transfered td {
background-color : #e8f0f6;
}
-.waitinghere {
+.waitinghere,
+.credit {
color : #669900;
}
border : 1px solid #EEE;
padding : 0.3em 0.4em;
}
-</style>
\ No newline at end of file
+#circ_circulation_issue {
+ position: relative;
+ }
+
+#clearscreen {
+ margin-right: 0;
+ position: absolute;
+ top:0;
+ right:0;
+ }
+/* CSS Hack to target Firefox */
+@-moz-document url-prefix() {
+ #clearscreen {
+ margin-right : 1em;
+ top: -1em;
+ }
+}
+#clearscreen a {
+ display:block;
+ -moz-border-radius: 0 0 0 5px;
+ border-radius: 0 0 0 5px;
+ padding : 0 .7em .2em .7em;
+ background-color : #EEE;
+ color : #CCC;
+ text-shadow: 0px -1px 0px #666;
+ text-decoration: none;
+ font-size: 160%;
+ font-weight : bold
+ }
+#clearscreen a:hover {
+ color : #cc0000;
+ }
+
<fieldset id="acqui_basket_add">
<legend>Add Order To Basket</legend>
+ [% IF has_budgets %]
<form action="/cgi-bin/koha/acqui/neworderbiblio.pl" method="post">
<input type="hidden" name="booksellerid" value="[% booksellerid %]" />
<input type="hidden" name="basketno" value="[% basketno %]" />
<li><a href="/cgi-bin/koha/acqui/addorderiso2709.pl?booksellerid=[% booksellerid %]&basketno=[% basketno %]"> From a staged file</a></li>
</ul>
</form>
+ [% ELSE %]
+ You can't create any orders unless you first <a href="/cgi-bin/koha/admin/aqbudgetperiods.pl">define a budget and a fund</a>.
+ [% END %]
</fieldset>
\ No newline at end of file
+<script type="text/javascript">//<![CDATA[
+ $(document).ready(function() {
+ var path = location.pathname.substring(1);
+ var url = window.location.toString();
+ url.match(/\?(.+)$/);
+ var params = RegExp.$1;
+ if (params) { params = "?" + params; }
+ $('#navmenulist a[href$="/' + path + params + '"]').css('font-weight','bold');
+ });
+//]]>
+</script>
+<div id="navmenu">
+<div id="navmenulist">
<h5>System Preferences</h5>
<ul>
<li><a href="/cgi-bin/koha/admin/preferences.pl">System Preferences</a></li>
<!-- <li><a href="/cgi-bin/koha/admin/printers.pl">Network Printers</a></li> -->
<li><a href="/cgi-bin/koha/admin/z3950servers.pl">Z39.50 Client Targets</a></li>
</ul>
+</div>
+</div>
[% IF ( CAN_user_circulate ) %]
<div id="circ_search" class="residentsearch" style="display:none;">
<p class="tip">Enter patron card number or partial name:</p>
- <form action="/cgi-bin/koha/circ/circulation.pl" method="post">
+ <form action="/cgi-bin/koha/circ/circulation.pl" method="post" autocomplete="off">
[% IF ( CircAutocompl ) %]
<div class="autocomplete">
<div id="borrowerautocomplete" class="autocomplete">
[% IF ( CAN_user_circulate ) %]
<div id="checkin_search" class="residentsearch" style="display:none;">
<p class="tip">Scan a barcode to check in:</p>
- <form method="post" action="/cgi-bin/koha/circ/returns.pl">
+ <form method="post" action="/cgi-bin/koha/circ/returns.pl" autocomplete="off">
<input name="barcode" id="ret_barcode" size="40" />
<input value="Submit" class="submit" type="submit" />
</form>
[% IF ( CAN_user_editcatalogue_edit_items ) %]{ text: _("Edit Items"), url: "/cgi-bin/koha/cataloguing/additem.pl?biblionumber=[% biblionumber %]" },[% END %]
[% IF ( CAN_user_editcatalogue_edit_items ) %]{ text: _("Attach Item"), url: "/cgi-bin/koha/cataloguing/moveitem.pl?biblionumber=[% biblionumber %]" },[% END %]
[% IF ( CAN_user_editcatalogue_edit_catalogue ) %]{ text: _("Edit as New (Duplicate)"), url: "/cgi-bin/koha/cataloguing/addbiblio.pl?biblionumber=[% biblionumber %]&frameworkcode=&op=duplicate" },[% END %]
+ [% IF ( CAN_user_editcatalogue_edit_catalogue ) %]{ text: _("Replace Record via Z39.50"), onclick: {fn: PopupZ3950 } },[% END %]
[% IF ( CAN_user_editcatalogue_edit_catalogue ) %]{ text: _("Delete Record"), onclick: {fn: confirm_deletion }[% IF ( count ) %],id:'disabled'[% END %] },[% END %]
[% IF ( CAN_user_editcatalogue_edit_items ) %]{ text: _("Delete all Items"), onclick: {fn: confirm_items_deletion } }[% END %]
];
});
[% END %]
[% END %][% END %]
- [% IF ( CAN_user_editcatalogue_edit_catalogue ) %]
- new YAHOO.widget.Button({
- id: "z3950search",
- type: "button",
- label: _("Z39.50 Search"),
- container: this,
- onclick: {fn:function(){PopupZ3950()}}
- });
- [% END %]
+
});
//]]>
</script>
[% IF ( CAN_user_circulate ) %]
<div id="checkin_search" class="residentsearch" style="display:none;">
<p class="tip">Scan a barcode to check in:</p>
- <form method="post" action="/cgi-bin/koha/circ/returns.pl">
+ <form method="post" action="/cgi-bin/koha/circ/returns.pl" autocomplete="off">
<input name="barcode" id="ret_barcode" size="40" accesskey="r" />
<input value="Submit" class="submit" type="submit" />
</form>
function update_child() {
// var borrowernumbervalue= $("#borrowernumber").attr("value");
[% IF ( CATCODE_MULTI ) %]
- window.open('/cgi-bin/koha/members/update-child.pl?op=multi&borrowernumber=[% borrowernumber %]','UpdateChild','width=400,height=300,toolbar=no,scrollbars=no,resizable=yes');
+ window.open('/cgi-bin/koha/members/update-child.pl?op=multi&borrowernumber=[% borrowernumber %]','UpdateChild','width=400,height=300,toolbar=no,scrollbars=yes,resizable=yes');
[% ELSE %]
confirm_updatechild();
[% END %]
function update_child() {
[% IF ( CATCODE_MULTI ) %]
- window.open('update-child.pl?op=multi&borrowernumber=[% borrowernumber %]','UpdateChild','width=400,height=300,toolbar=no,scrollbars=no,resizable=yes');
+ window.open('update-child.pl?op=multi&borrowernumber=[% borrowernumber %]','UpdateChild','width=400,height=300,toolbar=no,scrollbars=yes,resizable=yes');
[% ELSE %]
confirm_updatechild();
[% END %]
[% IF ( CAN_user_circulate ) %]
<div id="circ_search" class="residentsearch" style="display:none;">
<p class="tip">Enter patron card number or partial name:</p>
- <form action="/cgi-bin/koha/circ/circulation.pl" method="post">
+ <form action="/cgi-bin/koha/circ/circulation.pl" method="post" autocomplete="off">
[% IF ( CircAutocompl ) %]
<div class="autocomplete">
<div id="borrowerautocomplete" class="autocomplete">
[% IF ( subscriptionid ) %]
var editmenu = [
[% IF ( CAN_user_serials_edit_subscription ) %]
- { text: _("Edit Subscription"), [% IF ( cannotedit ) %]disabled: true, [% END %] url: "/cgi-bin/koha/serials/subscription-add.pl?op=mod&subscriptionid=[% subscriptionid %]" },
+ { text: _("Edit Subscription"), [% IF ( cannotedit ) %]disabled: true, [% END %] url: "/cgi-bin/koha/serials/subscription-add.pl?op=modify&subscriptionid=[% subscriptionid %]" },
[% END %]
[% IF ( CAN_user_serials_create_subscription ) %]
{ text: _("Edit as New (Duplicate)"), [% IF ( cannotedit ) %]disabled: true, [% END %] url: "/cgi-bin/koha/serials/subscription-add.pl?op=dup&subscriptionid=[% subscriptionid %]" },
[% IF ( CAN_user_serials_edit_subscription || CAN_user_serials_create_subscription || CAN_user_serials_delete_subscription ) %]
[% UNLESS ( cannotedit ) %]
- <li id="editmenuc"><a id="edit" href="/cgi-bin/koha/serials/subscription-add.pl?op=mod&subscriptionid=[% subscriptionid %]">Edit</a></li>
+ <li id="editmenuc"><a id="edit" href="/cgi-bin/koha/serials/subscription-add.pl?op=modify&subscriptionid=[% subscriptionid %]">Edit</a></li>
[% END %]
[% END %]
<li>Andrew Chilton</li>
<li>Garry Collum</li>
<li>John Copeland</li>
+ <li>Jeremy Crabtree</li>
<li>Christophe Croullebois</li>
<li>Nate Curulla</li>
<li>Vincent Danjean</li>
<li>Ambrose Li (translation tool)</li>
<li>Gynn Lomax</li>
<li>Robert Lyon (Corporate Serials)</li>
+ <li>Francois Marier</li>
<li>Frère Sébastien Marie</li>
<li>Ricardo Dias Marques</li>
<li>Julian Maurice</li>
<th>Avail</th>
</tr>
</thead>
- <tfoot>
+ <tfoot id="funds_total">
<tr>
<th>Total</th>
<th> </th>
[% UNLESS ( grouped ) %]
<script type="text/javascript">
//<![CDATA[
- function confirm_reopen() {
- var is_confirmed = confirm(_('Are you sure you want to reopen this basket?'));
+ function confirm_reopen(skip) {
+ var is_confirmed = skip || confirm(_('Are you sure you want to reopen this basket?'));
if (is_confirmed) {
window.location = "[% script_name %]?op=reopen&basketno=[% basketno %]";
}
<li><a href="basketheader.pl?basketno=[% basketno %]&op=add_form" class="button" id="basketheadbutton">Edit basket header information</a></li>
<li><a href="javascript:confirm_deletion();" class="button" id="delbasketbutton">Delete this basket</a></li>
[% IF ( unclosable ) %]
- <li><button onclick="confirm_close()" class="yui-button-disabled" id="closebutton" type="button" disabled="disabled" title="You can not close this basket">Can not close basket</button></li>
[% ELSIF ( uncertainprices ) %]
<li><a href="/cgi-bin/koha/acqui/uncertainprice.pl?booksellerid=[% booksellerid %]&owner=1" class="button" id="uncertpricesbutton">Uncertain prices</a></li>
[% ELSE %]
//]]>
</script>
<ul id="toolbar-list" class="toolbar">
- <li><a href="javascript:confirm_reopen();" class="button" id="reopenbutton">Reopen this basket</a></li>
+ <li><a href="javascript:confirm_reopen([% skip_confirm_reopen %]);" class="button" id="reopenbutton">Reopen this basket</a></li>
</ul>
</div>
[% END %]
<form action="/cgi-bin/koha/acqui/basket.pl" class="confirm">
<h1>Are you sure you want to close basket [% basketname %]?</h1>
<p>
- <label for="createbasketgroup">create a purchase order now?</label>
+ <label for="createbasketgroup">Attach this basket to a new basket group with the same name</label>
<input type="checkbox" id="createbasketgroup" name="createbasketgroup"/>
</p>
<input type="hidden" id="basketno" value="[% basketno %]" name="basketno" />
<input type="text" size="50" name="series" id="series" value="[% seriestitle %]" />
[% END %]
</li>
+ </li>
+ [% UNLESS ( biblionumber ) %]
+ [% IF ( itemtypeloop ) %]
+ <li>
+ <span class="label">Item type:</span>
+ <select name="itemtype" style="width:12em;">
+ [% FOREACH itemtype IN itemtypeloop %]
+ [% IF ( itemtype.selected ) %]
+ <option value="[% itemtype.itemtype %]" selected="selected">[% itemtype.description %]</option>
+ [% ELSE %]
+ <option value="[% itemtype.itemtype %]">[% itemtype.description %]</option>
+ [% END %]
+ [% END %]
+ </select>
+ </li>
+ [% END %]
+ [% END %]
</ol>
</fieldset>
[% IF ( items ) %]
[% FOREACH item IN items %]
<div id="outeritemblock">
<div id="itemblock">
- <ol>[% FOREACH iteminformatio IN item.iteminformation %]<li>
- <div class="subfield_line" style="[% iteminformatio.hidden %];" id="subfield[% iteminformatio.serialid %][% iteminformatio.countitems %][% iteminformatio.subfield %][% iteminformatio.random %]">
+ <ol>[% FOREACH iteminformatio IN item.iteminformation %]<li style="[% iteminformatio.hidden %];">
+ <div class="subfield_line" id="subfield[% iteminformatio.serialid %][% iteminformatio.countitems %][% iteminformatio.subfield %][% iteminformatio.random %]">
<label>[% iteminformatio.subfield %] - [% IF ( iteminformatio.mandatory ) %]<b>[% END %][% iteminformatio.marc_lib %][% IF ( iteminformatio.mandatory ) %] *</b>[% END %]</label>
[% iteminformatio.marc_value %]
[% IF ( budget_perm_1 ) %]<option value="1" selected="selected">Owner</option>[% ELSE %]<option value="1">Owner</option>[% END %]
[% IF ( budget_perm_2 ) %]<option value="2" selected="selected">Library</option>[% ELSE %]<option value="2">Library</option>[% END %]
</option>
+ </select>
</li>
<li>
[% IF ( action_add_value ) %]New authorized value[% END %]
[% IF ( action_add_category ) %]New category[% END %]
</h1>
+
+ [% IF ( action_modify ) %]<div class="note"><strong>NOTE:</strong> If you change an authorized value, existing records using it won't be updated.</div>[% END %]
+
<form action="[% script_name %]" name="Aform" method="post">
<input type="hidden" name="op" value="add_validate" />
<input type="hidden" name="offset" value="[% offset %]" />
</ul></div>
<h1>Authorized values</h1>
-<p>These values can be used in many pull down menus throughout the Koha system. You can define as many categories as you want, and as many authorized values as you want in each category.</p>
-
-<p>When you define the MARC subfield structure, you can link a subfield to a authorized-value category. When the user ask for adding of modifying a biblio, the subfield is not entered through a free field, but though a list of authorized values</p>
+<div class="note"><strong>NOTE:</strong> If you change an authorized value, existing records using it won't be updated.</div>
[% IF ( duplicate_category ) %]
-<div>
-<span class="problem">Could not add value "[% duplicate_value %]" for category
- "[% duplicate_category %]" — value already present.
-</span>
+<div class="dialog alert">Could not add value "[% duplicate_value %]" for category "[% duplicate_category %]" — value already present.
</div>
[% END %]
<form action="/cgi-bin/koha/admin/authorised_values.pl" method="post" id="category"><label for="searchfield">Show Category: </label>[% tab_list %] <input type="submit" value="Submit" /></form>
<span id="pager[% codes_loo.code %]table" class="pager">
<form class="formpager"> <strong>page(s)</strong> :
- <img src="[% codes_loo.interface %]/prog/img/first.png" class="first"/>
- <img src="[% codes_loo.interface %]/prog/img/prev.png" class="prev"/>
+ <img src="[% interface %]/[% theme %]/img/first.png" class="first"/>
+ <img src="[% interface %]/[% theme %]/img/prev.png" class="prev"/>
<input type="text" size="5" class="pagedisplay"/>
- <img src="[% codes_loo.interface %]/prog/img/next.png" class="next"/>
- <img src="[% codes_loo.interface %]/prog/img/last.png" class="last"/>
+ <img src="[% interface %]/[% theme %]/img/next.png" class="next"/>
+ <img src="[% interface %]/[% theme %]/img/last.png" class="last"/>
, entries/page :
<select class="pagesize">
<option selected="selected" value="10">10</option>
<tbody>
[% FOREACH to_branch_loo IN codes_loo.to_branch_loop %]
- [% UNLESS ( loop.odd ) %]<tr class="highlight"><!-- TMPL_ELSE
---><tr>[% END %]
+ [% UNLESS ( loop.odd ) %]<tr class="highlight">[% ELSE %]<tr>[% END %]
<td><label style="min-width:400px;" for="[% to_branch_loo.code %][% to_branch_loo.toBranch %]row">[% to_branch_loo.toBranch %] - [% to_branch_loo.toBranchname %]</label></td>
<td><input type="checkbox" id="[% to_branch_loo.code %][% to_branch_loo.toBranch %]row" name="[% to_branch_loo.code %]_[% to_branch_loo.toBranch %]" [% IF ( to_branch_loo.isChecked ) %]checked="checked" [% END %] /></td>
</tr>
</li>
<li>
<label for="branchname">Name</label>
- <input type="text" name="branchname" id="branchname" size="40" maxlength="80" value="[% branch_name |html %]" />
+ <input type="text" name="branchname" id="branchname" size="80" value="[% branch_name |html %]" />
</li>
</ol>
</fieldset>
[% categorycode %]
[% ELSE %]
<label for="categorycode">Category code:</label>
- <input type="text" name="categorycode" id="categorycode" size="11" maxlength="10" value="[% categorycode |html %]" />
+ <input type="text" name="categorycode" id="categorycode" size="10" maxlength="10" value="[% categorycode |html %]" />
[% END %]
</li>
<li>
<label for="categoryname">Name: </label>
- <input type="text" name="categoryname" id="categoryname" size="40" maxlength="80" value="[% categoryname |html %]" />
+ <input type="text" name="categoryname" id="categoryname" size="32" maxlength="32" value="[% categoryname |html %]" />
</li>
<li>
<label for="codedescription">Description: </label>
- <input type="text" name="codedescription" id="codedescription" size="70" maxlength="80" value="[% codedescription |html %]" />
+ <input type="text" name="codedescription" id="codedescription" size="70" value="[% codedescription |html %]" />
</li>
<li>
<label for="categorytype">Category Type: </label>
<script type="text/javascript" id="js">$(document).ready(function() {
$("#table_categorie").tablesorter({
sortList: [[0,0]],
- headers: { 10: { sorter: false}}
+ widgets: ['zebra'],
+ headers: { 11: { sorter: false}}
}).tablesorterPager({container: $("#pagertable_categorie"),positionFixed: false,size: 20});
}); </script>
[% INCLUDE 'calendar.inc' %]
<th scope="col" colspan="2"> </th>
</thead>
[% FOREACH loo IN loop %]
- [% UNLESS ( loop.odd ) %]
- <tr class="highlight">
- [% ELSE %]
<tr>
- [% END %]
<td>[% loo.categorycode |html %]</td>
<td>
<a href="[% loo.script_name %]?op=add_form&categorycode=[% loo.categorycode |url %]">[% loo.description |html %]</a>
<td>[% IF ( loo.hidelostitems ) %]Hidden[% ELSE %]Shown[% END %]</td>
<td>[% loo.reservefee %]</td>
[% IF ( EnhancedMessagingPreferences ) %]
- <td>
+ <td style="white-space: nowrap; font-size:80%;">
[% IF ( loo.messaging_prefs ) %]
- [% IF ( messaging_preference.Item_Due ) %]Item Due
- [% ELSIF ( messaging_preference.Advance_Notice ) %]Advance Notice
- [% ELSIF ( messaging_preference.Upcoming_Events ) %]Upcoming Events
- [% ELSIF ( messaging_preference.Hold_Filled ) %]Hold Filled
- [% ELSIF ( messaging_preference.Item_Check_in ) %]Item Check-in
- [% ELSIF ( messaging_preference.Item_Checkout ) %]Item Checkout
- [% ELSE %]Unknown
- [% END %] :
- [% FOREACH transport IN messaging_pref.transports %]
- [% transport.transport %]
- [% END %]
- <br />
+ [% FOREACH prefs IN loo.messaging_prefs %]
+ [% FOREACH transport IN prefs.transports %]
+ [% IF ( transport.transport ) %]
+ [% IF ( prefs.Item_Due ) %]Item Due
+ [% ELSIF ( prefs.Advance_Notice ) %]Advance Notice
+ [% ELSIF ( prefs.Upcoming_Events ) %]Upcoming Events
+ [% ELSIF ( prefs.Hold_Filled ) %]Hold Filled
+ [% ELSIF ( prefs.Item_Check_in ) %]Item Check-in
+ [% ELSIF ( prefs.Item_Checkout ) %]Item Checkout
+ [% ELSE %]Unknown
+ [% END %]:
+ <strong>[% transport.transport %]</strong><br />
+ [% ELSE %]None<br />[% END %]
+ [% END %]
+ [% END %]
[% ELSE %]
- none
+ None
[% END %]
</td>
[% END %]
<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.min.js"></script>
<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.pager.js"></script>
<script type="text/javascript" id="js">$(document).ready(function() {
+ $.tablesorter.defaults.widgets = ['zebra'];
$("#table_cities").tablesorter({
sortList: [[1,0]],
- headers: { 3: { sorter: false},4: { sorter: false}}
+ headers: { 5: { sorter: false},6: { sorter: false}}
}).tablesorterPager({container: $("#pagertable_cities"),positionFixed: false,size: 20});
}); </script>
<script type="text/javascript">
<span class="label">City ID: </span>[% cityid %]</li>
[% END %]
<li>
- <label for="city_name">City, State: </label>
- <input type="text" name="city_name" id="city_name" size="40" maxlength="80" value="[% city_name |html %]" />
+ <label for="city_name" class="required" title="required">City: </label>
+ <input type="text" name="city_name" id="city_name" size="80" maxlength="100" value="[% city_name |html %]" />
+ </li>
+ <li>
+ <label for="city_state">State: </label>
+ <input type="text" name="city_state" id="city_state" size="80" maxlength="100" value="[% city_state |html %]" />
</li>
<li>
- <label for="city_zipcode">Zip/Postal code: </label>
- <input type="text" name="city_zipcode" id="city_zipcode" size="10" maxlength="10" value="[% city_zipcode %]" />
+ <label for="city_zipcode" class="required" title="required">Zip/Postal code: </label>
+ <input type="text" name="city_zipcode" id="city_zipcode" size="20" maxlength="20" value="[% city_zipcode %]" />
+ </li>
+ <li>
+ <label for="city_country">Country: </label>
+ <input type="text" name="city_country" id="city_country" size="80" maxlength="100" value="[% city_country |html %]" />
</li></ol></fieldset>
<fieldset class="action">
<tr><th>City id</th>
<td>[% cityid %]</td>
</tr>
- <tr><th>City, State</th>
+ <tr><th>City</th>
<td>[% city_name %]</td>
</tr>
+ <tr><th>State</th>
+ <td>[% city_state %]</td>
+ </tr>
<tr><th>Zip/Postal code</th>
<td>[% city_zipcode %]</td>
</tr>
+ <tr><th>Country</th>
+ <td>[% city_country %]</td>
+ </tr>
</table>
<form action="[% script_name %]" method="post">
<input type="hidden" name="op" value="delete_confirmed" />
<table id="table_cities">
<thead>
<th>City ID</th>
- <th>City, State</th>
+ <th>City</th>
+ <th>State</th>
<th>Zip/Postal code</th>
+ <th>Country</th>
<th> </th>
<th> </th>
</thead>
[% END %]
<td>[% loo.cityid %]</td>
<td>[% loo.city_name %]</td>
+ <td>[% loo.city_state %]</td>
<td>[% loo.city_zipcode %]</td>
-
+ <td>[% loo.city_country %]</td>
<td><a href="[% loo.script_name %]?op=add_form&cityid=[% loo.cityid %]">Edit</a></td>
<td><a href="[% loo.script_name %]?op=delete_confirm&cityid=[% loo.cityid %]">Delete</a></td>
</tr>
</li>
[% END %]
<li>
- <label for="description">Description</label><input type="text" id="description" name="description" size="48" maxlength="80" value="[% description |html %]" /> </li>
+ <label for="description">Description</label><input type="text" id="description" name="description" size="48" value="[% description |html %]" /> </li>
[% IF ( noItemTypeImages ) %]
<li><span class="label">Image: </span>Item type images are disabled. To enable them, turn off the <a href="/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=noItemTypeImages">noItemTypeImages system preference</a></li></ol>
[% ELSE %]</ol>
receiving: receiving an order.
cataloguing: cataloging the record.
-
+ - When closing or reopening a basket,
+ - pref: BasketConfirmations
+ default: 1
+ choices:
+ 1: always ask for confirmation.
+ 2: do not ask for confirmation.
+ -
- Display currencies using the following format
- pref: CurrencyFormat
choices:
no: Do
- automatically update attached biblios when changing an authority record. If this is off, please ask your administrator to enable the merge_authorities.pl cronjob.
-
+ - Use the following text for the contents of MARC authority control field 008 position 06-39 (fixed length data elements). Do NOT include the date (position 00-05).
+ - pref: MARCAuthorityControlField008
+ default: "|| aca||aabn | a|a d"
+ type: textarea
+ class: code
+ -
- pref: UseAuthoritiesForTracings
default: yes
choices:
yes: Add
no: "Don't add"
- cover images from Google Books to search results and item detail pages on the OPAC.
+ OpenLibrary:
+ -
+ - pref: OpenLibraryCovers
+ choices:
+ yes: Add
+ no: "Don't add"
+ - cover images from OpenLibrary to search results and item detail pages on the OPAC.
Library Thing:
# Awkward syntax below, due to quoting conflicts
-
no: Hide
- reviewer's name above comments in OPAC.
-
+ - pref: ShowReviewerPhoto
+ choices:
+ yes: Show
+ no: Hide
+ - reviewer's photo beside comments in OPAC.
+ -
- pref: RequestOnOpac
choices:
yes: Allow
no: "Don't allow"
- patrons to renew their own books on the OPAC.
-
+ - Use
+ - pref: OpacRenewalBranch
+ choices:
+ itemhomebranch: "The Items' home branch"
+ patronhomebranch: "The Patrons' home branch"
+ checkoutbranch: "The branch the item was checked out from"
+ null: "NULL"
+ opacrenew: "OPACRenew"
+ - as branchcode to store in the statistics table
+ -
- Only allow patrons to renew their own books on the OPAC if they have less than
- pref: OPACFineNoRenewals
class: currency
- - '[% local_currency %] in fines (leave blank to disable).'
+ - '[% local_currency %] in fines (set a large value to always allow renewal).'
-
- pref: OPACViewOthersSuggestions
choices:
type: textarea
class: code
-
- - "Show the following HTML in the More menu at the top of each page on the staff client (should be a list of links or blank):"
+ - "Show the following HTML to the left of the More menu at the top of each page on the staff client (should be a list of links or blank):"
- pref: IntranetNav
type: textarea
class: code
[% END %]
<li>
<label for="road_type">Road type: </label>
- <input type="text" name="road_type" id="road_type" size="40" maxlength="80" value="[% road_type |html %]" />
+ <input type="text" name="road_type" id="road_type" size="80" maxlength="100" value="[% road_type |html %]" />
</li></ol></fieldset>
<fieldset class="action">
[% IF ( number.highlight ) %]
[% number.number %]
[% ELSE %]
- <a href="auth_finder.pl?startfrom=[% number.startfrom %]&authtypecode=[% number.authtypecode %][% FOREACH searchdat IN number.searchdata %]&[% searchdat.term %]=[% searchdat.val %][% END %]&op=do_search&type=intranet&index=[% number.index %]&tagid=[% number.tagid %]&orderby=[% number.orderby %]">
+ <a href="auth_finder.pl?startfrom=[% number.startfrom %]&authtypecode=[% authtypecode %][% FOREACH searchdat IN number.searchdata %]&[% searchdat.term %]=[% searchdat.val %][% END %]&op=do_search&type=intranet&index=[% index %]&tagid=[% tagid %]&orderby=[% orderby %]">
[% number.number %]</a>
[% END %]
[% END %]
<td>
[% IF ( resul.repets ) %]
[% FOREACH repet IN resul.repets %]
- <a href="javascript:jumpfull('blinddetail-biblio-search.pl?authid=[% repet.authid %]&index=[% repet.index %]&repet=[% repet.repet %]')" title="[% repet.value %]">[% repet.repet %]</a>
+ <a href="javascript:jumpfull('blinddetail-biblio-search.pl?authid=[% resul.authid %]&index=[% repet.index %]&repet=[% repet.repet %]')" title="[% repet.value %]">[% repet.repet %]</a>
[% END %]
[% ELSE %]
<a href="javascript:jumpfull('blinddetail-biblio-search.pl?authid=[% resul.authid %]&index=[% index %]')">choose</a>
[% IF ( number.highlight ) %]
[% number.number %]
[% ELSE %]
- <a href="auth_finder.pl?startfrom=[% number.startfrom %]&authtypecode=[% number.authtypecode %][% FOREACH searchdat IN number.searchdata %]&[% searchdat.term %]=[% searchdat.val %][% END %]&op=do_search&type=intranet&index=[% number.index %]&tagid=[% number.tagid %]&orderby=[% number.orderby %]">
+ <a href="auth_finder.pl?startfrom=[% number.startfrom %]&authtypecode=[% authtypecode %][% FOREACH searchdat IN number.searchdata %]&[% searchdat.term %]=[% searchdat.val %][% END %]&op=do_search&type=intranet&index=[% index %]&tagid=[% tagid %]&orderby=[% orderby %]">
[% number.number %]</a>
[% END %]
[% END %]
[% IF ( pages ) %] [% END %][% pages %] [% IF ( illus ) %][% illus %][% END %]
[% IF ( size ) %][% size %][% END %]
</li>
-[% IF ( MARCurlS ) %]<li>
+[% IF ( MARCURLS ) %]<li>
<strong>Online Resources:</strong>
- <ul> [% FOREACH MARCurl IN MARCurlS %]
+ <ul> [% FOREACH MARCurl IN MARCURLS %]
<li>[% IF ( MARCurl.part ) %][% MARCurl.part %]
<br />[% END %]
<!-- here you might do a tmpl_if name="toc" and use greybox or equivalent for table of contents -->
- <a href="[% MARCurl.MARCurl %]" title="[% MARCurl.MARCurl %]">[% MARCurl.linktext %]</a>
+ <a href="[% MARCurl.MARCURL %]" title="[% MARCurl.MARCURL %]">[% MARCurl.linktext %]</a>
[% IF ( MARCurl.notes ) %]<ul>[% FOREACH note IN MARCurl.notes %]<li>[% note.note %]</li>[% END %]</ul>[% END %]</li>
[% END %]</ul>
</li>
<span class="datedue">Checked out
[% UNLESS ( itemloo.NOTSAMEBRANCH ) %]
to <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% itemloo.borrowernumber %]">
- [% IF ( hidepatronname ) %]
+ [% IF ( itemloo.hidepatronname ) %]
[% itemloo.cardnumber %]
[% ELSE %]
[% itemloo.firstname %] [% itemloo.surname %]
</td>
<td class="datelastseen">[% itemloo.datelastseen %]</td>
<td><a href="/cgi-bin/koha/catalogue/moredetail.pl?type=[% itemloo.type %]&itemnumber=[% itemloo.itemnumber %]&biblionumber=[% itemloo.biblionumber %]&bi=[% itemloo.biblioitemnumber %]#item[% itemloo.itemnumber %]">[% itemloo.barcode %]</a></td>
- [% IF ( itemloo.enumchron ) %] <td class="enumchron">
+ [% IF ( volinfo ) %] <td class="enumchron">
[% IF ( itemdata_enumchron ) %]
[% IF ( itemloo.enumchron ) %]
[% itemloo.enumchron %][% IF ( itemloo.serialseq ) %] -- [% END %]
</tr></thead>
<tbody>
[% FOREACH issue IN issues %]
- [% UNLESS ( loop.odd ) %]<tr class="highlight"><!-- TMPL_ELSE
---><tr>[% END %]
+ [% UNLESS ( loop.odd ) %]<tr class="highlight">[% ELSE %]<tr>[% END %]
<td><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% issue.borrowernumber %]">[% issue.surname %][% IF ( issue.firstname ) %], [% issue.firstname %][% END %]</a></td>
<td>[% IF ( issue.barcode ) %]
<a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% issue.biblionumber %]&itemnumber=[% issue.itemnumber %]">[% issue.barcode %]</a>
<table>
<tr>
[% IF ( AmazonEnabled ) %][% IF ( AmazonCoverImages ) %]<th> </th>[% END %][% END %]
- <th>Results</th>
+ <th colspan="2">Results</th>
<th>Location</th>
</tr>
<!-- Actual Search Results -->
[% FOREACH SEARCH_RESULT IN SEARCH_RESULTS %]
[% IF ( loop.odd ) %]<tr>[% ELSE %]<tr class="highlight">[% END %]
- [% IF ( SEARCH_RESULT.AmazonEnabled ) %][% IF ( SEARCH_RESULT.AmazonCoverImages ) %]
+ [% IF ( AmazonEnabled ) %][% IF ( AmazonCoverImages ) %]
<td>
<a class="p1" href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% SEARCH_RESULT.biblionumber |url %]">
[% ELSIF ( BiblioDefaultViewisbd ) %]
<form action="/cgi-bin/koha/catalogue/ISBDdetail.pl" method="post">
[% ELSE %]
- <form action="/cgi-bin/koha/catalogue/detail.pl" method="post">
+ <form method="link" action="/cgi-bin/koha/cataloguing/moveitem.pl?biblionumber=[% biblionumber %]"/>
[% END %]
+ <input type="submit" class="attachanother" value="Attach Another Item"/>
+ <input type="hidden" name="biblionumber" value="[% biblionumber %]" />
+ </form>
+ <form action="/cgi-bin/koha/catalogue/detail.pl" method="post">
<input type="submit" class="approve" value="OK" />
<input type="hidden" name="biblionumber" value="[% biblionumber %]" />
- </form></div>
+ </form>
+</div>
[% ELSE %]
[% IF ( missingparameter ) %]
<td>[% IF ( branchloo.seen ) %]
<span style="display:none;">[% branchloo.seen %][% branchloo.seentime %]</span>
<!-- invisible span for eventual use by tablesorter -->
- [% DEFAULT branchloo.seentime="??:??" %] [% branchloo.seen %]
+ [% branchloo.seen %] [% branchloo.seentime %]
[% ELSE %]Never
[% END %]
</td>
<li> <a href="/cgi-bin/koha/circ/waitingreserves.pl" title="holds waiting for patron pickup">Holds awaiting pickup</a></li>
<li> <a href="/cgi-bin/koha/circ/reserveratios.pl">Hold ratios</a></li>
<li> <a href="/cgi-bin/koha/circ/transferstoreceive.pl" title="transfers to receive at your library">Transfers to receive</a></li>
- <li> <a href="/cgi-bin/koha/circ/overdue.pl">Overdues</a>
+ [% IF ( CAN_user_reports_execute_reports ) %]<li> <a href="/cgi-bin/koha/circ/overdue.pl">Overdues</a>
- <b>Warning:</b> This report is very resource intensive on
- systems with large numbers of overdue items.</li>
+ systems with large numbers of overdue items.</li>[% END %]
<li> <a href="/cgi-bin/koha/circ/branchoverdues.pl">Overdues with fines</a> - Limited to your library. See report help for other details.</li>
<!-- <li> <a href="/cgi-bin/koha/circ/billing.pl">Billing</a></li> -->
<!-- <li> <a href="/cgi-bin/koha/circ/stats.pl?time=yesterday">Daily reconciliation</a></li> -->
};
//]]>
</script>
-
[% INCLUDE 'calendar.inc' %]
</head>
<body>
<select name="type" id="type" onchange="this.form.borrower_message.value=this.options[this.selectedIndex].value;">
<option value="">Select Note</option>
[% FOREACH canned_bor_notes_loo IN canned_bor_notes_loop %]
- <option value="[% canned_bor_notes_loo.lib %]">[% canned_bor_notes_loo.authorised_value %]</option>
+ <option value="[% canned_bor_notes_loo.lib %]">[% canned_bor_notes_loo.lib %]</option>
[% END %]
</select>
</li>
[% END %]
</ul>
-<form method="post" action="/cgi-bin/koha/circ/circulation.pl">
+<form method="post" action="/cgi-bin/koha/circ/circulation.pl" autocomplete="off">
[% IF ( RESERVED ) %]
<p>
[% IF ( CGIselectborrower ) %]
[% INCLUDE 'patron-toolbar.inc' %]
-<form method="post" action="/cgi-bin/koha/circ/circulation.pl" id="mainform" name="mainform">
+<form method="post" action="/cgi-bin/koha/circ/circulation.pl" id="mainform" name="mainform" autocomplete="off">
<fieldset id="circ_circulation_selectborrower" class="brief">
<legend>Patron selection</legend>
[% END %]
-<form method="post" action="/cgi-bin/koha/circ/circulation.pl" id="mainform" name="mainform">
+<form method="post" action="/cgi-bin/koha/circ/circulation.pl" id="mainform" name="mainform" autocomplete="off">
<fieldset id="circ_circulation_issue">
[% IF ( DisplayClearScreenButton ) %]
- <input type="button" value="Clear Screen" onclick="window.location = '/cgi-bin/koha/circ/circulation.pl'" />
+ <span id="clearscreen"><a href="/cgi-bin/koha/circ/circulation.pl" title="Clear screen">x</a></span>
[% END %]
<label for="barcode">Checking out to [% firstname %] [% surname %] ([% cardnumber %]) </label>
[% IF ( expired ) %]
<li><span class="circ-hlt">Expiration:</span> Patron's card has expired.
- Patron's card expired on [% expiry %] <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% borrowernumber %]&cardnumber=[% cardnumber %]&destination=circ&reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&destination=circ&borrowernumber=[% borrowernumber %]&categorycode=[% categorycode %]">Edit Details</a>
+ [% IF ( expiry ) %]Patron's card expired on [% expiry %][% END %] <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% borrowernumber %]&cardnumber=[% cardnumber %]&destination=circ&reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&destination=circ&borrowernumber=[% borrowernumber %]&categorycode=[% categorycode %]">Edit Details</a>
</li>
[% END %]
<td>[% overdueloo.duedate %]</td>
<td><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% overdueloo.borrowernumber %]">[% overdueloo.name %]</a>
[% IF ( overdueloo.email ) %][<a href="mailto:[% overdueloo.email %]?subject=Overdue: [% overdueloo.title |html %]">email</a>][% END %]
- ([% IF ( overdueloo.phone ) %][% overdueloo.phone %][% ELSIF ( overdueloo.mobile ) %][% overdueloo.mobile %][% ELSIF ( overdueloo.phonepro ) %][% overdueloo.phonepro %][% END %])</td>
+ [% IF ( overdueloo.phone ) %]([% overdueloo.phone %])[% ELSIF ( overdueloo.mobile ) %]([% overdueloo.mobile %])[% ELSIF ( overdueloo.phonepro ) %]([% overdueloo.phonepro %])[% END %]</td>
<td>[% overdueloo.branchcode %]</td>
<td>[% INCLUDE 'biblio-default-view.inc' biblionumber = overdueloo.biblionumber %][% overdueloo.title |html %] [% overdueloo.subtitle %]</a> [% IF ( overdueloo.author ) %], by [% overdueloo.author %][% END %]
</td>
<form method="post" action="/cgi-bin/koha/circ/overdue.pl">
<fieldset class="brief">
<h4>Filter On:</h4>
+ <fieldset><legend>Date due:</legend>
<ol>
- <li style="border: dashed; border-width:1px;">Date due:
- <label for="dateduefrom">From:
+ <li><label for="dateduefrom">From:</label>
+ <input type="text" id="dateduefrom" name="dateduefrom" size="10" value="[% dateduefrom %]" />
<img src="[% themelang %]/lib/calendar/cal.gif" id="dateduefrom_button" alt="Show Calendar" />
- </label>
- <input type="text" id="dateduefrom" name="dateduefrom" size="20" value="[% dateduefrom %]" />
<script language="JavaScript" type="text/javascript">
Calendar.setup(
{
}
);
</script>
-
- <label for="datedueto">To:
+ </li>
+ <li>
+ <label for="datedueto">To:</label>
+ <input type="text" id="datedueto" name="datedueto" size="10" value="[% datedueto %]" />
<img src="[% themelang %]/lib/calendar/cal.gif" id="datedueto_button" alt="Show Calendar" />
- </label>
- <input type="text" id="datedueto" name="datedueto" size="20" value="[% datedueto %]" />
<script language="JavaScript" type="text/javascript">
Calendar.setup(
{
);
</script>
</li>
+ </ol></fieldset>
+ <ol>
<li><label>Name or cardnumber:</label><input type="text" name="borname" value="[% borname |html %]" /></li>
<li><label>Patron category:</label><select name="borcat" id="borcat"><option value="">Any</option>
[% FOREACH borcatloo IN borcatloop %]
<!-- Patron has waiting holds -->
[% IF ( waiting_holds ) %]
- <div class="dialog alert">
- <h3>Patron has [% waiting_holds %] hold(s) waiting for pickup.</h3>
- <p><a href="/cgi-bin/koha/circ/circulation.pl?borrowernumber=[% holdsborrowernumber %]">Checkout holds</a>.</p>
+ <div class="dialog message">
+ <h3>[% holdsfirstname %] [% holdssurname %] has [% waiting_holds %] hold(s) waiting for pickup.</h3>
+ <p><a href="/cgi-bin/koha/circ/circulation.pl?borrowernumber=[% holdsborrowernumber %]">Check out to this patron</a>.</p>
</div>
[% END %]
</div>
</div>
<div class="yui-g">
- <form method="post" action="/cgi-bin/koha/circ/returns.pl" >
+ <form method="post" action="/cgi-bin/koha/circ/returns.pl" autocomplete="off" >
<div class="yui-u first">
<fieldset>
<legend>Check In</legend>
<a href="label-item-search.pl?startfrom=[% startfromprev %]&ccl_query=[% ccl_query %]&resultsperpage=[% resultsperpage %]&op=do_search&batch_id=[% batch_id %]"><<</a>
[% END %]
[% FOREACH number IN numbers %]
- <a href="label-item-search.pl?startfrom=[% number.startfrom %]&ccl_query=[% number.ccl_query %]&resultsperpage=[% number.resultsperpage %]&op=do_search&batch_id=[% number.batch_id %]">[% number.number %]</a>
+ <a href="label-item-search.pl?startfrom=[% number.startfrom %]&ccl_query=[% ccl_query %]&resultsperpage=[% resultsperpage %]&op=do_search&batch_id=[% batch_id %]">[% number.number %]</a>
[% END %]
[% IF ( displaynext ) %]
<a href="label-item-search.pl?startfrom=[% startfromnext %]&ccl_query=[% ccl_query %]&resultsperpage=[% resultsperpage %]&op=do_search&batch_id=[% batch_id %]">>></a>
</p>
[% END %]
</div>
- [% INCLUDE 'intranet-bottom.inc' %]
+ [% INCLUDE 'popup-bottom.inc' %]
<fieldset class="action"><input type="submit" value="Search" class="submit" /> <a class="cancel close" href="#">Cancel</a></fieldset>
</form>
</div>
-[% INCLUDE 'intranet-bottom.inc' %]
+</div>
+[% INCLUDE 'popup-bottom.inc' %]
<td>[% resultsloo.branchcode %]</td>
<td>[% resultsloo.dateexpiry %]</td>
<td>[% IF ( resultsloo.overdues ) %]<span class="overdue"><strong>[% resultsloo.overdues %]</strong></span>[% ELSE %][% resultsloo.overdues %][% END %]/[% resultsloo.issues %]</td>
- <td>[% resultsloo.fines %]</td>
+ <td>[% IF ( resultsloo.fines < 0 ) %]<span class="credit">[% resultsloo.fines %]</span> [% ELSIF resultsloo.fines > 0 %] <span class="debit"><strong>[% resultsloo.fines %]</strong></span> [% ELSE %] [% resultsloo.fines %] [% END %]</td>
<td>[% resultsloo.borrowernotes %]</td>
<td>[% IF ( resultsloo.category_type ) %]
<a href="/cgi-bin/koha/members/memberentry.pl?op=modify&destination=circ&borrowernumber=[% resultsloo.borrowernumber %]&category_type=[% resultsloo.category_type %]">Edit</a>
$("#guarantorsearch").val("Set to Patron");
});
$("#select_city").change(function(){
- var myRegEx=new RegExp(/(.*)\|(.*)/);
+ var myRegEx=new RegExp(/(.*)\|(.*)\|(.*)\|(.*)/);
document.form.select_city.value.match(myRegEx);
document.form.zipcode.value=RegExp.$1;
document.form.city.value=RegExp.$2;
+ document.form.state.value=RegExp.$3;
+ document.form.country.value=RegExp.$4;
});
});
<input type="hidden" name="borrowernumber" value="[% IF ( opduplicate ) %][% ELSE %][% borrowernumber %][% END %]" />
<input type="hidden" name="nodouble" value="[% IF ( opduplicate ) %][% ELSE %][% nodouble %][% END %]" />
[% IF ( step ) %]<input type="hidden" name="step" value="[% step %]" />[% END %]
-[% IF ( opadd ) %]<input type="hidden" name="op" value="insert" />[% ELSIF ( opduplicate ) %]<input type="hidden" name="op" value="insert" />[% ELSE %]<input type="hidden" name="op" value="save" />[% END %]
+[% IF ( opadd ) %]<input type="hidden" name="op" value="insert" />
+[% ELSIF ( opduplicate ) %]
+<input type="hidden" name="op" value="insert" />
+[% ELSE %]
+<input type="hidden" name="op" value="save" />
+[% IF step == 4 || step == 5 || step == 6 || step == 2 || step == 1 %]
+[%# Only put the cardnumber if we arent showing it in the form later %]
+[% IF cardnumber %]
+<input type="hidden" name="cardnumber" value="[% cardnumber %]">
+[% END %]
+[% END %]
+[% END %]
[% IF ( step_1 ) %]
<fieldset class="rows" id="memberentry_identity">
<select id="select_city" name="select_city">
[% FOREACH city_loo IN city_loop %]
[% IF ( city_loo.selected ) %]
- <option value="[% city_loo.city_zipcode %]|[% city_loo.city_name %]" selected="selected">
+ <option value="[% city_loo.city_zipcode %]|[% city_loo.city_name %]|[% city_loo.city_state %]|[% city_loo.city_country %]" selected="selected">
[% ELSE %]
- <option value="[% city_loo.city_zipcode %]|[% city_loo.city_name %]">
+ <option value="[% city_loo.city_zipcode %]|[% city_loo.city_name %]|[% city_loo.city_state %]|[% city_loo.city_country %]">
[% END %]
- [% city_loo.city_name %] [% city_loo.city_zipcode %]
+ [% city_loo.city_name %] [% city_loo.city_state %] [% city_loo.city_zipcode %]
</option>
[% END %]
</select>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="shortcut icon" href="[% IF ( IntranetFavicon ) %][% IntranetFavicon %][% ELSE %][% themelang %]/includes/favicon.ico[% END %]" type="image/x-icon" />
<link rel="stylesheet" type="text/css" href="[% themelang %]/css/print.css" />
+<script language="javascript">
+ function printThenClose() {
+ window.print();
+ window.close();
+ }
+</script>
+<body onload="printThenClose();">
+
</head>
<body>
</div>
<div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=3">Edit</a></div>
+ [% UNLESS ( I ) %]
<div id="patron-alternate-address" style="padding-top: 1em;">
<h3>Alternate Address</h3>
- [% UNLESS ( I ) %][% UNLESS ( C ) %]
<div class="rows"> <ol><li><span class="label">Address: </span>[% B_address %]</li>
<li><span class="label">Address 2: </span>[% B_address2 %]</li>
<li><span class="label">City: </span>[% B_city %]</li>
<li><span class="label">Country: </span>[% B_country %]</li>
[% IF ( B_phone ) %]<li><span class="label">Phone: </span>[% B_phone %]</li>[% END %]
[% IF ( B_email ) %]<li><span class="label">Email: </span>[% B_email %]</li>[% END %]</ol></div>
- [% END %][% END %]
- [% IF ( C ) %]
- <div class="rows"> <ol><li><span class="label">Surname: </span>[% contactname %]</li>
- <li><span class="label">First name: </span>[% contactfirstname %]</li>
- <li><span class="label">Phone: </span>[% phone %]</li>
- <li><span class="label">Email: </span>[% email %]</li>
- <li><span class="label">Relationship: </span>[% relationship %]</li></ol></div>
- [% END %]
</div>
<div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=6">Edit</a></div>
+ [% END %]
<div id="patron-alternative-contact" style="padding-top: 1em;">
<h3>Alternative Contact</h3>
<td>[% loop_pa.description %] [% loop_pa.title |html %]</td>
<td>
[% IF ( loop_pa.net_balance ) %]
- <input type="text" name="note[% loop_pa.i %]" value="
+ <input type="text" name="note[% loop_pa.i %]" value="[% loop_pa.note %]" />
+ [% ELSE %]
+ [% loop_pa.note %]
[% END %]
- [% loop_pa.note %]
- [% IF ( loop_pa.net_balance ) %]" />[% END %]
</td>
<td>[% loop_pa.accounttype %]</td>
<td>[% loop_pa.notify_id %]</td>
[% INCLUDE 'doc-head-open.inc' %]
<title>Koha › Choose Adult category</title>
[% INCLUDE 'doc-head-close.inc' %]
+<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.min.js"></script>
+<script type="text/javascript">
+ $(document).ready(function() {
+ $.tablesorter.defaults.widgets = ['zebra'];
+ $("#catst").tablesorter({
+ sortList: [[2,0]],
+ headers: { 0: { sorter: false }}
+ });
+ });
+</script>
<style type="text/css">
#custom-doc { width:29em;*width:28.3em;min-width:377px; margin:auto; text-align:left; }
</style>
<form method="post" action="update-child.pl">
<fieldset>
-<table>
+<table id="catst">
+<thead>
<tr>
<th> </th>
<th>Code</th>
<th>Description</th>
</tr>
+</thead>
+<tbody>
[% FOREACH CAT_LOO IN CAT_LOOP %]
<tr>
<td>
<td><label for="catcode[% CAT_LOO.catcode %]"><strong>[% CAT_LOO.catdesc %]</strong></label></td>
</tr>
[% END %]
+</tbody>
</table>
<input type="hidden" name="op" value="update" />
<input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
</div>
-[% INCLUDE 'intranet-bottom.inc' %]
+[% INCLUDE 'popup-bottom.inc' %]
[% END %]
<h1>Dictionary</h1>
[% IF ( start_dictionary ) %]
-<p>Use the dictionary to define custom criteria for reporting.</p>
+ <p>Use the dictionary to define custom criteria for reporting.</p>
-
-<h2>Current Terms</h2>
-<form action="/cgi-bin/koha/reports/dictionary.pl" method="post">
-<input type="hidden" name="phase" value="View Dictionary" />
-Filter by area <select name="areas">
-<option value="">All</option>
-[% FOREACH area IN areas %]
- [% IF ( area.selected ) %]
- <option value="[% area.id %]" selected="selected" >[% area.name %]</option>
- [% ELSE %]
- <option value="[% area.id %]">[% area.name %]</option>
- [% END %]
-[% END %]
-</select>
-<input name="submit" value="Go" type="submit" />
-</form>
-<br />
-<table border="1" cellspacing="0" cellpadding="5">
-<tr>
-<th>Name</th>
-<th>Description</th>
-<th>Area</th>
-<th>Definition</th>
-<th> </th>
-</tr>
-[% IF ( definitions ) %]
-[% FOREACH definition IN definitions %]
-[% UNLESS ( loop.odd ) %]
-<tr class="highlight" valign="top">
-[% ELSE %]
-<tr valign="top">
-[% END %]
-<td>[% definition.name %]</td>
-<td>[% definition.description %]</td>
-<td>[% definition.areaname %]</td>
-<td>[% definition.saved_sql %]</td>
-<td><form method="post" action="/cgi-bin/koha/reports/dictionary.pl">
-<input type="hidden" name="id" value="[% definition.id %]" />
-<input type="hidden" name="phase" value="Delete Definition" />
-<input type="submit" name="submit" value="Delete Definition" />
-</form></td>
-</tr>
-[% END %]
+ [% IF ( definitions ) %]
+ <h2>Current Terms</h2>
+ <form action="/cgi-bin/koha/reports/dictionary.pl" method="post">
+ <input type="hidden" name="phase" value="View Dictionary" />
+ [% IF ( areas ) %]
+ Filter by area <select name="areas">
+ <option value="">All</option>
+ [% FOREACH area IN areas %]
+ [% IF ( area.selected ) %]
+ <option value="[% area.id %]" selected="selected" >[% area.name %]</option>
+ [% ELSE %]
+ <option value="[% area.id %]">[% area.name %]</option>
+ [% END %]
+ [% END %]
+ </select>
+ <input name="submit" value="Go" type="submit" />
+ </form>
+ <br />
+ [% END %]
+ <table border="1" cellspacing="0" cellpadding="5">
+ <tr>
+ <th>Name</th>
+ <th>Description</th>
+ <th>Area</th>
+ <th>Definition</th>
+ <th> </th>
+ </tr>
+ [% FOREACH definition IN definitions %]
+ [% UNLESS ( loop.odd ) %]
+ <tr class="highlight" valign="top">
+ [% ELSE %]
+ <tr valign="top">
+ [% END %]
+ <td>[% definition.name %]</td>
+ <td>[% definition.description %]</td>
+ <td>[% definition.areaname %]</td>
+ <td>[% definition.saved_sql %]</td>
+ <td><form method="post" action="/cgi-bin/koha/reports/dictionary.pl">
+ <input type="hidden" name="id" value="[% definition.id %]" />
+ <input type="hidden" name="phase" value="Delete Definition" />
+ <input type="submit" name="submit" value="Delete Definition" />
+ </form></td>
+ </tr>
+ [% END %]
+ </table>
+ [% END %]
[% END %]
-</table>
-[% END %]
-
[% IF ( new_dictionary ) %]
<form action="/cgi-bin/koha/reports/dictionary.pl" method="post">
<script type="text/javascript">
Calendar.setup({
inputField : "[% column.name %]_start_value",
-ifFormat : "[% column.DHTMLcalendar_dateformat %]",
+ifFormat : "[% DHTMLcalendar_dateformat %]",
button : "buttonfrom1",
align : "Tl"
});
<script type="text/javascript">
Calendar.setup({
inputField : "[% column.name %]_end_value",
-ifFormat : "[% column.DHTMLcalendar_dateformat %]",
+ifFormat : "[% DHTMLcalendar_dateformat %]",
button : "buttonfrom2",
align : "Tl"
});
<script type="text/javascript">
Calendar.setup({
inputField : "[% criteri.name %]_value",
- ifFormat : "[% criteri.DHTMLcalendar_dateformat %]",
+ ifFormat : "[% DHTMLcalendar_dateformat %]",
button : "buttonfrom[% criteri.name %]",
align : "Tl"
});
<script type="text/javascript">
Calendar.setup({
inputField : "from_[% criteri.name %]_value",
- ifFormat : "[% criteri.DHTMLcalendar_dateformat %]",
+ ifFormat : "[% DHTMLcalendar_dateformat %]",
button : "buttonfromfrom_[% criteri.name %]",
align : "Tl"
});
<script type="text/javascript">
Calendar.setup({
inputField : "to_[% criteri.name %]_value",
- ifFormat : "[% criteri.DHTMLcalendar_dateformat %]",
+ ifFormat : "[% DHTMLcalendar_dateformat %]",
button : "buttonfromto_[% criteri.name %]",
align : "Tl"
});
[% IF ( definitions ) %]
<fieldset><legend>Dictionary Definitions</legend><table>
[% FOREACH definition IN definitions %]
- <tr><td><input type="checkbox" name="definition" value="[% id %]" /> [% definition.name %]</td></tr>
+ <tr><td><input type="checkbox" name="definition" value="[% definition.id %]" /> [% definition.name %]</td></tr>
[% END %]
</table>
[% END %]
<h1>Confirm Holds</h1>
[% END %]
- [% UNLESS ( cardnumber ) %]
+ [% UNLESS ( borrowernumber ) %]
[% IF ( messageborrower ) %]
<div class="dialog alert"><h3>Patron Not Found</h3><p>No patron with this name, Please, try another</p> </div>
[% END %]
<form action="placerequest.pl" method="post" onsubmit="return checkMultiHold();" name="form">
[% END %]
- <input type="hidden" size="10" name="member" value="[% cardnumber %]" />
+ <input type="hidden" size="10" name="borrowernumber" value="[% borrowernumber %]" />
<input type="hidden" name="type" value="str8" />
[% IF ( multi_hold ) %]
[% END %]
<ol> <li><span class="label">Patron:</span>
- [% IF ( cardnumber ) %]
+ [% IF ( borrowernumber ) %]
<a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% borrowernumber %]">[% borrowerfirstname %] [% borrowersurname %] ([% cardnumber %])</a>
[% ELSE %]
Not defined yet
</ol>
[% UNLESS ( multi_hold ) %]
<fieldset class="action">
- [% IF ( cardnumber ) %]
+ [% IF ( borrowernumber ) %]
[% IF ( override_required ) %]
<input type="submit" class="warning" value="Place Hold" />
[% ELSIF ( none_available ) %]
</table>
[% IF ( bibitemloo.hiddencount ) %]
<form>
- <p class="hiddencount"><a href="request.pl?biblionumber=[% bibitemloo.biblionumber %]&cardnumber=[% bibitemloo.cardnumber %]&showallitems=1">Show all items ([% bibitemloo.hiddencount %] hidden)</a></p>
+ <p class="hiddencount"><a href="request.pl?biblionumber=[% bibitemloo.biblionumber %]&borrowernumber=[% bibitemloo.borrowernumber %]&showallitems=1">Show all items ([% bibitemloo.hiddencount %] hidden)</a></p>
</form>
[% END %] <!-- hiddencount -->
[% END %] <!-- bibitemloop -->
[% END %]<!-- /multi_hold -->
<fieldset class="action">
- [% IF ( cardnumber ) %]
+ [% IF ( borrowernumber ) %]
[% IF ( override_required ) %]
<input type="submit" class="warning" value="Place Hold" />
[% ELSIF ( none_available ) %]
</fieldset>
[% END %]
-[% UNLESS ( cardnumber ) %]
+[% UNLESS ( borrowernumber ) %]
[% IF ( reserveloop ) %]
<form name="T[% time %]" action="modrequest.pl" method="post">
[% IF ( multi_hold ) %]
<td>
<a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% reserveloo.borrowernumber %]" >
[% IF ( reserveloo.hidename ) %]
- [% reserveloo.cardnumber %]
+ [% reserveloo.cardnumber (reserveloo.borrowernumber) %]
[% ELSE %]
[% reserveloo.firstname %] [% reserveloo.surname %]
[% END %]
[% INCLUDE 'doc-head-open.inc' %]
-[% INCLUDE 'calendar.inc' %]
<title>Koha › Serials › Claims</title>
[% INCLUDE 'doc-head-close.inc' %]
<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.min.js"></script>
//]]>
</script>
+[% INCLUDE 'calendar.inc' %]
</head>
<body>
[% INCLUDE 'header.inc' %]
</tr></thead>
<tbody>[% FOREACH missingissue IN missingissues %]
<tr>
- [% IF ( missingissue.letter ) %]
+ [% IF ( letter ) %]
<td>
<input type="checkbox" name="serialid" value="[% missingissue.serialid %]" />
</td>
<div class="yui-b">
<h1>Serial Edition <i>[% bibliotitle %]</i>
- i[% IF location %] ( [% location %] ) [% END %]
+ [% IF location %] ( [% location %] ) [% END %]
[% IF ( callnumber ) %] callnumber: [% callnumber %][% END %]</h1>
<form method="post" name="f" action="serials-edit.pl" id="serials_edit">
<!--onsubmit="return barcode_check()">-->
[% FOREACH item IN serialslis.items %]
<div id="item[% item.serialid %][% item.countitems %]" class="items">
<ol>[% FOREACH iteminformatio IN item.iteminformation %]<li>
- <div class="subfield_line" style="[% iteminformatio.hidden %];" id="subfield[% iteminformatio.serialid %][% iteminformatio.countitems %][% iteminformatio.subfield %][% iteminformatio.random %]">
+ <div class="subfield_line" style="[% iteminformatio.hidden %];" id="subfield[% item.serialid %][% item.countitems %][% iteminformatio.subfield %][% iteminformatio.random %]">
<label>[% iteminformatio.subfield %] - [% IF ( iteminformatio.mandatory ) %]<b>[% END %][% iteminformatio.marc_lib %][% IF ( iteminformatio.mandatory ) %] *</b>[% END %]</label>
[% iteminformatio.marc_value %]
- <input type="hidden" name="itemid" value="[% iteminformatio.itemid %]" />
+ <input type="hidden" name="itemid" value="[% item.itemid %]" />
<input type="hidden" name="kohafield" value="[% iteminformatio.kohafield %]" />
<input type="hidden" name="tag" value="[% iteminformatio.tag %]" />
<input type="hidden" name="subfield" value="[% iteminformatio.subfield %]" />
<input type="hidden" name="mandatory" value="[% iteminformatio.mandatory %]" />
[% IF ( iteminformatio.ITEM_SUBFIELDS_ARE_NOT_REPEATABLE ) %]
- <span class="buttonPlus" onclick="CloneSubfield('subfield[% iteminformatio.serialid %][% iteminformatio.countitems %][% iteminformatio.subfield %][% iteminformatio.random %]')">+</span>
+ <span class="buttonPlus" onclick="CloneSubfield('subfield[% item.serialid %][% item.countitems %][% iteminformatio.subfield %][% iteminformatio.random %]')">+</span>
[% END %]
</div></li>
<input type="hidden" name="biblionumber" value="[% newserialloo.biblionumber %]" />
<input type="hidden" name="itemcount" value="[% newserialloo.issuesatonce %]" />
<input type="hidden" name="user" value="[% newserialloo.librarian %]" />
- Supplemental Issue <input type="text" name="serialseq" value="" size="20" maxlength="100" onchange="if (this.value!=''){unHideItems('items[% newserialloo.subscriptionid %][% newserialloo.serialid %]','label[% newserialloo.subscriptionid %][% newserialloo.serialid %]', '[% newserialloo.serialid %]')} else {HideItems('items[% newserialloo.subscriptionid %][% newserialloo.serialid %]','label[% newserialloo.subscriptionid %][% newserialloo.serialid %]')}" />
+ Supplemental Issue <input type="text" name="serialseq" id="serialseq[% newserialloo.serialid %]" value="" size="20" maxlength="100" onchange="if (this.value!=''){unHideItems('items[% newserialloo.subscriptionid %][% newserialloo.serialid %]','label[% newserialloo.subscriptionid %][% newserialloo.serialid %]', '[% newserialloo.serialid %]')} else {HideItems('items[% newserialloo.subscriptionid %][% newserialloo.serialid %]','label[% newserialloo.subscriptionid %][% newserialloo.serialid %]')}" />
</td>
<td>
<input type="text" name="publisheddate" value="[% newserialloo.publisheddate %]" size="10" maxlength="15" />
<input type="text" name="planneddate" id="supexpecteddate" value="[% newserialloo.planneddate %]" size="10" maxlength="15" />
</td>
<td>
- <select name="status" size="1" id="addstatus[% newserialloo.serialid %]" onchange="if (this.value==2 || this.value==7){changeDate2('[% newserialloo.arriveddate %]')} else {changeDate2('[% newserialloo.planneddate %]')}" >
+ <select name="status" size="1" id="addstatus[% newserialloo.serialid %]" onchange="if (this.value==2){unHideItems('items'+'[% newserialloo.subscriptionid %][% newserialloo.serialid %]','label[% newserialloo.subscriptionid %][% newserialloo.serialid %]','[% newserialloo.serialid %]'); changeDate2('[% newserialloo.arriveddate %]')} else if (this.value==7){changeDate('[% newserialloo.arriveddate %]')} else { HideItems('items'+'[% newserialloo.subscriptionid %]'+[% newserialloo.serialid %],'label[% serialslis.subscriptionid %][% serialslis.serialid %]'); changeDate2('[% serialslis.planneddate %]')}" >
+
<option value="">----</option>
[% IF ( newserialloo.status1 ) %]
<option value="1" selected="selected">Expected</option>
<div class="cataloguing_additem_itemlist">
<div id="item[% newserialloo.serialid %][% newserialloo.countitems %]" class="items">
<ol>[% FOREACH iteminformatio IN newserialloo.iteminformation %]<li>
- <div class="subfield_line" style="[% iteminformatio.hidden %];" id="subfield[% iteminformatio.serialid %][% iteminformatio.countitems %][% iteminformatio.subfield %][% iteminformatio.random %]">
+ <div class="subfield_line" style="[% iteminformatio.hidden %];" id="subfield[% newserialloo.serialid %][% newserialloo.countitems %][% iteminformatio.subfield %][% iteminformatio.random %]">
<label>[% iteminformatio.subfield %] - [% IF ( iteminformatio.mandatory ) %]<b>[% END %][% iteminformatio.marc_lib %][% IF ( iteminformatio.mandatory ) %] *</b>[% END %]</label>
[% iteminformatio.marc_value %]
- <input type="hidden" name="itemid" value="[% iteminformatio.itemid %]" />
+ <input type="hidden" name="itemid" value="[% newserialloo.itemid %]" />
<input type="hidden" name="kohafield" value="[% iteminformatio.kohafield %]" />
<input type="hidden" name="tag" value="[% iteminformatio.tag %]" />
<input type="hidden" name="subfield" value="[% iteminformatio.subfield %]" />
<input type="hidden" name="mandatory" value="[% iteminformatio.mandatory %]" />
[% IF ( iteminformatio.ITEM_SUBFIELDS_ARE_NOT_REPEATABLE ) %]
- <span class="buttonPlus" onclick="CloneSubfield('subfield[% iteminformatio.serialid %][% iteminformatio.countitems %][% iteminformatio.subfield %][% iteminformatio.random %]')">+</span>
+ <span class="buttonPlus" onclick="CloneSubfield('subfield[% newserialloo.serialid %][% newserialloo.countitems %][% iteminformatio.subfield %][% iteminformatio.random %]')">+</span>
[% END %]
</div>
</li>[% END %]</ol>
[% IF ( subscription.branchcode ) %][% subscription.branchcode %][% END %]
[% IF ( subscription.callnumber ) %]([% subscription.callnumber %])[% END %]
</td>
- [% IF ( subscription.routing ) %]
+ [% IF ( routing ) %]
<td>
[% IF ( subscription.cannotedit ) %]
<script language="JavaScript" type="text/javascript">
//<![CDATA[
function popup() {
- window.open("subscription-renew.pl?subscriptionid=<!-- TMPL_VAR
-name="subscriptionid">","subscription_renewal",'width=700,height=400,toolbar=false,scrollbars=yes');
+ window.open("subscription-renew.pl?subscriptionid=[% subscriptionid %]","subscription_renewal",'width=700,height=400,toolbar=false,scrollbars=yes');
}
function barcode_check(){
[% INCLUDE 'doc-head-open.inc' %]
-<title>Koha › Serials › [% IF ( modname ) %][% bibliotitle |html %] › Modify subscription[% ELSE %]New subscription[% END %]</title>
+<title>Koha › Serials › [% IF ( modify ) %][% bibliotitle |html %] › Modify subscription[% ELSE %]New subscription[% END %]</title>
[% INCLUDE 'doc-head-close.inc' %]
[% INCLUDE 'calendar.inc' %]
}
);
// $(".widelabel").attr("width", "300px"); // labels stay skinny in IE7 anyway.
-[% IF ( modname ) %]
+[% IF ( modify ) %]
set_num_pattern_from_template_vars();
[% IF ( hemisphere ) %]
is_hemisphere = [% hemisphere %] ;
[% INCLUDE 'header.inc' %]
[% INCLUDE 'serials-search.inc' %]
-<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/serials/serials-home.pl">Serials</a> › [% IF ( modname ) %]<a href="/cgi-bin/koha/serials/subscription-detail.pl?subscriptionid=[% subscriptionid %]"><i>[% bibliotitle |html %]</i></a> › Modify subscription[% ELSE %]New subscription[% END %]</div>
+<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/serials/serials-home.pl">Serials</a> › [% IF ( modify ) %]<a href="/cgi-bin/koha/serials/subscription-detail.pl?subscriptionid=[% subscriptionid %]"><i>[% bibliotitle |html %]</i></a> › Modify subscription[% ELSE %]New subscription[% END %]</div>
<div id="doc3" class="yui-t7">
<div id="bd">
-<h1>[% IF ( modname ) %] Modify subscription for <i>[% bibliotitle |html %]</i>[% ELSE %]Add a new subscription[% END %]</h1>
+<h1>[% IF ( modify ) %] Modify subscription for <i>[% bibliotitle |html %]</i>[% ELSE %]Add a new subscription[% END %]</h1>
<div class="yui-g">
<form method="post" name="f" action="/cgi-bin/koha/serials/subscription-add.pl">
-[% IF ( modname ) %]
+[% IF ( modify ) %]
<input type="hidden" name="op" value="modsubscription" />
<input type="hidden" name="subscriptionid" value="[% subscriptionid %]" />
[% ELSE %]
(<input type="text" name="title" value="[% bibliotitle %]" disabled="disabled" readonly="readonly" />) <span class="required" title="Subscriptions must be associated with a bibliographic record">Required</span>
<div class="inputnote"> <a href="#" onclick="Plugin(f)">Search for Biblio</a>
[% IF ( CAN_user_editcatalogue ) %]
- [% IF ( modname ) %]
+ [% IF ( modify ) %]
| <a href="#" onclick="addbiblioPopup([% bibnum %]); return false;">Edit biblio</a>
[% ELSE %]
| <a href="#" onclick="addbiblioPopup(); return false;">Create Biblio</a>
<ol>
<li>
<label for="acqui_date"> First issue publication date:</label>
- [% UNLESS ( modname ) %]<img src="[% themelang %]/lib/calendar/cal.gif" id="acqui_button" style="cursor: pointer;" alt="Show Calendar" title="Show Calendar" />[% END %]
- <input type="text" name="firstacquidate" value="[% firstacquidate %]" size="13" maxlength="10" id="acqui_date" [% IF ( modname ) %]disabled="disabled"[% END %] style="border-width: 0px;" />
+ [% UNLESS ( modify ) %]<img src="[% themelang %]/lib/calendar/cal.gif" id="acqui_button" style="cursor: pointer;" alt="Show Calendar" title="Show Calendar" />[% END %]
+ <input type="text" name="firstacquidate" value="[% firstacquidate %]" size="13" maxlength="10" id="acqui_date" [% IF ( modify ) %]disabled="disabled"[% END %] style="border-width: 0px;" />
</li>
- [% IF ( modname ) %]<li><label for="next_acqui_date"> Next issue publication date:</label>
+ [% IF ( modify ) %]<li><label for="next_acqui_date"> Next issue publication date:</label>
<img src="[% themelang %]/lib/calendar/cal.gif" id="next_acqui_button" style="cursor: pointer;" alt="Show Calendar" title="Show Calendar" />
<input type="text" name="nextacquidate" value="[% nextacquidate %]" size="13" maxlength="10" id="next_acqui_date" style="border-width: 0px;" />
</li>[% END %]
<li><!-- both scripts for calendar must follow the input field -->
<script type="text/javascript">
Calendar.setup({
- inputField : "[% IF ( modname ) %]next_[% END %]acqui_date",
+ inputField : "[% IF ( modify ) %]next_[% END %]acqui_date",
ifFormat : "[% DHTMLcalendar_dateformat %]",
- button : "[% IF ( modname ) %]next_[% END %]acqui_button",
+ button : "[% IF ( modify ) %]next_[% END %]acqui_button",
align : "Tl",
onUpdate : function(cal) {
irregular_issues.weeks = getWeeksArray(cal.date);
}
});
Calendar.setup({
- inputField : "[% IF ( modname ) %]next_[% END %]acqui_date",
+ inputField : "[% IF ( modify ) %]next_[% END %]acqui_date",
ifFormat : "[% DHTMLcalendar_dateformat %]",
- button : "[% IF ( modname ) %]next_[% END %]acqui_date",
+ button : "[% IF ( modify ) %]next_[% END %]acqui_date",
align : "Tl",
onUpdate : function(cal) { irregular_issues.weeks = getWeeksArray(cal.date);
irregular_issues.firstissue = cal.date;
</tr>
<tr>
<td>
- [% IF ( modname ) %]
+ [% IF ( modify ) %]
Last value
[% ELSE %]
Begins with
<div id="suggestiontabs" class="toptabs">
<ul class="ui-tabs-nav">
[% FOREACH suggestion IN suggestions %]
-[% IF ( suggestion.first ) %]<li class="ui-tabs-selected">[% ELSE %]<li>[% END %]<a href="suggestion.pl#[% suggestion.suggestiontype %]">[% IF ( suggestion.suggestiontypelabel ) %][% suggestion.suggestiontypelabel %][% ELSE %]No name[% END %] ([% suggestion.suggestionscount %])</a></li>
+[% IF ( suggestion.first ) %]<li class="ui-tabs-selected">[% ELSE %]<li>[% END %]<a href="suggestion.pl#[% suggestion.suggestiontype %]">[% IF ( suggestion.suggestiontypelabel ) %]
+ [% IF (suggestion.suggestiontypelabel == "Pending") %]Pending
+ [% ELSIF (suggestion.suggestiontypelabel == "Accepted") %]Accepted
+ [% ELSIF (suggestion.suggestiontypelabel == "Checked") %]Checked
+ [% ELSIF (suggestion.suggestiontypelabel == "Rejected") %]Rejected
+ [% ELSIF (suggestion.suggestiontypelabel == "Available") %]Available
+ [% ELSIF (suggestion.suggestiontypelabel == "Ordered") %]Ordered[% ELSE %]
+ [% suggestion.suggestiontypelabel %][% END %]
+ [% ELSE %]No name[% END %] ([% suggestion.suggestionscount %])</a></li>
[% END %]
</ul>
</div>
</tr>
[% FOREACH tagloo IN tagloop %]
<tr>
- <td class="count">[% offset + __counter__ %]
+ <td class="count">[% offset + loop.count %]
</td>
<td><span><input type="checkbox" value="[% tagloo.term %]" name="tags" [% IF ( approved == 0 ) %] class="pending"[% END %] /></span>
</td>
- [% IF ( approved == -1 ) %]<td class="red">rejected
- [% ELSIF ( approved == 1 ) %]<td class="green"><img alt="OK" src="/intranet-tmpl/prog/img/approve.gif" />
+ [% IF ( tagloo.approved == -1 ) %]<td class="red">rejected
+ [% ELSIF ( tagloo.approved == 1 ) %]<td class="green"><img alt="OK" src="/intranet-tmpl/prog/img/approve.gif" />
[% ELSE %]<td class="pending">
[% END %]
</td>
// Prepare array of all column headers, incrementing each index by
// two to accomodate control and title columns
var allColumns = new Array([% FOREACH item_header_loo IN item_header_loop %]'[% loop.count %]'[% UNLESS ( loop.last ) %],[% END %][% END %]);
+console.log(allColumns);
for( x=0; x<allColumns.length; x++ ){
allColumns[x] = Number(allColumns[x]) + 2;
}
<p id="selections"><strong>Show/hide columns:</strong> <span class="selected"><input type="checkbox" checked="checked" id="showall"/><label for="showall">Show all columns</label></span> <span><input type="checkbox" id="hideall"/><label for="hideall">Hide all columns</label></span>
[% FOREACH item_header_loo IN item_header_loop %]
- <span class="selected"><input id="checkheader[% item_header_loo.__counter %]" type="checkbox" checked="checked" /> <label for="checkheader[% loop.count %]">[% item_header_loo.header_value %]</label> </span>
+ <span class="selected"><input id="checkheader[% loop.count %]" type="checkbox" checked="checked" /> <label for="checkheader[% loop.count %]">[% item_header_loo.header_value %]</label> </span>
[% END %]
</p>
// Prepare array of all column headers, incrementing each index by
// two to accomodate control and title columns
var allColumns = new Array([% FOREACH item_header_loo IN item_header_loop %]'[% loop.count %]'[% UNLESS ( loop.last ) %],[% END %][% END %]);
+console.log(allColumns);
for( x=0; x<allColumns.length; x++ ){
allColumns[x] = Number(allColumns[x]) + 2;
}
<p id="selections"><strong>Show/hide columns:</strong> <span class="selected"><input type="checkbox" checked="checked" id="showall"/><label for="showall">Show all columns</label></span> <span><input type="checkbox" id="hideall"/><label for="hideall">Hide all columns</label></span>
[% FOREACH item_header_loo IN item_header_loop %]
- <span class="selected"><input id="checkheader[% item_header_loo.__counter %]" type="checkbox" checked="checked" /> <label for="checkheader[% loop.count %]">[% item_header_loo.header_value %]</label> </span>
+ <span class="selected"><input id="checkheader[% loop.count %]" type="checkbox" checked="checked" /> <label for="checkheader[% loop.count %]">[% item_header_loo.header_value %]</label> </span>
[% END %]
</p>
<table id="itemst">
$("#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"));
+ $("#holtype").attr("class","key repeatableweekly").html(_("Holiday repeating weekly"));
+ } else if(holidayType == 'daymonth') {
+ $("#showOperationDelLabel").html(_('Delete this holiday.'));
+ $("#holtype").attr("class","key repeatableyearly").html(_("Holiday repeating yearly"));
} else {
$("#showOperationDelLabel").html(_('Delete this holiday.'));
$("#holtype").attr("class","key holiday").html(_("Unique holiday"));
.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; }
+.repeatableweekly { background-color : #FFFF99; color : Black; border : 1px solid #BCBCBC; }
+.repeatableyearly { background-color : #FFCC66; 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; 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; }
var dateString = year + '/' + month + '/' + day;
if (exception_holidays[dateString] != null) {
return 'exception';
- } else if ((week_days[weekDay] != null) || (day_month_holidays[dayMonth] != null)) {
- return 'repeatableday';
+ } else if ( week_days[weekDay] != null ){
+ return 'repeatableweekly';
+ } else if ( day_month_holidays[dayMonth] != null ) {
+ return 'repeatableyearly';
} else if (holidays[dateString] != null) {
return 'holiday';
} else {
<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 repeatableweekly">Holiday repeating weekly</span>
+ <span class="key repeatableyearly">Holiday repeating yearly</span>
<span class="key exception">Holiday exception</span>
</p>
</div>
<table id="holidayweeklyrepeatable">
<thead>
<tr>
- <th class="repeatableday">Day of Week</th>
- <th class="repeatableday">Title</th>
- <th class="repeatableday">Description</th>
+ <th class="repeatableweekly">Day of Week</th>
+ <th class="repeatableweekly">Title</th>
+ <th class="repeatableweekly">Description</th>
</tr>
</thead>
<tbody>
<thead>
<tr>
[% IF ( dateformat == 'metric' ) %]
- <th class="repeatableday">Day/Month</th>
+ <th class="repeatableyearly">Day/Month</th>
[% ELSE %]
- <th class="repeatableday">Month/Day</th>
+ <th class="repeatableyearly">Month/Day</th>
[% END %]
- <th class="repeatableday">Title</th>
- <th class="repeatableday">Description</th>
+ <th class="repeatableyearly">Title</th>
+ <th class="repeatableyearly">Description</th>
</tr>
</thead>
<tbody>
[% INCLUDE 'doc-head-open.inc' %]
-<title>Koha › [% IF ( viewshelf ) %]Lists › Contents of [% shelfname %][% ELSE %]Lists[% END %][% IF ( shelves ) %] › Create New List[% END %][% IF ( edit ) %] › Edit List [% shelfname %][% END %]</title>
+<title>Koha › [% IF ( viewshelf ) %]Lists › Contents of [% shelfname | html %][% ELSE %]Lists[% END %][% IF ( shelves ) %] › Create New List[% END %][% IF ( edit ) %] › Edit List [% shelfname | html %][% END %]</title>
[% INCLUDE 'doc-head-close.inc' %]
<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.checkboxes.min.js"></script>
<script type="text/javascript">
[% INCLUDE 'cat-search.inc' %]
<div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/virtualshelves/shelves.pl">Lists</a>
-[% IF ( viewshelf ) %]› Contents of <i>[% shelfname %]</i>[% END %][% IF ( shelves ) %] › Create New List[% END %][% IF ( edit ) %] › Edit List <i>[% shelfname %]</i>[% END %]</div>
+[% IF ( viewshelf ) %]› Contents of <i>[% shelfname | html %]</i>[% END %][% IF ( shelves ) %] › Create New List[% END %][% IF ( edit ) %] › Edit List <i>[% shelfname | html %]</i>[% END %]</div>
<div id="doc" class="yui-t7">
<div id="bd">
<input type="hidden" name="viewshelf" value="[% shelfnumber %]" />
<input type="hidden" name="modifyshelfcontents" value="1" />
<fieldset>
- <legend>Contents of <i>[% shelfname %]</i></legend>
+ <legend>Contents of <i>[% shelfname | html %]</i></legend>
[% IF ( manageshelf ) %]
<p><span class="checkall"></span> |
<div class="yui-g">
<form action="/cgi-bin/koha/virtualshelves/shelves.pl" method="post">
<fieldset class="brief">
- <legend>Add an item to <i>[% shelfname %]</i></legend>
+ <legend>Add an item to <i>[% shelfname | html %]</i></legend>
<ol>
<li>
<label for="addbarcode">Barcode:</label>
[% END %]<!-- /manageshelf -->
[% IF ( debug ) %]
- [% IF ( edit ) %]<div>Edit is on ([% shelfname %])</div>[% END %]
+ [% IF ( edit ) %]<div>Edit is on ([% shelfname | html %])</div>[% END %]
[% IF ( seflag ) %]<div>seflag is on ([% seflag %])</div>[% END %]
[% END %]
<input type="hidden" name="op" value="modifsave" />
[% IF ( showprivateshelves ) %]<input type="hidden" name="display" value="privateshelves" />[% END %]
<input type="hidden" name="shelfnumber" value="[% shelfnumber %]" />
- <legend>Edit List <i>[% shelfname %]</i></legend>
+ <legend>Edit List <i>[% shelfname | html %]</i></legend>
<ol>
<li><label for="shelfname">Name: </label><input type="text" id="shelfname" name="shelfname" size="25" value='[% shelfname |html %]' /></li>
<li><label for="owner">Owner: </label><input type="hidden" id="owner" name="owner" value="[% IF ( owner ) %][% ownername %][% ELSE %][% loggedinusername %][% END %]" />[% IF ( owner ) %][% ownername %][% ELSE %][% loggedinusername %][% END %]</li>
#comments .yours {
background-color : #effed5;
}
+.commentline .avatar {
+ float : right;
+ padding-left : .5em;
+}
#comments #addcomment {
margin : 0 -1em -1em -1em;
padding : .3em 1em;
var NO_GOOGLE_JACKET = _("No cover image available");
//]]>
</script>
-[% END %][% IF ( BakerTaylorEnabled ) %]<script type="text/javascript" language="javascript" src="[% themelang %]/js/bakertaylorimages.js"></script>
+[% END %]
+[% IF OpenLibraryCovers %]
+<script type="text/javascript" language="javascript" src="[% themelang %]/js/openlibrary.js"></script>
+<script type="text/javascript" language="javascript">
+//<![CDATA[
+var NO_OL_JACKET = _("No cover image available");
+//]]>
+</script>
+[% END %]
+
+[% IF ( BakerTaylorEnabled ) %]<script type="text/javascript" language="javascript" src="[% themelang %]/js/bakertaylorimages.js"></script>
<script type="text/javascript" language="javascript">
//<![CDATA[
var NO_BAKERTAYLOR_IMAGE = _("No cover image available");
[% IF ( facets_loop ) %]
<div id="search-facets">
<h4>Refine your search</h4>
-[% query_cgi %]
<ul>
<li>Availability<ul><li>[% IF ( available ) %]Showing only <strong>available</strong> items. <a href="/cgi-bin/koha/opac-search.pl?[% query_cgi |html %][% limit_cgi_not_availablity %][% IF ( sort_by ) %]&sort_by=[% sort_by %][% END %]">Show all items</a>[% ELSE %]Limit to <a href="/cgi-bin/koha/opac-search.pl?[% query_cgi |html %][% limit_cgi |html %][% IF ( sort_by ) %]&sort_by=[% sort_by %][% END %]&limit=available">currently available items.</a>[% END %]</li></ul>
[% IF ( related ) %] <li>(related searches: [% FOREACH relate IN related %][% relate.related_search %][% END %])</li>[% END %]
[% IF ( facets_loo.type_label_Topics ) %]Topics[% END %]
[% IF ( facets_loo.type_label_Places ) %]Places[% END %]
[% IF ( facets_loo.type_label_Series ) %]Series[% END %]
-[% UNLESS ( facets_loo.singleBranchMode ) %]
+[% UNLESS ( singleBranchMode ) %]
[% IF ( facets_loo.type_label_Libraries ) %]Libraries[% END %]
[% END %]
<ul>
--- /dev/null
+if (typeof KOHA == "undefined" || !KOHA) {
+ var KOHA = {};
+}
+
+/**
+ * A namespace for OpenLibrary related functions.
+ */
+KOHA.OpenLibrary = {
+
+
+ /**
+ * Search all:
+ * <div title="biblionumber" id="isbn" class="openlibrary-thumbnail"></div>
+ * or
+ * <div title="biblionumber" id="isbn" class="openlibrary-thumbnail-preview"></div>
+ * and run a search with all collected isbns to Open Library Book Search.
+ * The result is asynchronously returned by OpenLibrary and catched by
+ * olCallBack().
+ */
+ GetCoverFromIsbn: function() {
+ var bibkeys = [];
+ $("div [id^=openlibrary-thumbnail]").each(function(i) {
+ bibkeys.push("ISBN:" + $(this).attr("class")); // id=isbn
+ });
+ bibkeys = bibkeys.join(',');
+ var scriptElement = document.createElement("script");
+ scriptElement.setAttribute("id", "jsonScript");
+ scriptElement.setAttribute("src",
+ "http://openlibrary.org/api/books?bibkeys=" + escape(bibkeys) +
+ "&callback=KOHA.OpenLibrary.olCallBack");
+ scriptElement.setAttribute("type", "text/javascript");
+ document.documentElement.firstChild.appendChild(scriptElement);
+
+ },
+
+ /**
+ * Add cover pages <div
+ * and link to preview if div id is gbs-thumbnail-preview
+ */
+ olCallBack: function(booksInfo) {
+ for (id in booksInfo) {
+ var book = booksInfo[id];
+ var isbn = book.bib_key.substring(5);
+
+ $("."+isbn).each(function() {
+ var a = document.createElement("a");
+ a.href = book.info_url;
+ if (typeof(book.thumbnail_url) != "undefined") {
+ var img = document.createElement("img");
+ img.src = book.thumbnail_url;
+ $(this).append(img);
+ var re = /^openlibrary-thumbnail-preview/;
+ if ( re.exec($(this).attr("id")) ) {
+ $(this).append(
+ '<div style="margin-bottom:5px; margin-top:-5px;font-size:9px">' +
+ '<a href="' +
+ book.info_url +
+ '">Preview</a></div>'
+ );
+ }
+ } else {
+ var message = document.createElement("span");
+ $(message).attr("class","no-image");
+ $(message).html(NO_OL_JACKET);
+ $(this).append(message);
+ }
+ });
+ }
+ }
+};
--- /dev/null
+(function($){$.extend({metadata:{defaults:{type:'class',name:'metadata',cre:/({.*})/,single:'metadata'},setType:function(type,name){this.defaults.type=type;this.defaults.name=name;},get:function(elem,opts){var settings=$.extend({},this.defaults,opts);if(!settings.single.length)settings.single='metadata';var data=$.data(elem,settings.single);if(data)return data;data="{}";var getData=function(data){if(typeof data!="string")return data;if(data.indexOf('{')<0){data=eval("("+data+")");}}
+var getObject=function(data){if(typeof data!="string")return data;data=eval("("+data+")");return data;}
+if(settings.type=="html5"){var object={};$(elem.attributes).each(function(){var name=this.nodeName;if(name.match(/^data-/))name=name.replace(/^data-/,'');else return true;object[name]=getObject(this.nodeValue);});}else{if(settings.type=="class"){var m=settings.cre.exec(elem.className);if(m)
+data=m[1];}else if(settings.type=="elem"){if(!elem.getElementsByTagName)returnvar;e=elem.getElementsByTagName(settings.name);if(e.length)
+data=$.trim(e[0].innerHTML);}else if(elem.getAttribute!=undefined){var attr=elem.getAttribute(settings.name);if(attr)
+data=attr;}
+object=getObject(data.indexOf("{")<0?"{"+data+"}":data);}
+$.data(elem,settings.single,object);return object;}}});$.fn.metadata=function(opts){return $.metadata.get(this[0],opts);};})(jQuery);
\ No newline at end of file
<biblioitemnumber>1</biblioitemnumber>
<isbn>9782862749198</isbn>
<marcxml>
+ <?xml version="1.0" encoding="UTF-8" ?>
<record
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.loc.gov/MARC21/slim http://www.loc.gov/ standards/marcxml/schema/MARC21slim.xsd"
<biblioitemnumber>2</biblioitemnumber>
<isbn>9782265078031</isbn>
<marcxml>
+ <?xml version="1.0" encoding="UTF-8" ?>
<record
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.loc.gov/MARC21/slim http://www.loc.gov/ standards/marcxml/schema/MARC21slim.xsd"
ilsdi.pl?service=GetAuthorityRecords&id=1+2+99999
</a>
<h4>Example Response</h4>
-<pre><?xml version="1.0" encoding="ISO-8859-1" ?>
+<pre><xml version="1.0" encoding="UTF-8">;
<GetAuthorityRecords>
+ <record>
+ <?xml version="1.0" encoding="UTF-8"?>
<record
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.loc.gov/MARC21/slim http://www.loc.gov/ standards/marcxml/schema/MARC21slim.xsd"
xmlns="http://www.loc.gov/MARC21/slim">
- <leader>00126nx j2200073 4500 </leader>
+ <leader>00182 2200085 4500</leader>
<controlfield tag="001">1</controlfield>
- <datafield tag="250" ind1=" " ind2=" ">
- <subfield code="a">TECHNIQUE</subfield>
+ <datafield tag="200" ind1=" " ind2=" ">
+ <subfield code="a">Hugo</subfield>
+ <subfield code="b">Victor</subfield>
</datafield>
- <datafield tag="100" ind1=" " ind2=" ">
- <subfield code="a">20071210afrey50 ba0</subfield>
- </datafield>
- <datafield tag="152" ind1=" " ind2=" ">
- <subfield code="b">NC</subfield>
- </datafield>
- </record>
- <record
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://www.loc.gov/MARC21/slim http://www.loc.gov/ standards/marcxml/schema/MARC21slim.xsd"
- xmlns="http://www.loc.gov/MARC21/slim">
- <leader>00130nx j2200073 4500 </leader>
- <controlfield tag="001">2</controlfield>
- <datafield tag="250" ind1=" " ind2=" ">
- <subfield code="a">CHEMIN DE FER</subfield>
+ <datafield tag="801" ind1=" " ind2=" ">
+ <subfield code="a">France</subfield>
+ <subfield code="b">Nimes</subfield>
+ <subfield code="c">2010/04/13</subfield>
</datafield>
<datafield tag="100" ind1=" " ind2=" ">
- <subfield code="a">20071210afrey50 ba0</subfield>
+ <subfield code="a">20100413 50 </subfield>
</datafield>
<datafield tag="152" ind1=" " ind2=" ">
- <subfield code="b">NC</subfield>
+ <subfield code="b">NP</subfield>
</datafield>
</record>
- <record>RecordNotFound</record>
+ </record>
+ <record>
+ <code>RecordNotFound</code>
+ </record>
+ <record>
+ <code>RecordNotFound</code>
+ </record>
</GetAuthorityRecords></pre>
[% ELSIF ( LookupPatron ) %]
[% END %]
[% END %]
[% END %]
- <li><a class="print" href="javascript:window.print();">Print</a></li>
+ <li><a class="print" href="#" onclick="window.print();">Print</a></li>
[% IF ( virtualshelves ) %]
[% IF ( opacuserlogin ) %] [% IF ( loggedinusername ) %]
<li><a class="addtoshelf" href="/cgi-bin/koha/opac-addbybiblionumber.pl?biblionumber=[% biblionumber %]" onclick="Dopop('opac-addbybiblionumber.pl?biblionumber=[% biblionumber %]'); return false;">
[% END %]
[% END %]
[% END %]
- <li><a class="print" href="/cgi-bin/koha/opac-detailprint.pl?biblionumber=[% biblionumber %]" onclick="Dopop('opac-detailprint.pl?biblionumber=[% biblionumber %]'); return false;">
+ <li><a class="print" href="#" onclick="window.print();">
Print
</a></li>
[% IF ( virtualshelves ) %]
<option value="1">Private</option>
<option value="2">Public</option>
</select></li></ol></fieldset>
- [% FOREACH biblio IN biblios %] <input type="hidden" name="biblionumber" value="[% biblio.biblionumber %]" />[% END %]
+ [% FOREACH biblio IN biblios %] <input type="hidden" name="biblionumber" value="[% biblio.biblionumber | html%]" />[% END %]
<fieldset class="action"><input type="submit" value="Save" class="submit" /> <a class="close cancel" href="#">Cancel</a></fieldset>
</form>
[% END %]
<td>[% resul.summary %]</td>
<td>
- [% resul.authtypetext %]
+ [% authtypetext %]
</td>
[% UNLESS ( resul.isEDITORS ) %]
<td>
dateFormat: 'uk',[% END %]
widgets : ['zebra'],
sortList: [[0,0]]
- });[% IF ( GoogleJackets ) %]
- KOHA.Google.GetCoverFromIsbn([% covernewwindow %]);[% END %][% IF ( opacuserlogin ) %][% IF ( loggedinusername ) %][% IF ( TagsEnabled ) %]
+ });
+ [% IF ( GoogleJackets ) %]
+ KOHA.Google.GetCoverFromIsbn([% covernewwindow %]);
+ [% END %]
+ [% IF OpenLibraryCovers %]
+ KOHA.OpenLibrary.GetCoverFromIsbn();
+ [% END %]
+ [% IF ( opacuserlogin ) %][% IF ( loggedinusername ) %][% IF ( TagsEnabled ) %]
$(".tagbutton").click(KOHA.Tags.add_tag_button);[% END %][% END %][% END %]
});
[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %][% END %]
[% IF ( GoogleJackets ) %]<div style="block" title="[% biblionumber |url %]" class="[% normalized_isbn %]" id="gbs-thumbnail-preview"></div>[% END %]
- [% IF ( BakerTaylorEnabled ) %][% IF ( normalized_isbn ) %][% IF ( OPACurlOpenInNewWindow ) %]<a href="https://[% BakerTaylorBookstoreurl |html %][% normalized_isbn %]" target="_blank"><img alt="See Baker & Taylor" src="[% BakerTaylorImageurl |html %][% normalized_isbn %]" /></a>[% ELSE %]<a href="https://[% BakerTaylorBookstoreurl |html %][% normalized_isbn %]"><img alt="See Baker & Taylor" src="[% BakerTaylorImageurl |html %][% normalized_isbn %]" /></a>[% END %][% END %][% END %]
+ [% IF OpenLibraryCovers %]<div style="block" title="[% biblionumber |url %]" class="[% normalized_isbn %]" id="openlibrary-thumbnail-preview"></div>[% END %]
+ [% IF ( BakerTaylorEnabled ) %][% IF ( normalized_isbn ) %][% IF ( OPACurlOpenInNewWindow ) %]<a href="https://[% BakerTaylorBookstoreURL |html %][% normalized_isbn %]" target="_blank"><img alt="See Baker & Taylor" src="[% BakerTaylorImageURL |html %][% normalized_isbn %]" /></a>[% ELSE %]<a href="https://[% BakerTaylorBookstoreURL |html %][% normalized_isbn %]"><img alt="See Baker & Taylor" src="[% BakerTaylorImageURL |html %][% normalized_isbn %]" /></a>[% END %][% END %][% END %]
</div>
<abbr class="unapi-id" title="koha:biblionumber:[% biblionumber %]"><!-- unAPI --></abbr>
[% END %]
</span>[% END %]
- [% IF ( MARCurlS ) %]
+ [% IF ( MARCURLS ) %]
<div class="results_summary"><span class="label">Online Resources:</span>
- <ul> [% FOREACH MARCurl IN MARCurlS %]
+ <ul> [% FOREACH MARCurl IN MARCURLS %]
<li>[% IF ( MARCurl.part ) %][% MARCurl.part %]
<br />[% END %]
<!-- here you might do a tmpl_if name="toc" and use greybox or equivalent for table of contents -->
- [% IF ( MARCurl.OPACurlOpenInNewWindow ) %]<a href="[% MARCurl.MARCurl %]" title="[% MARCurl.MARCurl %]" target="_blank">[% ELSE %]<a href="[% MARCurl.MARCurl %]" title="[% MARCurl.MARCurl %]">[% END %]
+ [% IF ( MARCurl.OPACurlOpenInNewWindow ) %]<a href="[% MARCurl.MARCURL %]" title="[% MARCurl.MARCURL %]" target="_blank">[% ELSE %]<a href="[% MARCurl.MARCURL %]" title="[% MARCurl.MARCURL %]">[% END %]
[% MARCurl.linktext %]</a>
[% IF ( MARCurl.notes ) %]<ul>[% FOREACH note IN MARCurl.notes %]<li>[% note.note %]</li>[% END %]</ul>[% END %]</li>
[% FOREACH review IN reviews %]
[% IF ( review.your_comment ) %]
<div class="commentline yours" id="c[% review.reviewid %]">
+ [% IF ( review.avatarurl ) %]
+ <img class="avatar" src="[% review.avatarurl %]" height="80" width="80"/>
+ [% END %]
<h5>
Your Comment
</h5>
[% ELSE %]
<div class="commentline">
[% IF ( ShowReviewer ) %]
+ [% IF ( review.avatarurl ) %]
+ <img class="avatar" src="[% review.avatarurl %]" height="80" width="80"/>
+ [% END %]
<h5>
Comment by
[% review.title %]
[% END %]
[% END %]
[% END %]
- <li><a class="print" href="javascript:window.print();">Print</a></li>
+ <li><a class="print" href="#" onclick="window.print();">Print</a></li>
[% IF ( virtualshelves ) %]
[% IF ( opacuserlogin ) %][% IF ( loggedinusername ) %]
<li><a class="addtoshelf" href="/cgi-bin/koha/opac-addbybiblionumber.pl?biblionumber=[% biblionumber %]" onclick="Dopop('opac-addbybiblionumber.pl?biblionumber=[% biblionumber %]'); return false;">
</select></li></ol>
</fieldset>
<fieldset class="action">
- <input type="hidden" name="bib_list" value="[% bib_list %]" />
+ <input type="hidden" name="bib_list" value="[% bib_list | html %]" />
<input type="submit" name="save" value="Go" />
</fieldset>
</form>
</select></li></ol>
</fieldset>
- <fieldset class="action"> <input type="hidden" name="shelfid" value="[% shelfid %]" />
+ <fieldset class="action"> <input type="hidden" name="shelfid" value="[% shelfid | html %]" />
<input type="submit" name="save" value="Go" /></fieldset>
</form>
<img src="http://www.syndetics.com/index.aspx?isbn=[% SEARCH_RESULT.normalized_isbn %]/SC.GIF&client=[% SEARCH_RESULT.SyndeticsClientCode %]&type=xw10&upc=[% SEARCH_RESULT.normalized_upc %]&oclc=[% SEARCH_RESULT.normalized_oclc %]" alt="" />
[% END %][% END %][% END %][% END %]
-[% IF ( BakerTaylorEnabled ) %][% IF ( SEARCH_RESULT.normalized_isbn ) %]<a href="https://[% SEARCH_RESULT.BakerTaylorBookstoreurl |html %][% SEARCH_RESULT.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% SEARCH_RESULT.BakerTaylorImageurl |html %][% SEARCH_RESULT.normalized_isbn %]" /></a>[% END %][% END %]
+[% IF ( BakerTaylorEnabled ) %][% IF ( SEARCH_RESULT.normalized_isbn ) %]<a href="https://[% BakerTaylorBookstoreURL |html %][% SEARCH_RESULT.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% BakerTaylorImageURL |html %][% SEARCH_RESULT.normalized_isbn %]" /></a>[% END %][% END %]
<p>[% IF ( SEARCH_RESULT.author ) %]By [% SEARCH_RESULT.author |html %]. [% END %]
[% IF ( SEARCH_RESULT.place ) %][% SEARCH_RESULT.place |html %] [% END %][% IF ( SEARCH_RESULT.publishercode ) %][% SEARCH_RESULT.publishercode |html %][% END %][% IF ( SEARCH_RESULT.publicationyear ) %] [% SEARCH_RESULT.publicationyear |html %]
[% ELSE %][% IF ( SEARCH_RESULT.copyrightdate ) %] [% SEARCH_RESULT.copyrightdate |html %][% END %][% END %]
[% INCLUDE 'doc-head-open.inc' %][% IF ( LibraryNameTitle ) %][% LibraryNameTitle %][% ELSE %]Koha Online[% END %] Catalog › Privacy management for [% firstname %] [% surname %]
[% INCLUDE 'doc-head-close.inc' %]
</head>
-<body>
+<body id="opac-privacy">
<div id="doc3" class="yui-t1">
<div id="bd">
[% INCLUDE 'masthead.inc' %]
[% IF ( GoogleJackets ) %][% IF ( READING_RECOR.normalized_isbn ) %]<div style="block" title="[% READING_RECOR.biblionumber |url %]" class="[% READING_RECOR.normalized_isbn %]" id="gbs-thumbnail[% loop.count %]"></div>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
- [% IF ( BakerTaylorEnabled ) %][% IF ( READING_RECOR.normalized_isbn ) %]<a href="https://[% READING_RECOR.BakerTaylorBookstoreurl |html %][% READING_RECOR.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% READING_RECOR.BakerTaylorImageurl |html %][% READING_RECOR.normalized_isbn %]" /></a>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
+ [% IF ( BakerTaylorEnabled ) %][% IF ( READING_RECOR.normalized_isbn ) %]<a href="https://[% BakerTaylorBookstoreURL |html %][% READING_RECOR.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% BakerTaylorImageURL |html %][% READING_RECOR.normalized_isbn %]" /></a>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
[% IF ( SyndeticsEnabled ) %][% IF ( SyndeticsCoverImages ) %][% IF ( using_https ) %]
<img src="https://secure.syndetics.com/index.aspx?isbn=[% READING_RECOR.normalized_isbn %]/SC.GIF&client=[% READING_RECOR.SyndeticsClientCode %]&type=xw10&upc=[% READING_RECOR.normalized_upc %]&oclc=[% READING_RECOR.normalized_oclc %]" alt="" class="thumbnail" />
</div>
[% END %]
[% IF ( too_much_oweing ) %]
- <div class="dialog alert">
+ <div id="too_much_oweing" class="dialog alert">
Sorry, you cannot place holds because you owe [% too_much_oweing %].
</div>
[% END %]
[% IF ( too_many_reserves ) %]
- <div class="dialog alert">Sorry, you cannot place more than [% too_many_reserves %] holds.
+ <div id="too_many_reserves" class="dialog alert">Sorry, you cannot place more than [% too_many_reserves %] holds.
</div>
[% END %]
[% IF ( bad_biblionumber ) %]
- <div class="dialog alert">ERROR: No biblio record found for biblionumber [% bad_biblionumber %].</div>
+ <div id="bad_biblionumber" class="dialog alert">ERROR: No biblio record found for biblionumber [% bad_biblionumber %].</div>
[% END %]
[% IF ( no_items_selected ) %]
- <div class="dialog alert">
+ <div id="no_items_selected" class="dialog alert">
You must select at least one item.
</div>
[% END %]
[% IF ( no_branch_selected ) %]
- <div class="dialog alert">
+ <div id="no_branch_selected" class="dialog alert">
You must select a library for pickup.
</div>
[% END %]
[% IF ( no_biblionumber ) %]
- <div class="dialog alert">ERROR: No biblionumber received.</div>
+ <div id="no_biblionumber" class="dialog alert">ERROR: No biblionumber received.</div>
[% END %]
[% IF ( bad_data ) %]
- <div class="dialog alert">ERROR: Internal error: incomplete hold request.</div>
+ <div id="bad_data" class="dialog alert">ERROR: Internal error: incomplete hold request.</div>
[% END %]
[% ELSE %]
[% IF ( none_available ) %]
- <div class="dialog alert"><strong>Sorry</strong>, none of these items can be placed on hold.
+ <div id="none_available" class="dialog alert"><strong>Sorry</strong>, none of these items can be placed on hold.
</div>
[% END %]
[% END %]<!-- NAME="message" -->
<th>Item Type</th>
[% END %]
<th>Barcode</th>
- [% UNLESS ( bibitemloo.singleBranchMode ) %]
+ [% UNLESS ( singleBranchMode ) %]
<th>Home Library</th>
<th>Last Location</th>
[% END %]
[% END %]
[% END %]
[% END %][% END %]
+ [% IF OpenLibraryCovers %]KOHA.OpenLibrary.GetCoverFromIsbn();[% END %]
[% IF ( GoogleJackets ) %]KOHA.Google.GetCoverFromIsbn();[% END %]
});
//]]>
<span class="results_summary">
<span class="label">Availability:</span>
- [% IF ( SEARCH_RESULT.available_items_loop ) %]
+ [% IF ( SEARCH_RESULT.available_items_loop.0 ) %]
<span class="available"><strong>Copies available:</strong>
[% FOREACH available_items_loo IN SEARCH_RESULT.available_items_loop %]
[% UNLESS ( available_items_loo.hideatopac ) %]
- [% IF ( available_items_loo.singleBranchMode ) %]
+ [% IF ( singleBranchMode ) %]
[% available_items_loo.location %]
[% ELSE %]
[% available_items_loo.branchname %]
[% END %]
[% IF ( OPACItemsResultsDisplay ) %]
- [% UNLESS ( available_items_loo.singleBranchMode ) %][% available_items_loo.location %][% END %]
+ [% UNLESS ( singleBranchMode ) %][% available_items_loo.location %][% END %]
[% IF ( available_items_loo.itemcallnumber ) %][<a href="/cgi-bin/koha/opac-search.pl?q=callnum:[% available_items_loo.itemcallnumber |url %]">[% available_items_loo.itemcallnumber %]</a>][% END %]
[% END %]
([% available_items_loo.count %]),
<img src="http://www.syndetics.com/index.aspx?isbn=[% SEARCH_RESULT.normalized_isbn %]/SC.GIF&client=[% SEARCH_RESULT.SyndeticsClientCode %]&type=xw10&upc=[% SEARCH_RESULT.normalized_upc %]&oclc=[% SEARCH_RESULT.normalized_oclc %]" alt="" class="thumbnail" />[% END %][% END %][% END %]
[% IF ( GoogleJackets ) %][% IF ( SEARCH_RESULT.normalized_isbn ) %]<div style="block" title="[% SEARCH_RESULT.biblionumber |url %]" class="[% SEARCH_RESULT.normalized_isbn %]" id="gbs-thumbnail[% loop.count %]"></div>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
+ [% IF OpenLibraryCovers %][% IF SEARCH_RESULT.normalized_isbn %]<div style="block" title="[% SEARCH_RESULT.biblionumber %]" class="[% SEARCH_RESULT.normalized_isbn %]" id="openlibrary-thumbnail[% loop.count %]"></div>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
</a>
- [% IF ( BakerTaylorEnabled ) %][% IF ( SEARCH_RESULT.normalized_isbn ) %]<a href="https://[% SEARCH_RESULT.BakerTaylorBookstoreurl |html %][% SEARCH_RESULT.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% SEARCH_RESULT.BakerTaylorImageurl |html %][% SEARCH_RESULT.normalized_isbn %]" /></a>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
+ [% IF ( BakerTaylorEnabled ) %][% IF ( SEARCH_RESULT.normalized_isbn ) %]<a href="https://[% BakerTaylorBookstoreURL |html %][% SEARCH_RESULT.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% BakerTaylorImageURL |html %][% SEARCH_RESULT.normalized_isbn %]" /></a>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
</td>
</tr>
[% END %]
[% IF ( cgi_debug ) %]alert(_('injecting OLD comment: ')+comment);[% END %]
parent.opener.$('#c[% reviewid %] p').prev("small").prev("h5").html("Your Edited Comment (preview, pending approval)");
parent.opener.$('#c[% reviewid %] p').html(comment);
- parent.opener.$('#c[% reviewid %] p').append(" <a href=\"#comment\" onclick=\"Dopop(\'/cgi-bin/koha/opac-review.pl?biblionumber=[% biblionumber %]&reviewid=[% reviewid %]\');\">Edit<\/a>");
+ parent.opener.$('#c[% reviewid %] p').append("<a href=\"#comment\" onclick=\"Dopop(\'/cgi-bin/koha/opac-review.pl?biblionumber=[% biblionumber | uri %]&reviewid=[% reviewid | uri%]\');\">Edit<\/a>");
[% END %]
return 1;
};
parent.opener.$('#newcomment').html(
"<h5>Your Comment (preview, pending approval)<\/h5>" +
"<p>"+comment+"<\/p>" +
- "<a href=\"#comment\" onclick=\"Dopop(\'/cgi-bin/koha/opac-review.pl?biblionumber=[% biblionumber %]\');\">Edit<\/a><\/p>"
+ "<a href=\"#comment\" onclick=\"Dopop(\'/cgi-bin/koha/opac-review.pl?biblionumber=[% biblionumber |uri%]\');\">Edit<\/a><\/p>"
);
parent.opener.$("#addcomment").prev("p").remove();
parent.opener.$("#addcomment").remove();
</div>
[% END %]
<form id="reviewf" action="/cgi-bin/koha/opac-review.pl[% IF ( cgi_debug ) %]?debug=1[% END %]" method="post">
- <input type="hidden" name="biblionumber" value="[% biblionumber %]" />
+ <input type="hidden" name="biblionumber" value="[% biblionumber | html%]" />
<fieldset class="brief">
<legend>Comments on <i>[% title |html %] [% subtitle %]</i>[% IF ( author ) %]by [% author %][% END %]</legend>
<ol><li><textarea id="review" name="review" cols="60" rows="8">[% review %]</textarea></li></ol>
<div id="userserialissues" class="container">
<h2>Issues for a subscription</h2>
<div id="views">
- <span class="view"><a id="Normalview" href="opac-detail.pl?biblionumber=[% biblionumber %]" class="button">Normal View</a></span>
+ <span class="view"><a id="Normalview" href="opac-detail.pl?biblionumber=[% biblionumber | html %]" class="button">Normal View</a></span>
<span class="view"><span id="Briefhistory">Brief history</span></span>
- <span class="view"><a id="Fullhistory" href="opac-serial-issues.pl?selectview=full&biblionumber=[% biblionumber %]" class="button">Full History</a></span>
+ <span class="view"><a id="Fullhistory" href="opac-serial-issues.pl?selectview=full&biblionumber=[% biblionumber | html%]" class="button">Full History</a></span>
</div>
<form method="post" name="f">
[% FOREACH subscription_LOO IN subscription_LOOP %]
[% IF ( GoogleJackets ) %][% IF ( itemsloo.normalized_isbn ) %]<div style="block" title="[% itemsloo.biblionumber |url %]" class="[% itemsloo.normalized_isbn %]" id="gbs-thumbnail[% loop.count %]"></div>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
</a>
- [% IF ( BakerTaylorEnabled ) %][% IF ( itemsloo.normalized_isbn ) %]<a href="https://[% itemsloo.BakerTaylorBookstoreurl |html %][% itemsloo.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% itemsloo.BakerTaylorImageurl |html %][% itemsloo.normalized_isbn %]" /></a>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
+ [% IF ( BakerTaylorEnabled ) %][% IF ( itemsloo.normalized_isbn ) %]<a href="https://[% BakerTaylorBookstoreURL |html %][% itemsloo.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% BakerTaylorImageURL |html %][% itemsloo.normalized_isbn %]" /></a>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
</td>
</tr>
[% END %]<!-- /itemsloop -->
<img src="http://www.syndetics.com/index.aspx?isbn=[% review.normalized_isbn %]/SC.GIF&client=[% review.SyndeticsClientCode %]&type=xw10&upc=[% review.normalized_upc %]&oclc=[% review.normalized_oclc %]" alt="" />
[% END %][% END %][% END %][% END %]
-[% IF ( BakerTaylorEnabled ) %][% IF ( review.normalized_isbn ) %]<a href="https://[% review.BakerTaylorBookstoreurl |html %][% review.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% review.BakerTaylorImageurl |html %][% review.normalized_isbn %]" /></a>[% END %][% END %]
+[% IF ( BakerTaylorEnabled ) %][% IF ( review.normalized_isbn ) %]<a href="https://[% BakerTaylorBookstoreURL |html %][% review.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% BakerTaylorImageURL |html %][% review.normalized_isbn %]" /></a>[% END %][% END %]
[% IF ( review.author ) %]<p>By [% review.author |html %].</p> [% END %]
<p>[% IF ( review.place ) %][% review.place |html %] [% END %][% IF ( review.publishercode ) %][% review.publishercode |html %][% END %][% IF ( review.publicationyear ) %] [% review.publicationyear |html %]
[% ELSE %][% IF ( review.copyrightdate ) %] [% review.copyrightdate |html %][% END %][% END %]
[% END %]
[% IF ( review.copyrightdate ) %]<span class="results_summary"><span class="label">Date:</span>[% review.copyrightdate %]</span>[% END %]</p>
- <p class="commentline[% IF ( review.your_comment ) %] yours[% END %]">[% review.review |html %]
+ <p class="commentline[% IF ( review.your_comment ) %] yours[% END %]">
+ [% IF ( review.avatarurl ) %]
+ <img class="avatar" src="[% review.avatarurl %]" height="40" width="40"/>
+ [% END %]
+ [% review.review |html %]
<span style="font-size:87%;font-color:#CCC;">Added [% review.datereviewed %] [% IF ( review.your_comment ) %] by <strong>you</strong>[% ELSE %]
[% IF ( ShowReviewer ) %] by
[% review.firstname %] [% review.surname %][% END %][% END %]</span></p>
[% IF ( GoogleJackets ) %][% IF ( review.normalized_isbn ) %]<div style="block" title="[% review.biblionumber |url %]" class="[% review.normalized_isbn %]" id="gbs-thumbnail[% loop.count %]"></div>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
</a>
- [% IF ( BakerTaylorEnabled ) %][% IF ( review.normalized_isbn ) %]<a href="https://[% review.BakerTaylorBookstoreurl |html %][% review.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% review.BakerTaylorImageurl |html %][% review.normalized_isbn %]" /></a>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
+ [% IF ( BakerTaylorEnabled ) %][% IF ( review.normalized_isbn ) %]<a href="https://[% review.BakerTaylorBookstoreURL |html %][% review.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% review.BakerTaylorImageURL |html %][% review.normalized_isbn %]" /></a>[% ELSE %]<span class="no-image">No cover image available</span>[% END %][% END %]
</td>
</tr>
[% END %]
[% BORROWER_INF.firstname %] [% BORROWER_INF.surname %]
[% END %]
[% INCLUDE 'doc-head-close.inc' %]
+<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.metadata.min.js"></script>
<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.min.js"></script>
<script type="text/JavaScript" language="JavaScript">
//<![CDATA[
});
$(function() {
$('#opac-user-views > ul').tabs();
- $("#holdst").tablesorter({[% IF ( dateformat == 'metric' ) %]
- dateFormat: 'uk',[% END %]
- widgets : ['zebra'],
- sortList: [[0,0]],
- headers: { 0: { sorter: 'articles' },5: { sorter: false }
- }
+ $.tablesorter.defaults.widgets = ['zebra'];
+ [% IF ( dateformat == 'metric' ) %]$.tablesorter.defaults.dateFormat = ['uk'];[% END %]
+ $("#holdst").tablesorter({
+ sortList: [[0,0]]
});
- $("#checkoutst").tablesorter({[% IF ( dateformat == 'metric' ) %]
- dateFormat: 'uk',[% END %]
- widgets : ['zebra'],
- [% IF ( JacketImages ) %]
- sortList: [[3,0]],
- [% IF ( item_level_itypes ) %]
- headers: { 0: { sorter: false }, 1: { sorter: 'articles' },4: { sorter: false },5: { sorter: false },6: { sorter: false }}
- [% ELSE %]
- headers: { 0: { sorter: false }, 1: { sorter: 'articles' },5: { sorter: false },6: { sorter: false },7: { sorter: false }}
- [% END %]
- [% ELSE %]
- [% IF ( item_level_itypes ) %]
- sortList: [[2,0]],
- headers: { 0: { sorter: 'articles' },3: { sorter: false },4: { sorter: false },5: { sorter: false }}
- [% ELSE %]
- sortList: [[3,0]],
- headers: { 0: { sorter: 'articles' },4: { sorter: false },5: { sorter: false },6: { sorter: false }}
- [% END %]
- [% END %]
- });
- $("#overduest").tablesorter({[% IF ( dateformat == 'metric' ) %]
- dateFormat: 'uk',[% END %]
- widgets : ['zebra'],
- [% IF ( JacketImages ) %]
- sortList: [[1,0]],
- [% IF ( item_level_itypes ) %]
- headers: { 0: { sorter: false }, 1: { sorter: 'articles' },4: { sorter: false },5: { sorter: false }}
- [% ELSE %]
- headers: { 0: { sorter: false }, 1: { sorter: 'articles' },5: { sorter: false },6: { sorter: false }}
- [% END %]
- [% ELSE %]
- [% IF ( item_level_itypes ) %]
- sortList: [[0,0]],
- headers: { 0: { sorter: 'articles' },3: { sorter: false }}
- [% ELSE %]
- sortList: [[0,0]],
- headers: { 0: { sorter: 'articles' },1: { sorter: false },3: { sorter: false }}
- [% END %]
- [% END %]
- });
+ $("#checkoutst").tablesorter({
+ [% IF ( JacketImages ) %]sortList: [[2,0]][% ELSE %]sortList: [[1,0]][% END %]
+ });
+ $("#overduest").tablesorter();
[% IF ( GoogleJackets ) %]KOHA.Google.GetCoverFromIsbn();[% END %]
});
//]]>
[% IF ( BORROWER_INF.lost ) %]
<li><strong>Please note: </strong> Your library card has been marked as lost or stolen. If this is an error, please contact the library.</li>
[% END %]
- [% IF ( BORROWER_INF.renewal_blocked_fines ) %]
- <li><strong>Please note: </strong> Since you have <a href="/cgi-bin/koha/opac-account.pl">more than [% BORROWER_INF.renewal_blocked_fines %]</a> in fines, you cannot renew your books online. Please pay your fines if you wish to renew your books.</li>
+ [% IF renewal_blocked_fines %]
+ <li><strong>Please note: </strong> Since you have <a href="/cgi-bin/koha/opac-account.pl">more than [% renewal_blocked_fines %]</a> in fines, you cannot renew your books online. Please pay your fines if you wish to renew your books.</li>
[% END %]
</ul></div>
[% END %]
<table id="waitingt">
<caption>Holds Waiting</caption>
<thead> <tr>
- <th colspan="2">Title</th>
+ <th colspan="2" class="{sorter:'articles'}">Title</th>
<th>Hold date</th>
<th>Pick Up Library</th>
</tr></thead>
<table id="checkoutst">
<caption>[% issues_count %] Item(s) Checked Out</caption>
<thead><tr>
- [% IF ( JacketImages ) %]<th> </th>[% END %]
- <th>Title</th>
+ [% IF ( JacketImages ) %]<th class="{sorter: false}"> </th>[% END %]
+ <th class="{sorter:'articles'}">Title</th>
+ <th>Due</th>
[% UNLESS ( item_level_itypes ) %]<th>Item Type</th> [% END %]
[% IF ( show_barcode ) %]<th>Barcode</th>[% END %]
<th>Call No.</th>
- <th>Due</th>
[% IF ( OpacRenewalAllowed ) %]
- [% UNLESS ( patron_flagged ) %]<th>Renew</th>[% END %]
+ [% UNLESS patron_flagged %]<th class="{sorter: false}">Renew</th>[% END %]
[% END %]
[% IF ( OPACFinesTab ) %]
<th>Fines</th>
[% END %]
[% IF ( OPACMySummaryHTML ) %]
- <th>Links</th>
+ <th class="{sorter: false}">Links</th>
[% END %]
</tr></thead>
<tbody>
[% IF ( GoogleJackets ) %][% IF ( ISSUE.normalized_isbn ) %]<div style="display:block;" title="Click to view in Google Books" class="[% ISSUE.normalized_isbn %]" id="gbs-thumbnail[% loop.count %]"></div>[% ELSE %]<a href="http://books.google.com/books?q=[% ISSUE.title |url %]"><span class="no-image">No cover image available</span></a>[% END %][% END %]
-[% IF ( BakerTaylorEnabled ) %][% IF ( ISSUE.normalized_isbn ) %]<a href="https://[% ISSUE.BakerTaylorBookstoreurl |html %][% ISSUE.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% ISSUE.BakerTaylorImageurl |html %][% ISSUE.normalized_isbn %]" /></a>[% ELSE %]<span class="no-image">No cover image available</span><!-- BakerTaylor needs normalized_isbn! -->[% END %][% END %]
+[% IF ( BakerTaylorEnabled ) %][% IF ( ISSUE.normalized_isbn ) %]<a href="https://[% BakerTaylorBookstoreURL |html %][% ISSUE.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% BakerTaylorImageURL |html %][% ISSUE.normalized_isbn %]" /></a>[% ELSE %]<span class="no-image">No cover image available</span><!-- BakerTaylor needs normalized_isbn! -->[% END %][% END %]
[% IF ( SyndeticsEnabled ) %][% IF ( SyndeticsCoverImages ) %][% IF ( using_https ) %]
<img src="https://secure.syndetics.com/index.aspx?isbn=[% ISSUE.normalized_isbn %]/SC.GIF&client=[% ISSUE.SyndeticsClientCode %]&type=xw10&upc=[% ISSUE.normalized_upc %]&oclc=[% ISSUE.normalized_oclc %]" alt="" class="thumbnail" />
<td><a href="/cgi-bin/koha/opac-detail.pl?biblionumber=[% ISSUE.biblionumber %]">[% ISSUE.title |html %]</a><span class="item-details">
[% ISSUE.author %]
</span></td>
- [% UNLESS ( item_level_itypes ) %]<td>[% IF ( ISSUE.imageurl ) %]<img src="[% ISSUE.imageurl %]" title="[% ISSUE.description %]" alt="[% ISSUE.description %]" />[% END %] [% ISSUE.description %]</td>[% END %]
- [% IF ( show_barcode ) %]<td>[% ISSUE.barcode %]</td>[% END %]
- <td>[% ISSUE.itemcallnumber %]</td>
[% IF ( ISSUE.overdue ) %]
<td class="overdue">[% ISSUE.date_due %]</td>
[% ELSE %]
<td>[% ISSUE.date_due %]</td>
[% END %]
+ [% UNLESS ( item_level_itypes ) %]<td>[% IF ( ISSUE.imageurl ) %]<img src="[% ISSUE.imageurl %]" title="[% ISSUE.description %]" alt="[% ISSUE.description %]" />[% END %] [% ISSUE.description %]</td>[% END %]
+ [% IF ( show_barcode ) %]<td>[% ISSUE.barcode %]</td>[% END %]
+ <td>[% ISSUE.itemcallnumber %]</td>
[% IF ( OpacRenewalAllowed ) %]
- [% UNLESS ( ISSUE.patron_flagged ) %]
+ [% UNLESS patron_flagged %]
<td>[% IF ( ISSUE.status ) %]<input type="checkbox" name="item" value="[% ISSUE.itemnumber %]"/><a href="/cgi-bin/koha/opac-renew.pl?from=opac_user&item=[% ISSUE.itemnumber %]&borrowernumber=[% ISSUE.borrowernumber %]">Renew</a> <span class="renewals">([% ISSUE.renewsleft %] of [% ISSUE.renewsallowed %] renewals remaining)</span>
[% ELSE %]
Not renewable[% IF ( ISSUE.too_many ) %] <span class="renewals">([% ISSUE.renewsleft %] of [% ISSUE.renewsallowed %] renewals remaining)</span>[% ELSE %][% IF ( ISSUE.on_reserve ) %] <span class="renewals">(On hold)</span>[% END %][% END %]
</tr>
[% END %]</tbody>
</table>
-
- [% IF ( OpacRenewalAllowed ) %]
- <input type="submit" value="Renew Selected" />
- [% END %]
+
+ [% IF OpacRenewalAllowed %]
+ [% UNLESS patron_flagged %]
+ <input type="submit" value="Renew Selected" />
+ [% END %]
+ [% END %]
</form>
[% IF ( OpacRenewalAllowed ) %]
[% FOREACH ISSUE IN ISSUES %]
<input type="hidden" name="item" value="[% ISSUE.itemnumber %]" />
[% END %]
- [% UNLESS ( patron_flagged ) %]<input type="submit" value="Renew All" />[% END %]
+ [% UNLESS patron_flagged %]<input type="submit" value="Renew All" />[% END %]
</form>
[% END %]
[% ELSE %]
<caption>Overdues <span class="count">([% overdues_count %] total)</span></caption>
<!-- OVERDUES TABLE ROWS -->
<thead><tr>
-[% IF ( JacketImages ) %]<th> </th>[% END %]
-<th>Title</th>
+[% IF ( JacketImages ) %]<th class="{sorter: false}"> </th>[% END %]
+<th class="{sorter:'articles'}">Title</th>
[% UNLESS ( item_level_itypes ) %]<th>Item Type</th> [% END %]
[% IF ( show_barcode ) %]<th>Barcode</th>[% END %]
<th>Call No.</th>
<th>Due</th>
[% IF ( OpacRenewalAllowed ) %]
- [% UNLESS ( patron_flagged ) %]<th>Renew</th>[% END %][% END %]
+ [% UNLESS patron_flagged %]<th class="{sorter: false}">Renew</th>[% END %][% END %]
[% IF ( OPACFinesTab ) %]
<th>Fines</th>
[% END %]
[% IF ( GoogleJackets ) %][% IF ( OVERDUE.normalized_isbn ) %]<div style="display:block;" title="Click to view in Google Books" class="[% OVERDUE.normalized_isbn %]" id="gbs-thumbnail[% loop.count %]"></div>[% ELSE %]<a href="http://books.google.com/books?q=[% OVERDUE.title |url %]"><span class="no-image">No cover image available</span></a>[% END %][% END %]
-[% IF ( BakerTaylorEnabled ) %][% IF ( OVERDUE.normalized_isbn ) %]<a href="https://[% OVERDUE.BakerTaylorBookstoreurl |html %][% OVERDUE.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% OVERDUE.BakerTaylorImageurl |html %][% OVERDUE.normalized_isbn %]" /></a>[% ELSE %]<!-- BakerTaylor needs normalized_isbn! --><span class="no-image">No cover image available</span>[% END %][% END %]
+[% IF ( BakerTaylorEnabled ) %][% IF ( OVERDUE.normalized_isbn ) %]<a href="https://[% BakerTaylorBookstoreURL |html %][% OVERDUE.normalized_isbn %]"><img alt="See Baker & Taylor" src="[% BakerTaylorImageURL |html %][% OVERDUE.normalized_isbn %]" /></a>[% ELSE %]<!-- BakerTaylor needs normalized_isbn! --><span class="no-image">No cover image available</span>[% END %][% END %]
[% IF ( SyndeticsCoverImages ) %]
[% IF ( using_https ) %]
<td>[% OVERDUE.itemcallnumber %]</td>
<td>[% OVERDUE.date_due %]</td>
[% IF ( OpacRenewalAllowed ) %]
- [% UNLESS ( OVERDUE.patron_flagged ) %]
+ [% UNLESS patron_flagged %]
<td>
[% IF ( OVERDUE.debarred ) %]Account Frozen
[% ELSIF ( OVERDUE.status ) %]
<caption>Holds <span class="count">([% reserves_count %] total)</span></caption>
<!-- RESERVES TABLE ROWS -->
<thead><tr>
- <th>Title</th>
+ <th class="{sorter:'articles'}">Title</th>
<th>Placed On</th>
<th>Expires On</th>
<th>Pick Up Location</th>
<th>Priority</th>
[% END %]
<th>Status</th>
- <th>Modify</th>
+ <th class="{sorter: false}">Modify</th>
</tr></thead>
<tbody>
[% FOREACH RESERVE IN RESERVES %]
<a>
<xsl:choose>
<xsl:when test="$UseControlNumber = '1' and marc:subfield[@code='w']">
- <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=Control-number:<xsl:value-of select="marc:subfield[@code='w']"/></xsl:attribute>
+ <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=Control-number:<xsl:call-template name="extractControlNumber"><xsl:with-param name="subfieldW" select="marc:subfield[@code='w']"/></xsl:call-template></xsl:attribute>
</xsl:when>
<xsl:otherwise>
<xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=Title:<xsl:value-of select="translate(//marc:datafield[@tag=245]/marc:subfield[@code='a'], '.', '')"/></xsl:attribute>
<a>
<xsl:choose>
<xsl:when test="$UseControlNumber = '1' and marc:subfield[@code='w']">
- <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=Control-number:<xsl:value-of select="marc:subfield[@code='w']"/></xsl:attribute>
+ <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=Control-number:<xsl:call-template name="extractControlNumber"><xsl:with-param name="subfieldW" select="marc:subfield[@code='w']"/></xsl:call-template></xsl:attribute>
</xsl:when>
<xsl:otherwise>
<xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=Title:<xsl:value-of select="translate(marc:subfield[@code='t'], '.', '')"/></xsl:attribute>
</xsl:variable>
<xsl:choose>
<xsl:when test="$UseControlNumber = '1' and marc:subfield[@code='w']">
- <a href="/cgi-bin/koha/opac-search.pl?q=Control-number:{marc:subfield[@code='w']}">
+ <a><xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=Control-number:<xsl:call-template name="extractControlNumber"><xsl:with-param name="subfieldW" select="marc:subfield[@code='w']"/></xsl:call-template></xsl:attribute>
<xsl:value-of select="translate($f780, '()', '')"/>
</a>
</xsl:when>
<xsl:choose>
<xsl:when test="$UseControlNumber = '1' and marc:subfield[@code='w']">
- <a href="/cgi-bin/koha/opac-search.pl?q=Control-number:{marc:subfield[@code='w']}">
+ <a><xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=Control-number:<xsl:call-template name="extractControlNumber"><xsl:with-param name="subfieldW" select="marc:subfield[@code='w']"/></xsl:call-template></xsl:attribute>
<xsl:value-of select="translate($f785, '()', '')"/>
</a>
</xsl:when>
use strict;
sub kohaversion {
- our $VERSION = '3.05.00.001';
+ our $VERSION = '3.05.00.008';
# version needs to be set this way
# so that it can be picked up by Makefile.PL
# during install
#!/usr/bin/perl
+# Copyright Chris Nighswonger 2009
+#
+# 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;
use CGI;
-
+use C4::Auth;
use C4::Debug;
use C4::Creators 1.000000;
use C4::Labels 1.000000;
my $cgi = new CGI;
+my ( $template, $loggedinuser, $cookie ) = get_template_and_user({
+ template_name => "labels/label-home.tt",
+ query => $cgi,
+ type => "intranet",
+ authnotrequired => 0,
+ flagsrequired => { tools => 'label_creator' },
+ debug => 1,
+ });
+
+
my $batch_id = $cgi->param('batch_id') if $cgi->param('batch_id');
my $template_id = $cgi->param('template_id') || undef;
my $layout_id = $cgi->param('layout_id') || undef;
my $items = undef;
+
+
my $pdf_file = (@label_ids || @item_numbers ? "label_single_" . scalar(@label_ids || @item_numbers) : "label_batch_$batch_id");
print $cgi->header( -type => 'application/pdf',
-encoding => 'utf-8',
format_string => $layout->get_attr('format_string'),
);
my $format_string = $layout->get_attr('format_string');
- my @data_fields = split(/, /, $format_string);
+ my @data_fields = map { $_ eq 'callnumber' ? 'itemcallnumber' : $_ } # see bug 5653
+ split(/, /, $format_string);
my $csv_data = $label->csv_data();
- for (my $i = 0; $i < (scalar(@data_fields) - 1); $i++) {
+ for (my $i = 0; $i <= (scalar(@data_fields) - 1); $i++) {
push(@{$xml_data->{'label'}[$item_count]->{$data_fields[$i]}}, $$csv_data[$i]);
}
$item_count++;
font_size => $cgi->param('font_size') || 3,
callnum_split => ($cgi->param('callnum_split') ? 1 : 0),
text_justify => $cgi->param('text_justify') || 'L',
- format_string => $cgi->param('format_string') || 'title, author, isbn, issn, itemtype, barcode, callnumber',
+ format_string => $cgi->param('format_string') || 'title, author, isbn, issn, itemtype, barcode, itemcallnumber',
);
if ($layout_id) { # if a label_id was passed in, this is an update to an existing layout
$layout = C4::Labels::Layout->retrieve(layout_id => $layout_id);
if ($add){
if(checkauth($input)) {
my $barcode = $input->param('barcode');
- my $itemnum = GetItemnumberFromBarcode($barcode) if $barcode;
+ my $itemnum;
+ if ($barcode) {
+ $itemnum = GetItemnumberFromBarcode($barcode);
+ }
my $desc = $input->param('desc');
my $note = $input->param('note');
my $amount = $input->param('amount') || 0;
if(checkauth($input)) {
# print $input->header;
my $barcode=$input->param('barcode');
- my $itemnum = GetItemnumberFromBarcode($barcode) if $barcode;
+ my $itemnum;
+ if ($barcode) {
+ $itemnum = GetItemnumberFromBarcode($barcode);
+ }
my $desc=$input->param('desc');
my $amount=$input->param('amount');
my $type=$input->param('type');
}
#############test for member being unique #############
-if (($op eq 'insert') and !$nodouble){
- my $category_type_send=$category_type if ($category_type eq 'I');
- my $check_category; # recover the category code of the doublon suspect borrowers
- # ($result,$categorycode) = checkuniquemember($collectivity,$surname,$firstname,$dateofbirth)
- ($check_member,$check_category) = checkuniquemember(
- $category_type_send,
- ($newdata{surname} ? $newdata{surname} : $data{surname} ),
- ($newdata{firstname} ? $newdata{firstname} : $data{firstname} ),
- ($newdata{dateofbirth} ? $newdata{dateofbirth} : $data{dateofbirth})
- );
- if(!$check_member){
- $nodouble = 1;
- }
- # recover the category type if the borrowers is a doublon
+if ( ( $op eq 'insert' ) and !$nodouble ) {
+ my $category_type_send;
+ if ( $category_type eq 'I' ) {
+ $category_type_send = $category_type;
+ }
+ my $check_category; # recover the category code of the doublon suspect borrowers
+ # ($result,$categorycode) = checkuniquemember($collectivity,$surname,$firstname,$dateofbirth)
+ ( $check_member, $check_category ) = checkuniquemember(
+ $category_type_send,
+ ( $newdata{surname} ? $newdata{surname} : $data{surname} ),
+ ( $newdata{firstname} ? $newdata{firstname} : $data{firstname} ),
+ ( $newdata{dateofbirth} ? $newdata{dateofbirth} : $data{dateofbirth} )
+ );
+ if ( !$check_member ) {
+ $nodouble = 1;
+ }
+
+ # recover the category type if the borrowers is a doublon
if ($check_category) {
- my $tmpborrowercategory=GetBorrowercategory($check_category);
- $check_categorytype=$tmpborrowercategory->{'category_type'};
- }
+ my $tmpborrowercategory = GetBorrowercategory($check_category);
+ $check_categorytype = $tmpborrowercategory->{'category_type'};
+ }
}
#recover all data from guarantor address phone ,fax...
if ( $guarantorid and ( $category_type eq 'C' || $category_type eq 'P' )) {
if (my $guarantordata=GetMember(borrowernumber => $guarantorid)) {
$guarantorinfo=$guarantordata->{'surname'}." , ".$guarantordata->{'firstname'};
- if ( !defined($data{'contactname'}) or $data{'contactname'} eq '' or
- $data{'contactname'} ne $guarantordata->{'surname'} ) {
- $newdata{'contactfirstname'}= $guarantordata->{'firstname'};
- $newdata{'contactname'} = $guarantordata->{'surname'};
- $newdata{'contacttitle'} = $guarantordata->{'title'};
+ $newdata{'contactfirstname'}= $guarantordata->{'firstname'};
+ $newdata{'contactname'} = $guarantordata->{'surname'};
+ $newdata{'contacttitle'} = $guarantordata->{'title'};
+ if ( $op eq 'add' ) {
foreach (qw(streetnumber address streettype address2
- zipcode country city phone phonepro mobile fax email emailpro branchcode)) {
+ zipcode country city state phone phonepro mobile fax email emailpro branchcode
+ B_streetnumber B_streettype B_address B_address2
+ B_city B_state B_zipcode B_country B_email B_phone)) {
$newdata{$_} = $guarantordata->{$_};
}
}
}
###############test to take the right zipcode, country and city name ##############
-if (!defined($guarantorid) or $guarantorid eq '' or $guarantorid eq '0') {
- # set only if parameter was passed from the form
- $newdata{'city'} = $input->param('city') if defined($input->param('city'));
- $newdata{'zipcode'} = $input->param('zipcode') if defined($input->param('zipcode'));
- $newdata{'country'} = $input->param('country') if defined($input->param('country'));
-}
+# set only if parameter was passed from the form
+$newdata{'city'} = $input->param('city') if defined($input->param('city'));
+$newdata{'zipcode'} = $input->param('zipcode') if defined($input->param('zipcode'));
+$newdata{'country'} = $input->param('country') if defined($input->param('country'));
#builds default userid
if ( (defined $newdata{'userid'}) && ($newdata{'userid'} eq '')){
$debug and warn join "\t", map {"$_: $newdata{$_}"} qw(dateofbirth dateenrolled dateexpiry);
my $extended_patron_attributes = ();
if ($op eq 'save' || $op eq 'insert'){
- if (checkcardnumber($newdata{cardnumber},$newdata{borrowernumber})){
- push @errors, 'ERROR_cardnumber';
- }
- my $dateofbirthmandatory = (scalar grep {$_ eq "dateofbirth"} @field_check) ? 1 : 0;
- if ($newdata{dateofbirth} && $dateofbirthmandatory) {
- my $age = GetAge($newdata{dateofbirth});
- my $borrowercategory=GetBorrowercategory($newdata{'categorycode'});
- my ($low,$high) = ($borrowercategory->{'dateofbirthrequired'}, $borrowercategory->{'upperagelimit'});
- if (($high && ($age > $high)) or ($age < $low)) {
- push @errors, 'ERROR_age_limitations';
- $template->param('ERROR_age_limitations' => "$low to $high");
+ # If the cardnumber is blank, treat it as null.
+ $newdata{'cardnumber'} = undef if $newdata{'cardnumber'} =~ /^\s*$/;
+
+ if (checkcardnumber($newdata{cardnumber},$newdata{borrowernumber})){
+ push @errors, 'ERROR_cardnumber';
+ }
+ my $dateofbirthmandatory = (scalar grep {$_ eq "dateofbirth"} @field_check) ? 1 : 0;
+ if ($newdata{dateofbirth} && $dateofbirthmandatory) {
+ my $age = GetAge($newdata{dateofbirth});
+ my $borrowercategory=GetBorrowercategory($newdata{'categorycode'});
+ my ($low,$high) = ($borrowercategory->{'dateofbirthrequired'}, $borrowercategory->{'upperagelimit'});
+ if (($high && ($age > $high)) or ($age < $low)) {
+ push @errors, 'ERROR_age_limitations';
+ $template->param('ERROR_age_limitations' => "$low to $high");
+ }
}
- }
if($newdata{surname} && C4::Context->preference('uppercasesurnames')) {
$newdata{'surname'} = uc($newdata{'surname'});
$template->param( step_1 => 1, step_2 => 1, step_3 => 1, step_4 => 1, step_5 => 1, step_6 => 1 ) unless $step;
}
-# my $cardnumber=$data{'cardnumber'};
$data{'cardnumber'}=fixup_cardnumber($data{'cardnumber'}) if $op eq 'add';
if(!defined($data{'sex'})){
$template->param( none => 1);
$template->param(
nodouble => $nodouble,
borrowernumber => $borrowernumber, #register number
- guarantorid => (($borrower_data->{'guarantorid'})) ? $borrower_data->{'guarantorid'} : $guarantorid,
+ guarantorid => ($borrower_data->{'guarantorid'} || $guarantorid),
ethcatpopup => $ethcatpopup,
relshiploop => \@relshipdata,
city_loop => $city_arrayref,
my $branch = $query->param('branchcode');
my $template_name;
+$branch = q{} unless defined $branch;
+
my ($template, $loggedinuser, $cookie)
= get_template_and_user({template_name => "members/member.tmpl",
query => $query,
my $branches = GetBranches;
my @branchloop;
-foreach (sort { $branches->{$a}->{branchname} cmp $branches->{$b}->{branchname} } keys %$branches) {
- my $selected = 1 if $branches->{$_}->{branchcode} eq $branch;
- my %row = ( value => $_,
- selected => $selected,
+foreach (sort { $branches->{$a}->{branchname} cmp $branches->{$b}->{branchname} } keys %{$branches}) {
+ push @branchloop, {
+ value => $_,
+ selected => ($branches->{$_}->{branchcode} eq $branch),
branchname => $branches->{$_}->{branchname},
- );
- push @branchloop, \%row;
+ };
}
my @categories;
my $catcode;
if ( $category_type eq 'C') {
- if ($data->{guarantorid} ) {
- my $data2 = GetMember( 'borrowernumber' => $data->{'guarantorid'} );
- foreach (qw(address address2 city state B_address B_address2 B_city B_state phone mobile zipcode B_zipcode country B_country)) {
- $data->{$_} = $data2->{$_};
- }
- }
my ( $catcodes, $labels ) = GetborCatFromCatType( 'A', 'WHERE category_type = ?' );
my $cnt = scalar(@$catcodes);
_set_preference( $row->{'variable'}, $preferences{$row->{'variable'}} );
}
+
+ C4::Context->clear_syspref_cache();
}
sub _fetch_preference {
#!/bin/bash
+
+# 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., 59 Temple Place,
+# Suite 330, Boston, MA 02111-1307 USA
+
+### BEGIN INIT INFO
+# Provides: koha-pazpar-daemon
+# Required-Start: $syslog $remote_fs
+# Required-Stop: $syslog $remote_fs
+# Default-Start: 2 3 4 5
+# Default-Stop: 0 1 6
+# Short-Description: PazPar2 server daemon for Koha
+### END INIT INFO
+
USER=__KOHA_USER__
GROUP=__KOHA_GROUP__
DBNAME=__DB_NAME__
#!/bin/bash
+
+# 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., 59 Temple Place,
+# Suite 330, Boston, MA 02111-1307 USA
+
+### BEGIN INIT INFO
+# Provides: koha-zebra-daemon
+# Required-Start: $syslog $remote_fs
+# Required-Stop: $syslog $remote_fs
+# Default-Start: 2 3 4 5
+# Default-Stop: 0 1 6
+# Short-Description: Zebra server daemon for Koha indexing
+### END INIT INFO
+
USER=__KOHA_USER__
GROUP=__KOHA_GROUP__
DBNAME=__DB_NAME__
borrowernumber => $upcoming->{'borrowernumber'},
branchcode => $upcoming->{'branchcode'},
biblionumber => $biblio->{'biblionumber'},
+ itemnumber => $upcoming->{'itemnumber'},
substitute => { 'items.content' => $titles }
} );
}
borrowernumber => $upcoming->{'borrowernumber'},
branchcode => $upcoming->{'branchcode'},
biblionumber => $biblio->{'biblionumber'},
+ itemnumber => $upcoming->{'itemnumber'},
substitute => { 'items.content' => $titles }
} );
}
if ( $params->{'branchcode'} ) {
C4::Letters::parseletter( $params->{'letter'}, 'branches', $params->{'branchcode'} );
}
-
+ if ( $params->{'itemnumber'} ) {
+ C4::Letters::parseletter( $params->{'letter'}, 'issues', $params->{'itemnumber'} );
+ }
if ( $params->{'biblionumber'} ) {
C4::Letters::parseletter( $params->{'letter'}, 'biblio', $params->{'biblionumber'} );
C4::Letters::parseletter( $params->{'letter'}, 'biblioitems', $params->{'biblionumber'} );
+ C4::Letters::parseletter( $params->{'letter'}, 'items', $params->{'biblionumber'} );
}
return $params->{'letter'};
# clean up databases nightly. Be sure not to run this with --sessions during a time when the system is in use!
16 1 * * * $KOHA_CRON_PATH/cleanup_database.pl --sessions --zebraqueue 10
+
+# delete old purchase suggestions weekly. Replace XX with a number to define the age of suggestions to delete.
+@weekly $KOHA_CRON_PATH/purge_suggestions.pl --days XX > /dev/null 2>&1
return unless exists $params->{$required};
}
+ my $todaysdate = C4::Dates->new()->output("syspref");
+ $params->{'letter'}->{title} =~ s/<<today>>/$todaysdate/g;
+ $params->{'letter'}->{content} =~ s/<<today>>/$todaysdate/g;
if ( $params->{'substitute'} ) {
while ( my ( $key, $replacedby ) = each %{ $params->{'substitute'} } ) {
my ($record_type, $directory, $skip_export, $process_zebraqueue, $as_xml, $noxml, $nosanitize, $do_not_clear_zebraqueue, $verbose_logging, $zebraidx_log_opt, $server_dir) = @_;
my $num_records_exported = 0;
- my $num_records_deleted = 0;
+ my $records_deleted;
my $need_reset = check_zebra_dirs($server_dir);
if ($need_reset) {
print "$0: found broken zebra server directories: forcing a rebuild\n";
if ($process_zebraqueue) {
my $entries = select_zebraqueue_records($record_type, 'deleted');
mkdir "$directory/del_$record_type" unless (-d "$directory/del_$record_type");
- $num_records_deleted = generate_deleted_marc_records($record_type, $entries, "$directory/del_$record_type", $as_xml);
+ $records_deleted = generate_deleted_marc_records($record_type, $entries, "$directory/del_$record_type", $as_xml);
mark_zebraqueue_batch_done($entries);
$entries = select_zebraqueue_records($record_type, 'updated');
mkdir "$directory/upd_$record_type" unless (-d "$directory/upd_$record_type");
$num_records_exported = export_marc_records_from_list($record_type,
- $entries, "$directory/upd_$record_type", $as_xml, $noxml);
+ $entries, "$directory/upd_$record_type", $as_xml, $noxml, $records_deleted);
mark_zebraqueue_batch_done($entries);
} else {
my $sth = select_all_records($record_type);
my $record_fmt = ($as_xml) ? 'marcxml' : 'iso2709' ;
if ($process_zebraqueue) {
do_indexing($record_type, 'delete', "$directory/del_$record_type", $reset, $noshadow, $record_fmt, $zebraidx_log_opt)
- if $num_records_deleted;
+ if %$records_deleted;
do_indexing($record_type, 'update', "$directory/upd_$record_type", $reset, $noshadow, $record_fmt, $zebraidx_log_opt)
if $num_records_exported;
} else {
? GetXmlBiblio( $record_number )
: GetAuthorityXML( $record_number );
if ($record_type eq 'biblio'){
- my @items = GetItemsInfo($record_number, 'intra');
+ my @items = GetItemsInfo($record_number);
if (@items){
my $record = MARC::Record->new;
my @itemsrecord;
# strung together with no single root element. zebraidx doesn't seem
# to care, though, at least if you're using the GRS-1 filter. It does
# care if you're using the DOM filter, which requires valid XML file(s).
- print OUT ($as_xml) ? $marc->as_xml_record(C4::Context->preference('marcflavour')) : $marc->as_usmarc();
- $num_exported++;
+ eval {
+ print OUT ($as_xml) ? $marc->as_xml_record(C4::Context->preference('marcflavour')) : $marc->as_usmarc();
+ $num_exported++;
+ };
+ if ($@) {
+ warn "Error exporting record $record_number ($record_type) ".($noxml ? "not XML" : "XML");
+ }
}
}
print "\nRecords exported: $num_exported\n" if ( $verbose_logging );
}
sub export_marc_records_from_list {
- my ($record_type, $entries, $directory, $as_xml, $noxml) = @_;
+ my ($record_type, $entries, $directory, $as_xml, $noxml, $records_deleted) = @_;
my $num_exported = 0;
open (OUT, ">:utf8 ", "$directory/exported_records") or die $!;
my $i = 0;
- my %found = ();
+
+ # Skip any deleted records. We check for this anyway, but this reduces error spam
+ my %found = %$records_deleted;
foreach my $record_number ( map { $_->{biblio_auth_number} }
grep { !$found{ $_->{biblio_auth_number} }++ }
@$entries ) {
sub generate_deleted_marc_records {
my ($record_type, $entries, $directory, $as_xml) = @_;
- my $num_exported = 0;
+ my $records_deleted = {};
open (OUT, ">:utf8 ", "$directory/exported_records") or die $!;
my $i = 0;
foreach my $record_number (map { $_->{biblio_auth_number} } @$entries ) {
}
print OUT ($as_xml) ? $marc->as_xml_record(C4::Context->preference("marcflavour")) : $marc->as_usmarc();
- $num_exported++;
+
+ $records_deleted->{$record_number} = 1;
}
- print "\nRecords exported: $num_exported\n" if ( $verbose_logging );
+ print "\nRecords exported: $i\n" if ( $verbose_logging );
close OUT;
- return $num_exported;
+ return $records_deleted;
}
$fetch_sth->execute($record_number);
if (my ($blob) = $fetch_sth->fetchrow_array) {
$marc = MARC::Record->new_from_usmarc($blob);
- $fetch_sth->finish();
- } else {
- return; # failure to find a bib is not a problem -
- # a delete could have been done before
- # trying to process a record update
+ unless ($marc) {
+ warn "error creating MARC::Record from $blob";
+ }
}
+ # failure to find a bib is not a problem -
+ # a delete could have been done before
+ # trying to process a record update
+
+ $fetch_sth->finish();
+ return unless $marc;
} else {
eval { $marc = GetMarcBiblio($record_number); };
- if ($@) {
+ if ($@ || !$marc) {
# here we do warn since catching an exception
# means that the bib was found but failed
# to be parsed
# $charset_in = $candidate;
# }
# }
+
+ # BUG6464: check consistency of PO messages
+ # - count number of '%s' in msgid and msgstr
+ for my $msg ( values %$href ) {
+ my $id_count = split(/%s/, $msg->{msgid}) - 1;
+ my $str_count = split(/%s/, $msg->{msgstr}) - 1;
+ next if $id_count == $str_count ||
+ $msg->{msgstr} eq '""' ||
+ grep { /fuzzy/ } @{$msg->{_flags}};
+ warn_normal
+ "unconsistent %s count: ($id_count/$str_count):\n" .
+ " line: " . $msg->{loaded_line_number} . "\n" .
+ " msgid: " . $msg->{msgid} . "\n" .
+ " msgstr: " . $msg->{msgstr} . "\n", undef;
+ }
}
# set our charset in to UTF-8
print XMLout(
$out,
noattr => 1,
- noescape => 1,
nosort => 1,
xmldecl => '<?xml version="1.0" encoding="UTF-8" ?>',
RootName => $service,
my $ean = GetNormalizedEAN($record,$marcflavour);
my $oclc = GetNormalizedOCLCNumber($record,$marcflavour);
my $isbn = GetNormalizedISBN(undef,$record,$marcflavour);
-my $content_identifier_exists = 1 if ($isbn or $ean or $oclc or $upc);
+my $content_identifier_exists;
+if ( $isbn or $ean or $oclc or $upc ) {
+ $content_identifier_exists = 1;
+}
$template->param(
normalized_upc => $upc,
normalized_ean => $ean,
my $norequests = 1;
my $res = GetISBDView($biblionumber, "opac");
-my @items = &GetItemsInfo($biblionumber, 'opac');
+my @items = GetItemsInfo( $biblionumber );
my $itemtypes = GetItemTypes();
for my $itm (@items) {
my ( $template, $loggedinuser, $cookie );
my $resultsperpage;
-my $authtypes = getauthtypes;
-my @authtypesloop;
-foreach my $thisauthtype ( sort { $authtypes->{$a}{'authtypetext'} cmp $authtypes->{$b}{'authtypetext'} }
- keys %$authtypes )
-{
- my $selected = 1 if $thisauthtype eq $authtypecode;
- my %row = (
- value => $thisauthtype,
- selected => $selected,
- authtypetext => $authtypes->{$thisauthtype}{'authtypetext'},
- );
- push @authtypesloop, \%row;
+my $authtypes = getauthtypes();
+my @authtypesloop = ();
+foreach my $thisauthtype (
+ sort {
+ $authtypes->{$a}->{'authtypetext'}
+ cmp $authtypes->{$b}->{'authtypetext'}
+ }
+ keys %{$authtypes}
+ ) {
+ push @authtypesloop,
+ { value => $thisauthtype,
+ selected => $thisauthtype eq $authtypecode,
+ authtypetext => $authtypes->{$thisauthtype}->{'authtypetext'},
+ };
}
if ( $op eq "do_search" ) {
}
$template->param( "Tab0XX" => \@loop_data );
-my $authtypes = getauthtypes;
-my @authtypesloop;
-foreach my $thisauthtype ( keys %$authtypes ) {
- my $selected = 1 if $thisauthtype eq $authtypecode;
- my %row = (
- value => $thisauthtype,
- selected => $selected,
+my $authtypes = getauthtypes();
+my @authtypesloop = ();
+foreach my $thisauthtype ( keys %{$authtypes} ) {
+ push @authtypesloop,
+ { value => $thisauthtype,
+ selected => $thisauthtype eq $authtypecode,
authtypetext => $authtypes->{$thisauthtype}{'authtypetext'},
- );
- push @authtypesloop, \%row;
+ };
}
$template->param(
$template->param('OPACShowCheckoutName' => C4::Context->preference("OPACShowCheckoutName") );
# change back when ive fixed request.pl
-my @all_items = &GetItemsInfo( $biblionumber, 'opac' );
+my @all_items = GetItemsInfo( $biblionumber );
my @items;
# Getting items to be hidden
my $ean = GetNormalizedEAN($record,$marcflavour);
my $oclc = GetNormalizedOCLCNumber($record,$marcflavour);
my $isbn = GetNormalizedISBN(undef,$record,$marcflavour);
-my $content_identifier_exists = 1 if ($isbn or $ean or $oclc or $upc);
+my $content_identifier_exists;
+if ( $isbn or $ean or $oclc or $upc ) {
+ $content_identifier_exists = 1;
+}
$template->param(
normalized_upc => $upc,
normalized_ean => $ean,
ocoins => GetCOinSBiblio($biblionumber),
);
+my $libravatar_enabled = 0;
+eval 'use Libravatar::URL';
+if (!$@ and C4::Context->preference('ShowReviewer') and C4::Context->preference('ShowReviewerPhoto')) {
+ $libravatar_enabled = 1;
+}
+
my $reviews = getreviews( $biblionumber, 1 );
my $loggedincommenter;
foreach ( @$reviews ) {
$_->{title} = $borrowerData->{'title'};
$_->{surname} = $borrowerData->{'surname'};
$_->{firstname} = $borrowerData->{'firstname'};
+ if ($libravatar_enabled and $borrowerData->{'email'}) {
+ $_->{avatarurl} = libravatar_url(email => $borrowerData->{'email'}, https => $ENV{HTTPS});
+ }
$_->{userid} = $borrowerData->{'userid'};
$_->{cardnumber} = $borrowerData->{'cardnumber'};
$_->{datereviewed} = format_date($_->{datereviewed});
#written 18/1/2000 by chris@katipo.co.nz
# adapted for use in the hlt opac by finlay@katipo.co.nz 29/11/2002
# script to renew items from the web
-# Parts Copyright 2010 Catalyst IT
+# Parts Copyright 2010,2011 Catalyst IT
# This file is part of Koha.
#
use CGI;
use C4::Circulation;
use C4::Auth;
-
+use C4::Items;
+use C4::Members;
my $query = new CGI;
my ( $template, $borrowernumber, $cookie ) = get_template_and_user(
for my $itemnumber ( @items ) {
my ($status,$error) = CanBookBeRenewed( $borrowernumber, $itemnumber );
if ( $status == 1 && $opacrenew == 1 ) {
- AddRenewal( $borrowernumber, $itemnumber );
+ my $renewalbranch = C4::Context->preference('OpacRenewalBranch');
+ my $branchcode;
+ if ($renewalbranch eq 'itemhomebranch'){
+ my $item = GetItem($itemnumber);
+ $branchcode=$item->{'homebranch'};
+ }
+ elsif ($renewalbranch eq 'patronhomebranch'){
+ my $borrower = GetMemberDetails($borrowernumber);
+ $branchcode = $borrower->{'branchcode'};
+ }
+ elsif ($renewalbranch eq 'checkoutbranch'){
+ my $issue = GetOpenIssue($itemnumber);
+ $branchcode = $issue->{'branchcode'};
+ }
+ elsif ($renewalbranch eq 'NULL'){
+ $branchcode='';
+ }
+ else {
+ $branchcode='OPACRenew'
+ }
+ AddRenewal( $borrowernumber, $itemnumber, $branchcode);
}
else {
$errorstring .= $error ."|";
$template->param(outer_sup_servers_loop => $secondary_servers_loop,);
# set the default sorting
- my $default_sort_by = C4::Context->preference('OPACdefaultSortField')."_".C4::Context->preference('OPACdefaultSortOrder')
- if (C4::Context->preference('OPACdefaultSortField') && C4::Context->preference('OPACdefaultSortOrder'));
- $template->param($default_sort_by => 1);
+ if ( C4::Context->preference('OPACdefaultSortField')
+ && C4::Context->preference('OPACdefaultSortOrder') ) {
+ my $default_sort_by =
+ C4::Context->preference('OPACdefaultSortField') . '_'
+ . C4::Context->preference('OPACdefaultSortOrder');
+ $template->param( $default_sort_by => 1 );
+ }
# determine what to display next to the search boxes (ie, boolean option
# shouldn't appear on the first one, scan indexes should, adding a new
# sort by is used to sort the query
# in theory can have more than one but generally there's just one
my @sort_by;
-my $default_sort_by = C4::Context->preference('OPACdefaultSortField')."_".C4::Context->preference('OPACdefaultSortOrder')
- if (C4::Context->preference('OPACdefaultSortField') && C4::Context->preference('OPACdefaultSortOrder'));
+my $default_sort_by;
+if ( C4::Context->preference('OPACdefaultSortField')
+ && C4::Context->preference('OPACdefaultSortOrder') ) {
+ $default_sort_by =
+ C4::Context->preference('OPACdefaultSortField') . '_'
+ . C4::Context->preference('OPACdefaultSortOrder');
+}
+my @allowed_sortby = qw /acqdate_asc acqdate_dsc author_az author_za call_number_asc call_number_dsc popularity_asc popularity_dsc pubdate_asc pubdate_dsc relevance title_az title_za/;
@sort_by = split("\0",$params->{'sort_by'}) if $params->{'sort_by'};
$sort_by[0] = $default_sort_by if !$sort_by[0] && defined($default_sort_by);
foreach my $sort (@sort_by) {
- $template->param($sort => 1); # FIXME: security hole. can set any TMPL_VAR here
+ if ( $sort ~~ @allowed_sortby ) {
+ $template->param($sort => 1);
+ }
}
$template->param('sort_by' => $sort_by[0]);
my $pages = ceil($hits / $results_per_page);
# default page number
my $current_page_number = 1;
- $current_page_number = ($offset / $results_per_page + 1) if $offset;
- my $previous_page_offset = $offset - $results_per_page unless ($offset - $results_per_page <0);
+ if ($offset) {
+ $current_page_number = ( $offset / $results_per_page + 1 );
+ }
+ my $previous_page_offset;
+ if ( $offset >= $results_per_page ) {
+ $previous_page_offset = $offset - $results_per_page;
+ }
my $next_page_offset = $offset + $results_per_page;
# If we're within the first 10 pages, keep it simple
#warn "current page:".$current_page_number;
my $this_offset = (($i*$results_per_page)-$results_per_page);
# the page number for this page
my $this_page_number = $i;
- # it should only be highlighted if it's the current page
- my $highlight = 1 if ($this_page_number == $current_page_number);
# put it in the array
- push @page_numbers, { offset => $this_offset, pg => $this_page_number, highlight => $highlight, sort_by => join " ",@sort_by };
-
+ push @page_numbers,
+ { offset => $this_offset,
+ pg => $this_page_number,
+ highlight => $this_page_number == $current_page_number,
+ sort_by => join ' ', @sort_by
+ };
+
}
}
for ($i=$current_page_number; $i<=($current_page_number + 20 );$i++) {
my $this_offset = ((($i-9)*$results_per_page)-$results_per_page);
my $this_page_number = $i-9;
- my $highlight = 1 if ($this_page_number == $current_page_number);
- if ($this_page_number <= $pages) {
- push @page_numbers, { offset => $this_offset, pg => $this_page_number, highlight => $highlight, sort_by => join " ",@sort_by };
+ if ( $this_page_number <= $pages ) {
+ push @page_numbers,
+ { offset => $this_offset,
+ pg => $this_page_number,
+ highlight => $this_page_number == $current_page_number,
+ sort_by => join ' ', @sort_by
+ };
}
}
my $marcauthorsarray = GetMarcAuthors( $record, $marcflavour );
my $marcsubjctsarray = GetMarcSubjects( $record, $marcflavour );
- my @items = &GetItemsInfo( $biblionumber, 'opac' );
+ my @items = GetItemsInfo( $biblionumber );
my $hasauthors = 0;
if($dat->{'author'} || @$marcauthorsarray) {
my $marcauthorsarray = GetMarcAuthors( $record, $marcflavour );
my $marcsubjctsarray = GetMarcSubjects( $record, $marcflavour );
- my @items = &GetItemsInfo( $biblionumber, 'opac' );
+ my @items = GetItemsInfo( $biblionumber );
$dat->{MARCNOTES} = $marcnotesarray;
$dat->{MARCSUBJCTS} = $marcsubjctsarray;
);
}
+my $libravatar_enabled = 0;
+eval 'use Libravatar::URL';
+if (!$@ and C4::Context->preference('ShowReviewer') and C4::Context->preference('ShowReviewerPhoto')) {
+ $libravatar_enabled = 1;
+}
+
my $reviews = getallreviews(1,$offset,$results_per_page);
my $marcflavour = C4::Context->preference("marcflavour");
my $hits = numberofreviews();
$result->{timestamp} = $bib->{'timestamp'};
$result->{firstname} = $borr->{'firstname'};
$result->{surname} = $borr->{'surname'};
+ if ($libravatar_enabled and $borr->{'email'}) {
+ $result->{avatarurl} = libravatar_url(email => $borr->{'email'}, size => 40, https => $ENV{HTTPS});
+ }
+
if ($result->{borrowernumber} eq $borrowernumber) {
$result->{your_comment} = 1;
}
my $itype_or_itemtype = (C4::Context->preference("item-level_itypes"))?'itype':'itemtype';
$itemtypes = GetItemTypes;
my @itemtypesloop;
-my $selected=1;
if (!$advanced_search_types or $advanced_search_types eq 'itemtypes') {
foreach my $thisitemtype ( sort {$itemtypes->{$a}->{'description'} cmp $itemtypes->{$b}->{'description'} } keys %$itemtypes ) {
- my $selected = 1 if $thisitemtype eq $itemtype;
my %row =( value => $thisitemtype,
description => $itemtypes->{$thisitemtype}->{'description'},
- selected => $selected,
+ selected => $thisitemtype eq $itemtype,
);
push @itemtypesloop, \%row;
}
for my $thisitemtype (@$advsearchtypes) {
my $selected = 1 if $thisitemtype->{authorised_value} eq $itemtype;
my %row =( value => $thisitemtype->{authorised_value},
- selected => $selected,
+ selected => $thisitemtype eq $itemtype,
description => $thisitemtype->{'lib'},
);
push @itemtypesloop, \%row;
if ( 5 >= $borr->{'amountoutstanding'} && $borr->{'amountoutstanding'} > 0 ) {
$borr->{'amountoverzero'} = 1;
}
+my $no_renewal_amt = C4::Context->preference( 'OPACFineNoRenewals' );
+$no_renewal_amt ||= 0;
-if ( $borr->{'amountoutstanding'} > C4::Context->preference( 'OPACFineNoRenewals' ) ) {
+if ( $borr->{amountoutstanding} > $no_renewal_amt ) {
$borr->{'flagged'} = 1;
$template->param(
- renewal_blocked_fines => sprintf( "%.02f", C4::Context->preference( 'OPACFineNoRenewals' ) ),
+ renewal_blocked_fines => sprintf( '%.02f', $no_renewal_amt ),
);
}
# load the branches
my $branches = GetBranches();
my @branch_loop;
-for my $branch_hash (sort keys %$branches ) {
- my $selected=(C4::Context->userenv && ($branch_hash eq C4::Context->userenv->{branch})) if (C4::Context->preference('SearchMyLibraryFirst'));
+for my $branch_hash ( sort keys %{$branches} ) {
+ my $selected;
+ if ( C4::Context->preference('SearchMyLibraryFirst') ) {
+ $selected =
+ ( C4::Context->userenv
+ && ( $branch_hash eq C4::Context->userenv->{branch} ) );
+ }
push @branch_loop,
- {
- value => "branch: $branch_hash",
+ { value => "branch: $branch_hash",
branchname => $branches->{$branch_hash}->{'branchname'},
- selected => $selected
+ selected => $selected,
};
}
$template->param( branchloop => \@branch_loop );
my $item = GetItem(undef,$barcode);
if (C4::Context->preference('SelfCheckoutByLogin') && !$patronid) {
my $dbh = C4::Context->dbh;
- my $resval, $patronid = checkpw($dbh, $patronlogin, $patronpw);
+ my ($resval, $patronid) = checkpw($dbh, $patronlogin, $patronpw);
}
my $borrower = GetMemberDetails(undef,$patronid);
use warnings;
use CGI;
+use C4::Auth;
use Graphics::Magick;
use XML::Simple;
use POSIX qw(ceil);
my $cgi = new CGI;
+my ( $template, $loggedinuser, $cookie ) = get_template_and_user({
+ template_name => "labels/label-home.tt",
+ query => $cgi,
+ type => "intranet",
+ authnotrequired => 0,
+ flagsrequired => { tools => 'label_creator' },
+ debug => 1,
+ });
+
+
my $batch_id = $cgi->param('batch_id') if $cgi->param('batch_id');
my $template_id = $cgi->param('template_id') || undef;
my $layout_id = $cgi->param('layout_id') || undef;
#use warnings; FIXME - Bug 2505
use CGI;
use Text::CSV;
+use URI::Escape;
use C4::Reports::Guided;
use C4::Auth qw/:DEFAULT get_session/;
use C4::Output;
my $totpages = int($total/$limit) + (($total % $limit) > 0 ? 1 : 0);
my $url = "/cgi-bin/koha/reports/guided_reports.pl?reports=$report&phase=Run%20this%20report";
+ if (@sql_params) {
+ $url = join('&sql_params=', $url, map { URI::Escape::uri_escape($_) } @sql_params);
+ }
$template->param(
'results' => \@rows,
'sql' => $sql,
# and the number matches the number of columns
my $colcount=0;
foreach my $col ( @loopcol ) {
- my $value =$table{$row}->{(($col->{coltitle} eq "NULL")or ($col->{coltitle} eq ""))?"zzEMPTY":$col->{coltitle}} / $wgttable{$row}->{(($col->{coltitle} eq "NULL")or ($col->{coltitle} eq ""))?"zzEMPTY":$col->{coltitle}} if ($table{$row}->{(($col->{coltitle} eq "NULL")or ($col->{coltitle} eq ""))?"zzEMPTY":$col->{coltitle}});
-
+ my $value;
+ if ($table{$row}->{
+ ( ( $col->{coltitle} eq 'NULL' )
+ or ( $col->{coltitle} eq q{} )
+ ) ? 'zzEMPTY' : $col->{coltitle}
+ }
+ ) {
+ $value = $table{$row}->{
+ ( ( $col->{coltitle} eq 'NULL' )
+ or ( $col->{coltitle} eq q{} )
+ ) ? 'zzEMPTY' : $col->{coltitle}
+ } / $wgttable{$row}->{
+ ( ( $col->{coltitle} eq 'NULL' )
+ or ( $col->{coltitle} eq q{} )
+ ) ? 'zzEMPTY' : $col->{coltitle}
+ };
+ }
$table{$row}->{(($col->{coltitle} eq "NULL")or ($col->{coltitle} eq ""))?"zzEMPTY":$col->{coltitle}} = $value;
$table{$row}->{totalrow}+=$value;
#warn "row : $row col:$col $cnttable{$row}->{(($col->{coltitle} eq \"NULL\")or ($col->{coltitle} eq \"\"))?\"zzEMPTY\":$col->{coltitle}}";
push @loopcell, {value => ($value)?sprintf("%.2f",$value):0 } ;
}
#warn "row : $row colcount:$colcount";
- my $total = $table{$row}->{totalrow}/$colcount if ($colcount>0);
- push @looprow,{ 'rowtitle' => ($row eq "zzEMPTY")?"NULL":$row,
- 'loopcell' => \@loopcell,
- 'hilighted' => ($hilighted >0),
- 'totalrow' => ($total)?sprintf("%.2f",$total):0
- };
+ my $total;
+ if ( $colcount > 0 ) {
+ $total = $table{$row}->{totalrow} / $colcount;
+ }
+ push @looprow,
+ { 'rowtitle' => ( $row eq "zzEMPTY" ) ? "NULL" : $row,
+ 'loopcell' => \@loopcell,
+ 'hilighted' => ( $hilighted > 0 ),
+ 'totalrow' => ($total) ? sprintf( "%.2f", $total ) : 0
+ };
$hilighted = -$hilighted;
}
#
# FIXME still need to shift the text to the template so its translateable
if ( $data->[$i]) {
# find if its on issue
- my @items = GetItemsInfo($line{'biblionumber'}, 'intra' );
+ my @items = GetItemsInfo( $line{biblionumber} );
my $onissue = 0;
foreach my $item (@items) {
if ( $item->{'datedue'} eq 'Reserved' ) {
# and probably remove the reserveconstraint table as well, I never could fill anything in this table.
my @reqbib=$input->param('reqbib');
my $biblionumber=$input->param('biblionumber');
-my $borrower=$input->param('member');
+my $borrowernumber=$input->param('borrowernumber');
my $notes=$input->param('notes');
my $branch=$input->param('pickup');
my $startdate=$input->param('reserve_date') || '';
my @rank=$input->param('rank-request');
my $type=$input->param('type');
my $title=$input->param('title');
-my $borrowernumber=GetMember('cardnumber'=>$borrower);
+my $borrower=GetMember('borrowernumber'=>$borrowernumber);
my $checkitem=$input->param('checkitem');
my $expirationdate = $input->param('expiration_date');
}
}
-if ($type eq 'str8' && $borrowernumber ne ''){
+if ($type eq 'str8' && $borrower){
foreach my $biblionumber (keys %bibinfos) {
my $count=@bibitems;
if ($multi_hold) {
my $bibinfo = $bibinfos{$biblionumber};
- AddReserve($branch,$borrowernumber->{'borrowernumber'},$biblionumber,'a',[$biblionumber],
+ AddReserve($branch,$borrower->{'borrowernumber'},$biblionumber,'a',[$biblionumber],
$bibinfo->{rank},$startdate,$expirationdate,$notes,$bibinfo->{title},$checkitem,$found);
} else {
if ($input->param('request') eq 'any'){
# place a request on 1st available
- AddReserve($branch,$borrowernumber->{'borrowernumber'},$biblionumber,'a',\@realbi,$rank[0],$startdate,$expirationdate,$notes,$title,$checkitem,$found);
+ AddReserve($branch,$borrower->{'borrowernumber'},$biblionumber,'a',\@realbi,$rank[0],$startdate,$expirationdate,$notes,$title,$checkitem,$found);
} elsif ($reqbib[0] ne ''){
# FIXME : elsif probably never reached, (see top of the script)
# place a request on a given item
- AddReserve($branch,$borrowernumber->{'borrowernumber'},$biblionumber,'o',\@reqbib,$rank[0],$startdate,$expirationdate,$notes,$title,$checkitem, $found);
+ AddReserve($branch,$borrower->{'borrowernumber'},$biblionumber,'o',\@reqbib,$rank[0],$startdate,$expirationdate,$notes,$title,$checkitem, $found);
} else {
- AddReserve($branch,$borrowernumber->{'borrowernumber'},$biblionumber,'a',\@realbi,$rank[0],$startdate,$expirationdate,$notes,$title,$checkitem, $found);
+ AddReserve($branch,$borrower->{'borrowernumber'},$biblionumber,'a',\@realbi,$rank[0],$startdate,$expirationdate,$notes,$title,$checkitem, $found);
}
}
}
} else {
print $input->redirect("request.pl?biblionumber=$biblionumber");
}
-} elsif ($borrowernumber eq ''){
+} elsif ($borrower eq ''){
print $input->header();
- print "Invalid card number please try again";
- print $input->Dump;
+ print "Invalid borrower number please try again";
+# Not sure that Dump() does HTML escaping. Use firebug or something to trace
+# instead.
+# print $input->Dump;
}
my $findborrower = $input->param('findborrower');
$findborrower = '' unless defined $findborrower;
$findborrower =~ s|,| |g;
-my $cardnumber = $input->param('cardnumber') || '';
+my $borrowernumber_hold = $input->param('borrowernumber') || '';
my $borrowerslist;
my $messageborrower;
my $warnings;
my @borrowers = @$borrowers;
- if ( $#borrowers == -1 ) {
- $input->param( 'findborrower', '' );
+ if ( !@borrowers ) {
$messageborrower = "'$findborrower'";
}
- elsif ( $#borrowers == 0 ) {
- $input->param( 'cardnumber', $borrowers[0]->{'cardnumber'} );
- $cardnumber = $borrowers[0]->{'cardnumber'};
+ elsif ( @borrowers == 1 ) {
+ $borrowernumber_hold = $borrowers[0]->{'borrowernumber'};
}
else {
$borrowerslist = \@borrowers;
}
}
-if ($cardnumber) {
- my $borrowerinfo = GetMemberDetails( 0, $cardnumber );
+if ($borrowernumber_hold) {
+ my $borrowerinfo = GetMemberDetails( $borrowernumber_hold );
my $diffbranch;
my @getreservloop;
my $count_reserv = 0;
my $number_reserves =
GetReserveCount( $borrowerinfo->{'borrowernumber'} );
- if ( C4::Context->preference('maxreserves') && $number_reserves >= C4::Context->preference('maxreserves') ) {
+ if ( C4::Context->preference('maxreserves') && ($number_reserves >= C4::Context->preference('maxreserves')) ) {
$warnings = 1;
$maxreserves = 1;
}
}
$template->param(
- borrowernumber => $borrowerinfo->{'borrowernumber'},
- borrowersurname => $borrowerinfo->{'surname'},
- borrowerfirstname => $borrowerinfo->{'firstname'},
- borrowerstreetaddress => $borrowerinfo->{'address'},
- borrowercity => $borrowerinfo->{'city'},
- borrowerphone => $borrowerinfo->{'phone'},
- borrowermobile => $borrowerinfo->{'mobile'},
- borrowerfax => $borrowerinfo->{'fax'},
- borrowerphonepro => $borrowerinfo->{'phonepro'},
- borroweremail => $borrowerinfo->{'email'},
- borroweremailpro => $borrowerinfo->{'emailpro'},
- borrowercategory => $borrowerinfo->{'category'},
- borrowerreservs => $count_reserv,
- maxreserves => $maxreserves,
- expiry => $expiry,
- diffbranch => $diffbranch,
- messages => $messages,
- warnings => $warnings
+ borrowernumber => $borrowerinfo->{'borrowernumber'},
+ borrowersurname => $borrowerinfo->{'surname'},
+ borrowerfirstname => $borrowerinfo->{'firstname'},
+ borrowerstreetaddress => $borrowerinfo->{'address'},
+ borrowercity => $borrowerinfo->{'city'},
+ borrowerphone => $borrowerinfo->{'phone'},
+ borrowermobile => $borrowerinfo->{'mobile'},
+ borrowerfax => $borrowerinfo->{'fax'},
+ borrowerphonepro => $borrowerinfo->{'phonepro'},
+ borroweremail => $borrowerinfo->{'email'},
+ borroweremailpro => $borrowerinfo->{'emailpro'},
+ borrowercategory => $borrowerinfo->{'category'},
+ borrowerreservs => $count_reserv,
+ cardnumber => $borrowerinfo->{'cardnumber'},
+ maxreserves => $maxreserves,
+ expiry => $expiry,
+ diffbranch => $diffbranch,
+ messages => $messages,
+ warnings => $warnings
);
}
} @{$borrowerslist}
)
{
- push @values, $borrower->{cardnumber};
+ push @values, $borrower->{borrowernumber};
- $labels{ $borrower->{cardnumber} } = sprintf(
+ $labels{ $borrower->{borrowernumber} } = sprintf(
'%s, %s ... (%s - %s) ... %s',
- $borrower->{surname}, $borrower->{firstname},
- $borrower->{cardnumber}, $borrower->{categorycode},
- $borrower->{address},
+ $borrower->{surname} ||'', $borrower->{firstname} || '',
+ $borrower->{cardnumber} || '', $borrower->{categorycode} || '',
+ $borrower->{address} || '',
);
}
$CGIselectborrower = CGI::scrolling_list(
- -name => 'cardnumber',
+ -name => 'borrowernumber',
-values => \@values,
-labels => \%labels,
-size => 7,
}
# FIXME launch another time GetMemberDetails perhaps until
-my $borrowerinfo = GetMemberDetails( 0, $cardnumber );
+my $borrowerinfo = GetMemberDetails( $borrowernumber_hold );
my @biblionumbers = ();
my $biblionumbers = $input->param('biblionumbers');
my $dat = GetBiblioData($biblionumber);
- if ( not CanBookBeReserved($borrowerinfo->{borrowernumber}, $biblionumber) ) {
+ unless ( CanBookBeReserved($borrowerinfo->{borrowernumber}, $biblionumber) ) {
$warnings = 1;
$maxreserves = 1;
}
$item->{'holdallowed'} = $branchitemrule->{'holdallowed'};
if ( $branchitemrule->{'holdallowed'} == 0 ||
- ( $branchitemrule->{'holdallowed'} == 1 && $borrowerinfo->{'branchcode'} ne $item->{'homebranch'} ) ) {
+ ( $branchitemrule->{'holdallowed'} == 1 &&
+ $borrowerinfo->{'branchcode'} ne $item->{'homebranch'} ) ) {
$policy_holdallowed = 0;
}
- if (IsAvailableForItemLevelRequest($itemnumber) and not $item->{cantreserve} and CanItemBeReserved($borrowerinfo->{borrowernumber}, $itemnumber) ) {
+ if (IsAvailableForItemLevelRequest($itemnumber) and
+ not $item->{cantreserve} and
+ CanItemBeReserved($borrowerinfo->{borrowernumber}, $itemnumber) ) {
if ( $policy_holdallowed ) {
$item->{available} = 1;
$num_available++;
date => $date,
biblionumber => $biblionumber,
findborrower => $findborrower,
- cardnumber => $cardnumber,
title => $dat->{title},
author => $dat->{author},
holdsview => 1,
# get biblio information....
my $biblio = $subs->{'biblionumber'};
my ($count2,@bibitems) = GetBiblioItemByBiblioNumber($biblio);
- my @itemresults = GetItemsInfo($subs->{'biblionumber'}, 'intra');
+ my @itemresults = GetItemsInfo( $subs->{biblionumber} );
my $branch = $itemresults[0]->{'holdingbranch'};
my $branchname = GetBranchName($branch);
$cell->{serialsadditems} = 1;
}
$cell->{'subscriptionid'} = $subscriptionid;
+ $cell->{biblionumber} = $serialdatalist[0]->{'biblionumber'};
$cell->{'itemid'} = 'NNEW';
$cell->{'serialid'} = 'NEW';
$cell->{'issuesatonce'} = 1;
# Permission needed if it is a modification : edit_subscription
# Permission needed otherwise (nothing or dup) : create_subscription
-my $permission = ($op eq "mod") ? "edit_subscription" : "create_subscription";
+my $permission = ($op eq "modify") ? "edit_subscription" : "create_subscription";
my ($template, $loggedinuser, $cookie)
= get_template_and_user({template_name => "serials/subscription-add.tmpl",
my $firstissuedate;
my $nextexpected;
-if ($op eq 'mod' || $op eq 'dup' || $op eq 'modsubscription') {
+if ($op eq 'modify' || $op eq 'dup' || $op eq 'modsubscription') {
my $subscriptionid = $query->param('subscriptionid');
$subs = GetSubscription($subscriptionid);
## FIXME : Check rights to edit if mod. Could/Should display an error message.
- if ($subs->{'cannotedit'} && $op eq 'mod'){
+ if ($subs->{'cannotedit'} && $op eq 'modify'){
carp "Attempt to modify subscription $subscriptionid by ".C4::Context->userenv->{'id'}." not allowed";
print $query->redirect("/cgi-bin/koha/serials/subscription-detail.pl?subscriptionid=$subscriptionid");
}
letter_loop($subs->{'letter'}, $template);
$nextexpected = GetNextExpected($subscriptionid);
$nextexpected->{'isfirstissue'} = $nextexpected->{planneddate}->output('iso') eq $firstissuedate ;
- $subs->{nextacquidate} = $nextexpected->{planneddate}->output() if($op eq 'mod');
+ $subs->{nextacquidate} = $nextexpected->{planneddate}->output() if($op eq 'modify');
unless($op eq 'modsubscription') {
foreach my $length_unit qw(numberlength weeklength monthlength){
if ($subs->{$length_unit}){
$op => 1,
"subtype_$sub_on" => 1,
sublength =>$sub_length,
- history => ($op eq 'mod'),
+ history => ($op eq 'modify'),
"periodicity".$subs->{'periodicity'} => 1,
"numberpattern".$subs->{'numberpattern'} => 1,
firstacquiyear => substr($firstissuedate,0,4),
}
$template->param(subtype => \@sub_type_data);
- letter_loop( '', $template ) if ($op ne 'modsubscription' && $op ne 'dup' && $op ne 'mod');
+ letter_loop( '', $template ) if ($op ne 'modsubscription' && $op ne 'dup' && $op ne 'modify');
my $new_biblionumber = $query->param('biblionumber_for_new_subscription');
if (defined $new_biblionumber) {
$template->param(patron_reason_loop=>$patron_reason_loop);
#Budgets management
-my $searchbudgets={ budget_branchcode=>$branchfilter} if $branchfilter;
-my $budgets = GetBudgets($searchbudgets);
+my $budgets = [];
+if ($branchfilter) {
+ my $searchbudgets = { budget_branchcode => $branchfilter };
+ $budgets = GetBudgets($searchbudgets);
+} else {
+ $budgets = GetBudgets(undef);
+}
-foreach my $budget (@$budgets){
+foreach my $budget ( @{$budgets} ) {
+## Please see file perltidy.ERR
$budget->{'selected'}=1 if ($$suggestion_ref{'budgetid'} && $budget->{'budget_id'} eq $$suggestion_ref{'budgetid'})
};
--- /dev/null
+#!/usr/bin/perl
+#
+# 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., 59 Temple Place,
+# Suite 330, Boston, MA 02111-1307 USA
+#
+# for context, see http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=2691
+
+use strict;
+use warnings;
+
+use Test::More tests => 2;
+
+BEGIN {
+ use_ok('C4::Labels::Label');
+}
+
+my $format_string = "title, callnumber";
+my $parsed_fields = C4::Labels::Label::_get_text_fields($format_string);
+my $expected_fields = [
+ { code => 'title', desc => 'title' },
+ { code => 'itemcallnumber', desc => 'itemcallnumber' },
+];
+is_deeply($parsed_fields, $expected_fields, '"callnumber" in label layout alias for "itemcallnumber" per bug 5653');
push @itemtypesloop, \%row;
}
my @branchloop;
- for my $thisbranch (sort { $branches->{$a}->{branchname} cmp $branches->{$b}->{branchname} } keys %$branches) {
- my $selected = 1 if $thisbranch eq $branch;
- my %row = (
- value => $thisbranch,
- selected => $selected,
+ for my $thisbranch (
+ sort { $branches->{$a}->{branchname} cmp $branches->{$b}->{branchname} }
+ keys %{$branches}
+ ) {
+ push @branchloop,
+ { value => $thisbranch,
+ selected => $thisbranch eq $branch,
branchname => $branches->{$thisbranch}->{'branchname'},
- );
- push @branchloop, \%row;
+ };
}
-
+
$template->param(
branchloop => \@branchloop,
itemtypeloop => \@itemtypesloop,
$branch = C4::Context->userenv->{'branch'};
}
my $branchname = GetBranchName($branch);
-my $branches = GetBranches($onlymine);
+my $branches = GetBranches($onlymine);
my @branchloop;
-for my $thisbranch (sort { $branches->{$a}->{branchname} cmp $branches->{$b}->{branchname} } keys %$branches) {
- my $selected = 1 if $thisbranch eq $branch;
- my %row =(value => $thisbranch,
- selected => $selected,
- branchname => $branches->{$thisbranch}->{'branchname'},
- );
- push @branchloop, \%row;
+for my $thisbranch (
+ sort { $branches->{$a}->{branchname} cmp $branches->{$b}->{branchname} }
+ keys %{$branches} ) {
+ push @branchloop,
+ { value => $thisbranch,
+ selected => $thisbranch eq $branch,
+ branchname => $branches->{$thisbranch}->{'branchname'},
+ };
}
+
# branches calculated - put branch codes in a single string so they can be passed in a form
-my $branchcodes = join("|", keys %$branches);
+my $branchcodes = join '|', keys %{$branches};
# Get all the holidays
my $input = CGI->new();
our $csv = Text::CSV->new({binary => 1}); # binary needed for non-ASCII Unicode
-# push @feedback, {feedback=>1, name=>'backend', value=>$csv->backend, backend=>$csv->backend};
+#push @feedback, {feedback=>1, name=>'backend', value=>$csv->backend, backend=>$csv->backend}; #XXX
my ( $template, $loggedinuser, $cookie ) = get_template_and_user({
template_name => "tools/import_borrowers.tmpl",
}
if ($extended) {
my $attr_str = $borrower{patron_attributes};
+ $attr_str =~ s/\xe2\x80\x9c/"/g; # fixup double quotes in case we are passed smart quotes
+ $attr_str =~ s/\xe2\x80\x9d/"/g;
+ push @feedback, {feedback=>1, name=>'attribute string', value=>$attr_str, filename=>$uploadborrowers};
delete $borrower{patron_attributes}; # not really a field in borrowers, so we don't want to pass it to ModMember.
$patron_attributes = extended_attributes_code_value_arrayref($attr_str);
}
}
unless (ModMember(%borrower)) {
$invalid++;
+ # untill we have better error trapping, we have no way of knowing why ModMember errored out...
+ push @errors, {unknown_error => 1};
$template->param('lastinvalid'=>$borrower{'surname'}.' / '.$borrowernumber);
next LINE;
}
my $old_attributes = GetBorrowerAttributes($borrowernumber);
$patron_attributes = extended_attributes_merge($old_attributes, $patron_attributes); #TODO: expose repeatable options in template
}
- SetBorrowerAttributes($borrower{'borrowernumber'}, $patron_attributes);
+ push @errors, {unknown_error => 1} unless SetBorrowerAttributes($borrower{'borrowernumber'}, $patron_attributes);
}
$overwritten++;
$template->param('lastoverwritten'=>$borrower{'surname'}.' / '.$borrowernumber);
$template->param('lastimported'=>$borrower{'surname'}.' / '.$borrowernumber);
} else {
$invalid++;
+ push @errors, {unknown_error => 1};
$template->param('lastinvalid'=>$borrower{'surname'}.' / AddMember');
}
}
my $authorisedvalue_categories = '';
my $frameworks = getframeworks();
+$frameworks->{''} = {frameworkcode => ''}; # Add the default framework
+
for my $fwk (keys %$frameworks){
my $fwkcode = $frameworks->{$fwk}->{'frameworkcode'};
my $authcode = GetAuthValCode('items.location', $fwkcode);
if ( defined $input->param('compareinv2barcd') && ( ( $input->param('compareinv2barcd') eq 'on' ) && ( scalar @brcditems != scalar @$res ) ) && length($uploadbarcodes) > 0 ){
if ( scalar @brcditems > scalar @$res ){
for my $brcditem (@brcditems) {
- if (! grep(/$brcditem->{barcode}/, @$res) ){
+ if (! grep( $_->{barcode} =~ /$brcditem->{barcode}/ , @$res) ){
$brcditem->{notfoundkoha} = 1;
push @$res, $brcditem;
}
} else {
my @notfound;
for my $item (@$res) {
- if ( ! grep(/$item->{barcode}/, @brcditems) ){
+ if ( ! grep( $_->{barcode} =~ /$item->{barcode}/ , @brcditems) ){
$item->{notfoundbarcode} = 1;
push @notfound, $item;
}
push @{$field_selection}, add_fields('biblio','biblioitems'),
{value => q{}, text => '---ITEMS---' },
{value => 'items.content', text => 'items.content'},
- add_fields('borrowers');
+ add_fields('issues','borrowers');
}
$template->param(
my $table_prefix = $table . q|.|;
my $rows = C4::Context->dbh->selectall_arrayref($sql, { Slice => {} });
for my $row (@{$rows}) {
+ next if $row->{'Field'} eq 'timestamp'; # this is really an irrelevant field and there may be other common fields that should be excluded from the list
push @fields, {
value => $table_prefix . $row->{Field},
text => $table_prefix . $row->{Field},
if ( ($op eq 'Upload') && $uploadfile ) { # Case is important in these operational values as the template must use case to be visually pleasing!
my $dirname = File::Temp::tempdir( CLEANUP => 1);
$debug and warn "dirname = $dirname";
- my $filesuffix = $1 if $uploadfilename =~ m/(\..+)$/i;
+ my $filesuffix;
+ if ( $uploadfilename =~ m/(\..+)$/i ) {
+ my $filesuffix = $1;
+ }
( $tfh, $tempfile ) = File::Temp::tempfile( SUFFIX => $filesuffix, UNLINK => 1 );
$debug and warn "tempfile = $tempfile";
my ( @directories, $errors );
undef $srcimage; # This object can get big...
}
$debug and warn "Image is of mimetype $mimetype";
- my $dberror = PutPatronImage($cardnumber,$mimetype, $imgfile) if $mimetype;
- if ( !$dberror && $mimetype ) { # Errors from here on are fatal only to the import of a particular image, so don't bail, just note the error and keep going
+ my $dberror;
+ if ($mimetype) {
+ $dberror = PutPatronImage( $cardnumber, $mimetype, $imgfile );
+ }
+ if ( !$dberror && $mimetype ) { # Errors from here on are fatal only to the import of a particular image, so don't bail, just note the error and keep going
$count{count}++;
push @{ $count{filenames} }, { source => $filename, cardnumber => $cardnumber };
} elsif ( $dberror ) {
my $marcauthorsarray = GetMarcAuthors( $record, $marcflavour );
my $marcsubjctsarray = GetMarcSubjects( $record, $marcflavour );
- my @items = &GetItemsInfo( $biblionumber, 'opac' );
+ my @items = GetItemsInfo( $biblionumber );
$dat->{MARCNOTES} = $marcnotesarray;
$dat->{MARCSUBJCTS} = $marcsubjctsarray;