Bug 12280 - "Others..." reason for suggestions not showing in Bootstrap OPAC
authorOwen Leonard <oleonard@myacpl.org>
Thu, 22 May 2014 15:24:52 +0000 (11:24 -0400)
committerTomas Cohen Arazi <tomascohen@gmail.com>
Wed, 4 Jun 2014 20:57:44 +0000 (17:57 -0300)
If you accept or reject a suggestion using the "Others..." option and
entering a reason manually, the text is not showing up in the Bootstrap
OPAC theme as it does in CCSR and prog. This patch corrects the problem.

This patch also adds a missing [% USE AuthorisedValues %] which would
cause errors if the template tried to display a custom suggestion status
as defined in the SUGGEST_STATUS authorized value category.

To test, accept or reject a suggestion and specify a custom reason. View
that suggestion in the Bootstrap OPAC and confirm that the custom reason
is displayed.

Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-suggestions.tt

index 573cd37..f58dd00 100644 (file)
@@ -1,4 +1,5 @@
 [% USE Koha %]
+[% USE AuthorisedValues %]
 [% INCLUDE 'doc-head-open.inc' %][% IF ( LibraryNameTitle ) %][% LibraryNameTitle %][% ELSE %]Koha online[% END %] catalog &rsaquo;
 [% IF ( op_add ) %]Enter a new purchase suggestion[% END %]
 [% IF ( op_else ) %]Purchase Suggestions[% END %]
                                                         [% ELSIF ( suggestions_loo.REJECTED ) %]Suggestion declined
                                                         [% ELSIF ( suggestions_loo.AVAILABLE ) %]Available in the library
                                                         [% ELSE %] [% AuthorisedValues.GetByCode( 'SUGGEST_STATUS', suggestions_loo.STATUS, 1 ) %] [% END %]
+                                                        [% IF ( suggestions_loo.reason ) %]([% suggestions_loo.reason |html %])[% END %]
                                                     </td>
                                                 </tr>
                                             [% END # / FOREACH suggestions_loo %]