Adding Branch Independancy.
[koha.git] / opac / opac-moredetail.pl
index 49b6b57..214d13e 100755 (executable)
@@ -10,6 +10,8 @@ use C4::Koha;
 use C4::Output;
 use C4::Acquisitions;
 use C4::Biblio;
+use C4::Date;
+use HTML::Template;
 
 use CGI;
 my $input = new CGI;
@@ -43,14 +45,14 @@ my $count=@items;
 my $i=0;
 print center();
 
-my $dewey = $data->{'dewey'};                                                  
-$dewey =~ s/0+$//;                                                             
-if ($dewey eq "000.") { $dewey = "";};                                         
-if ($dewey < 10){$dewey='00'.$dewey;}                                          
-if ($dewey < 100 && $dewey > 10){$dewey='0'.$dewey;}                           
+my $dewey = $data->{'dewey'};
+$dewey =~ s/0+$//;
+if ($dewey eq "000.") { $dewey = "";};
+if ($dewey < 10){$dewey='00'.$dewey;}
+if ($dewey < 100 && $dewey > 10){$dewey='0'.$dewey;}
 if ($dewey <= 0){
-  $dewey='';                                                                   
-}               
+  $dewey='';
+}
 $dewey=~ s/\.$//;
 print <<printend
 <br>
@@ -73,8 +75,8 @@ print <<printend
 </TR>
 <tr VALIGN=TOP  >
 <TD width=210 >
-<INPUT TYPE="image" name="submit"  VALUE="modify" height=42  WIDTH=93 BORDER=0 src="/images/modify-mem.gif"> 
-<INPUT TYPE="image" name="delete"  VALUE="delete" height=42  WIDTH=93 BORDER=0 src="/images/delete-mem.gif"> 
+<INPUT TYPE="image" name="submit"  VALUE="modify" height=42  WIDTH=93 BORDER=0 src="/images/modify-mem.gif">
+<INPUT TYPE="image" name="delete"  VALUE="delete" height=42  WIDTH=93 BORDER=0 src="/images/delete-mem.gif">
 <br>
 <FONT SIZE=2  face="arial, helvetica">
 <b>Biblionumber:</b> $bib<br>
@@ -97,7 +99,7 @@ printend
 ;
 if ($type eq 'catmain'){
   print "<br><a href=/cgi-bin/koha/maint/shiftbib.pl?bi=$data->{'biblioitemnumber'}&bib=$data->{'biblionumber'}>Shift to another biblio</a>";
+
 }
 print <<printend
 
@@ -112,7 +114,7 @@ printend
 for (my $i=0;$i<$count;$i++){
 print <<printend
 <img src="/images/holder.gif" width=16 height=300 align=left>
-<TABLE  CELLSPACING=0  CELLPADDING=5 border=1 align=left width=220 >                           
+<TABLE  CELLSPACING=0  CELLPADDING=5 border=1 align=left width=220 >
 <TR VALIGN=TOP>
 <td  bgcolor="99cc33" background="/images/background-mem.gif"><B>BARCODE $items[$i]->{'barcode'}</b></TD>
 </TR>
@@ -122,8 +124,8 @@ print <<printend
 <input type=hidden name=bibitem value=$bi>
 <input type=hidden name=item value=$items[$i]->{'itemnumber'}>
 <input type=hidden name=type value=$type>
-<INPUT TYPE="image" name="submit"  VALUE="modify" height=42  WIDTH=93 BORDER=0 src="/images/modify-mem.gif"> 
-<INPUT TYPE="image" name="delete"  VALUE="delete" height=42  WIDTH=93 BORDER=0 src="/images/delete-mem.gif"> 
+<INPUT TYPE="image" name="submit"  VALUE="modify" height=42  WIDTH=93 BORDER=0 src="/images/modify-mem.gif">
+<INPUT TYPE="image" name="delete"  VALUE="delete" height=42  WIDTH=93 BORDER=0 src="/images/delete-mem.gif">
 <br>
 printend
 ;
@@ -138,8 +140,8 @@ my $mon=substr($items[$i]->{'timestamp0'},4,2);
 my $day=substr($items[$i]->{'timestamp0'},6,2);
 $items[$i]->{'timestamp0'}="$day/$mon/$year";
 
-$items[$i]->{'dateaccessioned'} = slashifyDate($items[$i]->{'dateaccessioned'});
-$items[$i]->{'datelastseen'} = slashifyDate($items[$i]->{'datelastseen'});
+$items[$i]->{'dateaccessioned'} = format_date($items[$i]->{'dateaccessioned'});
+$items[$i]->{'datelastseen'} = format_date($items[$i]->{'datelastseen'});
 
 print <<printend
 <FONT SIZE=2  face="arial, helvetica">