Bugzilla – Attachment 5708 Details for
Bug 6972
Hardcoded template paths to en in showmarc
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Fix lang path
0001-Fix-to-use-the-good-themelang-instead-of-the-hardcod.patch (text/plain), 1.92 KB, created by
Maxime Pelletier
on 2011-10-04 20:51:21 UTC
(
hide
)
Description:
Fix lang path
Filename:
MIME Type:
Creator:
Maxime Pelletier
Created:
2011-10-04 20:51:21 UTC
Size:
1.92 KB
patch
obsolete
>From 0eee40410ec67f8734c3a6cc12d409de69789667 Mon Sep 17 00:00:00 2001 >From: Maxime Pelletier <maxime.pelletier@libeo.com> >Date: Tue, 4 Oct 2011 14:32:08 -0400 >Subject: [PATCH] Fix to use the good themelang instead of the hardcoded one in showmarc > >--- > catalogue/showmarc.pl | 8 ++++++-- > opac/opac-showmarc.pl | 7 +++++-- > 2 files changed, 11 insertions(+), 4 deletions(-) > >diff --git a/catalogue/showmarc.pl b/catalogue/showmarc.pl >index bd557e9..7a69c8d 100755 >--- a/catalogue/showmarc.pl >+++ b/catalogue/showmarc.pl >@@ -63,11 +63,15 @@ if($importid) { > $xmlrecord = $record->as_xml(); > } > } >- >+ > if($view eq 'card') { >+ >+my $themelang = $template->param('themelang'); >+$themelang =~ s/^\/intranet-tmpl//; >+ > $xmlrecord = GetXmlBiblio($biblionumber) unless $xmlrecord; > >-my $xslfile = C4::Context->config('intrahtdocs')."/prog/en/xslt/compact.xsl"; >+my $xslfile = C4::Context->config('intrahtdocs').$themelang."/xslt/compact.xsl"; > my $parser = XML::LibXML->new(); > my $xslt = XML::LibXSLT->new(); > my $source = $parser->parse_string($xmlrecord); >diff --git a/opac/opac-showmarc.pl b/opac/opac-showmarc.pl >index 4475512..c3c6bf8 100755 >--- a/opac/opac-showmarc.pl >+++ b/opac/opac-showmarc.pl >@@ -66,11 +66,14 @@ if ($importid) { > if ($view eq 'card' || $view eq 'html') { > $xmlrecord = GetXmlBiblio($biblionumber) unless $xmlrecord; > my $xslfile; >+ my $themelang = $template->param('themelang'); >+ $themelang =~ s/^\/opac-tmpl//; >+ > if ($view eq 'card'){ >- $xslfile = C4::Context->config('opachtdocs')."/prog/en/xslt/compact.xsl"; >+ $xslfile = C4::Context->config('opachtdocs').$themelang."/xslt/compact.xsl"; > } > else { # must be html >- $xslfile = C4::Context->config('opachtdocs')."/prog/en/xslt/MARC21slim2OPACMARCdetail.xsl"; >+ $xslfile = C4::Context->config('opachtdocs').$themelang."/xslt/MARC21slim2OPACMARCdetail.xsl"; > } > my $parser = XML::LibXML->new(); > my $xslt = XML::LibXSLT->new(); >-- >1.5.6.5 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 6972
:
5708
|
5778
|
5867