[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Koha-cvs] CVS: koha/C4 SearchMarc.pm,1.36.2.11,1.36.2.12
From: |
Joshua Ferraro |
Subject: |
[Koha-cvs] CVS: koha/C4 SearchMarc.pm,1.36.2.11,1.36.2.12 |
Date: |
Fri, 01 Jul 2005 11:26:13 -0700 |
Update of /cvsroot/koha/koha/C4
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4657
Modified Files:
Tag: rel_2_2
SearchMarc.pm
Log Message:
Adds new sub getMARCurls which allows opac-detail.pl to display
Table of Contents and Descriptions when they exist in the MARC
record (in 856u).
Index: SearchMarc.pm
===================================================================
RCS file: /cvsroot/koha/koha/C4/SearchMarc.pm,v
retrieving revision 1.36.2.11
retrieving revision 1.36.2.12
diff -C2 -r1.36.2.11 -r1.36.2.12
*** SearchMarc.pm 6 Jun 2005 15:23:35 -0000 1.36.2.11
--- SearchMarc.pm 1 Jul 2005 18:26:10 -0000 1.36.2.12
***************
*** 42,46 ****
@ISA = qw(Exporter);
! @EXPORT = qw(&catalogsearch &findseealso &findsuggestion &getMARCnotes
&getMARCsubjects);
=head1 findsuggestion($dbh,$values);
--- 42,46 ----
@ISA = qw(Exporter);
! @EXPORT = qw(&catalogsearch &findseealso &findsuggestion &getMARCurls
&getMARCnotes &getMARCsubjects);
=head1 findsuggestion($dbh,$values);
***************
*** 164,168 ****
--- 164,173 ----
=cut
+ =head2 my $marcurlsarray = &getMARCurls($dbh,$bibid,$marcflavour);
+ Returns a reference to an array containing all the URLS stored in the MARC
database for the given bibid.
+ $marcflavour ("MARC21" or "UNIMARC") isn't used in this version because both
flavours of MARC use the same subfield for URLS (but eventually when we get the
lables working we'll need to change this.
+
+ =cut
sub catalogsearch {
my ($dbh, $tags, $and_or, $excluding, $operator, $value,
$offset,$length,$orderby,$desc_or_asc) = @_;
***************
*** 612,615 ****
--- 617,638 ----
} #end getMARCsubjects
+ sub getMARCurls {
+ # same for MARC21 and UNIMARC with current functionality
+ # FIXME: really, this is a temporary hack
+ my ($dbh, $bibid, $marcflavour) = @_;
+ my $sth=$dbh->prepare("SELECT subfieldvalue FROM marc_subfield_table WHERE
bibid=? AND tag = '856' and subfieldcode = 'u'");
+ $sth->execute($bibid);
+ my @marcurls;
+ while (my $data=$sth->fetchrow_array) {
+ my %line;
+ $line{MARCURL} = $data;
+ push @marcurls, \%line;
+ }
+ $sth->finish;
+ $dbh->disconnect;
+ my address@hidden;
+ return $marcurlsarray;
+ } #end getMARCurls
+
END { } # module clean-up code here (global destructor)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Koha-cvs] CVS: koha/C4 SearchMarc.pm,1.36.2.11,1.36.2.12,
Joshua Ferraro <=
- Prev by Date:
[Koha-cvs] CVS: koha/koha-tmpl/intranet-tmpl/npl/en/help/circ circulation.tmpl,NONE,1.1.2.1 returns.tmpl,NONE,1.1.2.1
- Next by Date:
[Koha-cvs] CVS: koha/opac opac-detail.pl,1.14.2.4,1.14.2.5
- Previous by thread:
[Koha-cvs] CVS: koha/koha-tmpl/intranet-tmpl/npl/en/help/circ circulation.tmpl,NONE,1.1.2.1 returns.tmpl,NONE,1.1.2.1
- Next by thread:
[Koha-cvs] CVS: koha/opac opac-detail.pl,1.14.2.4,1.14.2.5
- Index(es):