Bugzilla – Attachment 104086 Details for
Bug 25340
opac-review.pl doesn't show title when commenting
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 25340: Pass biblio object to OPAC comments template
Bug-25340-Pass-biblio-object-to-OPAC-comments-temp.patch (text/plain), 3.66 KB, created by
Owen Leonard
on 2020-05-01 13:05:00 UTC
(
hide
)
Description:
Bug 25340: Pass biblio object to OPAC comments template
Filename:
MIME Type:
Creator:
Owen Leonard
Created:
2020-05-01 13:05:00 UTC
Size:
3.66 KB
patch
obsolete
>From 2cca1d6f3f28ff843d7350b29ca65543a4902ef7 Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Fri, 1 May 2020 12:43:40 +0000 >Subject: [PATCH] Bug 25340: Pass biblio object to OPAC comments template > >This patch modifies the OPAC comments system so that the biblio object >is passed to the template. This allows the biblio-title include to >properly access the title and subtitle information. > >Unrelated change: Remove some custom CSS from the page which was >obsolete. > >To test, apply the patch and make sure the "reviewson" preference is >enabled. > >- Log in to the OPAC and open a bibliographic record's detail page. >- Under the "Comments" tab, click the "Post your comments" link to > trigger the pop-up window. >- In the pop-up window, verify that the item's title is correct in the > page title and the heading. Author should display correctly, if > present. >- Test submitting a comment and editing a comment. Everything should > work correctly. >--- > koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-review.tt | 11 ++++------- > opac/opac-review.pl | 3 +-- > 2 files changed, 5 insertions(+), 9 deletions(-) > >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-review.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-review.tt >index 98248169a2..863e4ac696 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-review.tt >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-review.tt >@@ -1,8 +1,5 @@ > [% INCLUDE 'doc-head-open.inc' %] >-<title>[% IF ( LibraryNameTitle ) %][% LibraryNameTitle | html %][% ELSE %]Koha online[% END %] catalog › Comments on [% title | html %]</title> >-<style> >- #custom-doc { width:37.08em;*width:36.16em;min-width:485px; margin:1em auto; text-align:left; } >-</style> >+<title>[% IF ( LibraryNameTitle ) %][% LibraryNameTitle | html %][% ELSE %]Koha online[% END %] catalog › Comments on [% INCLUDE 'biblio-title-head.inc' %]</title> > [% INCLUDE 'doc-head-close.inc' %] > [% BLOCK cssinclude %][% END %] > </head> >@@ -42,10 +39,10 @@ > </div> > [% END # / ERRORs %] > >- <h1>Comments on <i>[% INCLUDE 'biblio-title.inc' biblio=Stash.stash() %]</i></h1> >- [% IF ( author ) %]<h3>[% author | html %]</h3>[% END %] >+ <h1>Comments on <i>[% INCLUDE 'biblio-title.inc' %]</i></h1> >+ [% IF ( biblio.author ) %]<h3>[% biblio.author | html %]</h3>[% 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 | html %]" /> >+ <input type="hidden" name="biblionumber" value="[% biblio.biblionumber | html %]" /> > [% IF ( reviewid ) %]<input type="hidden" name="reviewid" value="[% reviewid | html %]" />[% END %] > <fieldset> > <textarea id="review" name="review" cols="60" rows="8">[% review | html %]</textarea> >diff --git a/opac/opac-review.pl b/opac/opac-review.pl >index 86a9848ba9..6c0ac3e688 100755 >--- a/opac/opac-review.pl >+++ b/opac/opac-review.pl >@@ -97,11 +97,10 @@ if( !@errors && defined $review ) { > $review = $clean; > $review ||= $savedreview->review if $savedreview; > $template->param( >- 'biblionumber' => $biblionumber, > 'borrowernumber' => $borrowernumber, > 'review' => $review, > 'reviewid' => $reviewid || 0, >- 'title' => $biblio->title, >+ 'biblio' => $biblio, > ); > > output_html_with_http_headers $query, $cookie, $template->output; >-- >2.11.0
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 25340
:
104086
|
104113
|
104116