Bugzilla – Attachment 7641 Details for
Bug 7515
Authorized value code showing in OPAC for public note
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 7515 - authorized value code showing in opac for public note
Bug-7515---authorized-value-code-showing-in-opac-f.patch (text/plain), 1.73 KB, created by
Kyle M Hall
on 2012-02-14 18:12:09 UTC
(
hide
)
Description:
Bug 7515 - authorized value code showing in opac for public note
Filename:
MIME Type:
Creator:
Kyle M Hall
Created:
2012-02-14 18:12:09 UTC
Size:
1.73 KB
patch
obsolete
>From d5bc01be27643e65e96f038969b3b7897819c1d0 Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Tue, 14 Feb 2012 13:11:21 -0500 >Subject: [PATCH] Bug 7515 - authorized value code showing in opac for public note > >This alters C4::Items::GetItemsInfo() to look up the authorised value >for the itemnotes value if the field has been assigned an authorised >value rather than being a free text field. >--- > C4/Items.pm | 22 ++++++++++++++++++++++ > 1 files changed, 22 insertions(+), 0 deletions(-) > >diff --git a/C4/Items.pm b/C4/Items.pm >index 04cb417..11fe4b4 100644 >--- a/C4/Items.pm >+++ b/C4/Items.pm >@@ -1269,6 +1269,28 @@ sub GetItemsInfo { > $data->{notforloanvalue} = $lib; > } > >+ # get itemnotes authorised value if applicable >+ my $sql_itemnotes = " >+ SELECT authorised_value >+ FROM marc_subfield_structure >+ WHERE kohafield = 'items.itemnotes' >+ AND frameworkcode = ? >+ "; >+ my $sth_itemnotes = $dbh->prepare( $sql_itemnotes ); >+ $sth_itemnotes->execute( $data->{'frameworkcode'} ); >+ >+ my ($authorised_valuecode) = $sth_itemnotes->fetchrow; >+ if ($authorised_valuecode) { >+ $sth_itemnotes = $dbh->prepare( >+ "SELECT lib FROM authorised_values >+ WHERE category=? >+ AND authorised_value=?" >+ ); >+ $sth_itemnotes->execute( $authorised_valuecode, $data->{'itemnotes'} ); >+ my ($lib) = $sth_itemnotes->fetchrow; >+ $data->{'itemnotes'} = $lib; >+ } >+ > # get restricted status and description if applicable > my $restrictedstatus = $dbh->prepare( > 'SELECT authorised_value >-- >1.7.2.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 7515
:
7641
|
7643
|
7644
|
7702
|
7833
|
7893
|
7918
|
7924
|
8182
|
8214