[Koha-cvs] koha koha-tmpl/opac-tmpl/prog/en/opac-main.tmpl... [rel_3_0]
Antoine Farnault
antoine at koha-fr.org
Mon Feb 5 19:33:30 CET 2007
CVSROOT: /sources/koha
Module name: koha
Branch: rel_3_0
Changes by: Antoine Farnault <toins> 07/02/05 18:33:30
Modified files:
koha-tmpl/opac-tmpl/prog/en: opac-main.tmpl
opac : opac-main.pl
Log message:
re-introducing the possibility to list the recent acquisition on the OPAC.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/koha/koha-tmpl/opac-tmpl/prog/en/opac-main.tmpl?cvsroot=koha&only_with_tag=rel_3_0&r1=1.1.2.14&r2=1.1.2.15
http://cvs.savannah.gnu.org/viewcvs/koha/opac/opac-main.pl?cvsroot=koha&only_with_tag=rel_3_0&r1=1.23.2.9&r2=1.23.2.10
Patches:
Index: koha-tmpl/opac-tmpl/prog/en/opac-main.tmpl
===================================================================
RCS file: /sources/koha/koha/koha-tmpl/opac-tmpl/prog/en/opac-main.tmpl,v
retrieving revision 1.1.2.14
retrieving revision 1.1.2.15
diff -u -b -r1.1.2.14 -r1.1.2.15
--- koha-tmpl/opac-tmpl/prog/en/opac-main.tmpl 30 Jan 2007 14:14:14 -0000 1.1.2.14
+++ koha-tmpl/opac-tmpl/prog/en/opac-main.tmpl 5 Feb 2007 18:33:30 -0000 1.1.2.15
@@ -41,6 +41,13 @@
<!-- TMPL_IF name="OpacCloud" -->
<li>Dig into <a href="/cgi-bin/koha/opac-tags_subject.pl">tag cloud</a></li>
<!-- /TMPL_IF -->
+ <li>
+ <form name="recent-acqui" action="/cgi-bin/koha/opac-main.pl" method="POST">
+ <label for="recentacqui">Get the last</label>
+ <input id="recentacqui" type="text" name="recentacqui" value="30" size="3"/>
+ acquisitions
+ <input type="submit" value=" OK " />
+ </li>
</ul>
</div>
@@ -62,4 +69,77 @@
</div>
<!-- /TMPL_IF -->
+<!-- TMPL_IF NAME="recentacquiloop"-->
+ <div class="searchresults">
+ <table>
+ <tr>
+ <th>
+ Title
+ </th>
+ <th>
+ Author
+ </th>
+ <th>
+ copyright
+ </th>
+ <th>
+ publication year
+ </th>
+ <th>
+ Date
+ </th>
+ </tr>
+ <!-- TMPL_LOOP NAME="recentacquiloop" -->
+ <tr>
+ <td>
+ <p>
+ <!-- TMPL_IF name="BiblioDefaultViewmarc" -->
+ <a class="title" href="/cgi-bin/koha/opac-MARCdetail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" ESCAPE="URL" -->">
+ <!-- TMPL_IF NAME="title"-->
+ <!-- TMPL_VAR NAME="title" -->
+ <!-- TMPL_ELSE -->
+ <span class="problem">(no title)</span>
+ <!-- /TMPL_IF -->
+ </a>
+ <!-- TMPL_ELSE -->
+ <!-- TMPL_IF name="BiblioDefaultViewisbd" -->
+ <a class="title" href="/cgi-bin/koha/opac-ISBDdetail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" ESCAPE="URL" -->">
+ <!-- TMPL_IF NAME="title"-->
+ <!-- TMPL_VAR NAME="title" -->
+ <!-- TMPL_ELSE -->
+ <span class="problem">(no title)</span>
+ <!-- /TMPL_IF -->
+ </a>
+ <!-- TMPL_ELSE -->
+ <a class="title" href="/cgi-bin/koha/opac-detail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" ESCAPE="URL" -->">
+ <!-- TMPL_IF NAME="title"-->
+ <!-- TMPL_VAR NAME="title" -->
+ <!-- TMPL_ELSE -->
+ <span class="problem">(no title)</span>
+ <!-- /TMPL_IF -->
+ </a>
+ <!-- /TMPL_IF -->
+ <!-- /TMPL_IF -->
+ </p>
+ </td>
+ <td>
+ <a href="/cgi-bin/koha/opac-search.pl?q=au:<!-- TMPL_VAR NAME="author" -->">
+ <!-- TMPL_VAR NAME="author" -->
+ </a>
+ </td>
+ <td>
+ <!-- TMPL_VAR NAME="copyrightdate" -->
+ </td>
+ <td>
+ <!-- TMPL_VAR NAME="publicationyear" -->
+ </td>
+ <td>
+ <!-- TMPL_VAR NAME="timestamp" -->
+ </td>
+ </tr>
+ <!-- /TMPL_LOOP -->
+ </table>
+ </div>
+<!-- /TMPL_IF -->
+
<!-- TMPL_INCLUDE NAME="opac-bottom.inc" -->
Index: opac/opac-main.pl
===================================================================
RCS file: /sources/koha/koha/opac/opac-main.pl,v
retrieving revision 1.23.2.9
retrieving revision 1.23.2.10
diff -u -b -r1.23.2.9 -r1.23.2.10
--- opac/opac-main.pl 10 Jan 2007 10:52:58 -0000 1.23.2.9
+++ opac/opac-main.pl 5 Feb 2007 18:33:30 -0000 1.23.2.10
@@ -15,7 +15,7 @@
# Koha; if not, write to the Free Software Foundation, Inc., 59 Temple Place,
# Suite 330, Boston, MA 02111-1307 USA
-# $Id: opac-main.pl,v 1.23.2.9 2007/01/10 10:52:58 toins Exp $
+# $Id: opac-main.pl,v 1.23.2.10 2007/02/05 18:33:30 toins Exp $
use strict;
require Exporter;
@@ -25,12 +25,15 @@
use C4::BookShelves;
use C4::Koha; # GetLanguages
use C4::Branch; # GetBranches
-use C4::Members;
+use C4::Members; # GetMember
use C4::NewsChannels; # get_opac_news
+use C4::Acquisition; # GetRecentAcqui
my $input = new CGI;
my $dbh = C4::Context->dbh;
+my $limit = $input->param('recentacqui');
+
my @branches;
my @select_branch;
my %select_branches;
@@ -57,6 +60,14 @@
}
);
+if($limit) {
+ my $recentacquiloop = GetRecentAcqui($limit);
+ warn Data::Dumper::Dumper($recentacquiloop);
+ $template->param(
+ recentacquiloop => $recentacquiloop,
+ );
+}
+
my $borrower = GetMember( '', $borrowernumber );
my @languages;
my $counter = 0;
More information about the Koha-cvs
mailing list