Bugzilla – Attachment 47895 Details for
Bug 15797
C4::Koha::GetKohaImageurlFromAuthorisedValues is no longer in use
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 15797: Remove C4::Koha::GetKohaImageurlFromAuthorisedValues
Bug-15797-Remove-C4KohaGetKohaImageurlFromAuthoris.patch (text/plain), 2.54 KB, created by
Jonathan Druart
on 2016-02-11 13:55:56 UTC
(
hide
)
Description:
Bug 15797: Remove C4::Koha::GetKohaImageurlFromAuthorisedValues
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2016-02-11 13:55:56 UTC
Size:
2.54 KB
patch
obsolete
>From 84b6b0ce7bfadfd3cee90cc035ba24debb7bd946 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Wed, 10 Feb 2016 15:51:02 +0000 >Subject: [PATCH] Bug 15797: Remove > C4::Koha::GetKohaImageurlFromAuthorisedValues > >This subroutine is no longer in used and can be remove. > >Test plan: > git grep GetKohaImageurlFromAuthorisedValues >should not return any results. >--- > C4/Koha.pm | 20 -------------------- > t/db_dependent/Koha.t | 5 ++--- > 2 files changed, 2 insertions(+), 23 deletions(-) > >diff --git a/C4/Koha.pm b/C4/Koha.pm >index 353708b..d5d1501 100644 >--- a/C4/Koha.pm >+++ b/C4/Koha.pm >@@ -64,7 +64,6 @@ BEGIN { > &GetKohaAuthorisedValuesMapping > &GetKohaAuthorisedValueLib > &GetAuthorisedValueByCode >- &GetKohaImageurlFromAuthorisedValues > &GetAuthValCode > &AddAuthorisedValue > &GetNormalizedUPC >@@ -1060,25 +1059,6 @@ sub displayServers { > return \@primaryserverloop; > } > >- >-=head2 GetKohaImageurlFromAuthorisedValues >- >-$authhorised_value = GetKohaImageurlFromAuthorisedValues( $category, $authvalcode ); >- >-Return the first url of the authorised value image represented by $lib. >- >-=cut >- >-sub GetKohaImageurlFromAuthorisedValues { >- my ( $category, $lib ) = @_; >- my $dbh = C4::Context->dbh; >- my $sth = $dbh->prepare("SELECT imageurl FROM authorised_values WHERE category=? AND lib =?"); >- $sth->execute( $category, $lib ); >- while ( my $data = $sth->fetchrow_hashref ) { >- return $data->{'imageurl'}; >- } >-} >- > =head2 GetAuthValCode > > $authvalcode = GetAuthValCode($kohafield,$frameworkcode); >diff --git a/t/db_dependent/Koha.t b/t/db_dependent/Koha.t >index c013434..048185a 100644 >--- a/t/db_dependent/Koha.t >+++ b/t/db_dependent/Koha.t >@@ -21,7 +21,7 @@ $dbh->{AutoCommit} = 0; > $dbh->{RaiseError} = 1; > > subtest 'Authorized Values Tests' => sub { >- plan tests => 8; >+ plan tests => 7; > > my $data = { > category => 'CATEGORY', >@@ -39,10 +39,9 @@ subtest 'Authorized Values Tests' => sub { > > # Tests > SKIP: { >- skip "INSERT failed", 5 unless $insert_success; >+ skip "INSERT failed", 4 unless $insert_success; > > is ( GetAuthorisedValueByCode($data->{category}, $data->{authorised_value}), $data->{lib}, "GetAuthorisedValueByCode" ); >- is ( GetKohaImageurlFromAuthorisedValues($data->{category}, $data->{lib}), $data->{imageurl}, "GetKohaImageurlFromAuthorisedValues" ); > > my $sortdet=C4::Members::GetSortDetails("lost", "3"); > is ($sortdet, "Lost and Paid For", "lost and paid works"); >-- >2.1.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 15797
:
47895
|
47928
|
47950