Bugzilla – Attachment 67158 Details for
Bug 18584
Our legacy code contains trailing-spaces
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 13208: [FOLLOW-UP] Creating and implementing new Koha::Acquisition::Basket[s] modules
Bug-13208-FOLLOW-UP-Creating-and-implementing-new-.patch (text/plain), 3.89 KB, created by
David Bourgault
on 2017-09-15 19:33:13 UTC
(
hide
)
Description:
Bug 13208: [FOLLOW-UP] Creating and implementing new Koha::Acquisition::Basket[s] modules
Filename:
MIME Type:
Creator:
David Bourgault
Created:
2017-09-15 19:33:13 UTC
Size:
3.89 KB
patch
obsolete
>From f864029b019d308d52717d97b5a6cec662478cbd Mon Sep 17 00:00:00 2001 >From: Aleisha Amohia <aleishaamohia@hotmail.com> >Date: Thu, 27 Jul 2017 01:54:35 +0000 >Subject: [PATCH] Bug 13208: [FOLLOW-UP] Creating and implementing new > Koha::Acquisition::Basket[s] modules > >Test plan remains the same. > >Sponsored-by: Catalyst IT > >Signed-off-by: Owen Leonard <oleonard@myacpl.org> > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> > >Signed-off-by: David Bourgault <david.bourgault@inlibro.com> > >https://bugs.koha-community.org/show_bug.cgi?id=18584 >--- > Koha/Acquisition/Basket.pm | 19 +++++++++++++++++++ > Koha/Acquisition/Baskets.pm | 18 ++++++++++++++++++ > acqui/cancelorder.pl | 3 ++- > .../prog/en/modules/acqui/cancelorder.tt | 4 ++-- > 4 files changed, 41 insertions(+), 3 deletions(-) > create mode 100644 Koha/Acquisition/Basket.pm > create mode 100644 Koha/Acquisition/Baskets.pm > >diff --git a/Koha/Acquisition/Basket.pm b/Koha/Acquisition/Basket.pm >new file mode 100644 >index 0000000..ae95d2c >--- /dev/null >+++ b/Koha/Acquisition/Basket.pm >@@ -0,0 +1,19 @@ >+package Koha::Acquisition::Basket; >+ >+use Modern::Perl; >+ >+use Koha::Database; >+ >+use base qw( Koha::Object ); >+ >+sub bookseller { >+ my ($self) = @_; >+ my $bookseller_rs = $self->_result->booksellerid; >+ return Koha::Acquisition::Bookseller->_new_from_dbic( $bookseller_rs ); >+} >+ >+sub _type { >+ return 'Aqbasket'; >+} >+ >+1; >diff --git a/Koha/Acquisition/Baskets.pm b/Koha/Acquisition/Baskets.pm >new file mode 100644 >index 0000000..ebeb6c7 >--- /dev/null >+++ b/Koha/Acquisition/Baskets.pm >@@ -0,0 +1,18 @@ >+package Koha::Acquisition::Baskets; >+ >+use Modern::Perl; >+ >+use Koha::Database; >+use Koha::Acquisition::Basket; >+ >+use base qw( Koha::Objects ); >+ >+sub _type { >+ return 'Aqbasket'; >+} >+ >+sub object_class { >+ return 'Koha::Acquisition::Basket'; >+} >+ >+1; >diff --git a/acqui/cancelorder.pl b/acqui/cancelorder.pl >index 61d63c5..bb5086b 100755 >--- a/acqui/cancelorder.pl >+++ b/acqui/cancelorder.pl >@@ -35,6 +35,7 @@ use CGI; > use C4::Auth; > use C4::Output; > use C4::Acquisition; >+use Koha::Acquisition::Baskets; > > my $input = new CGI; > my ($template, $loggedinuser, $cookie, $flags) = get_template_and_user( { >@@ -50,7 +51,7 @@ my $action = $input->param('action'); > my $ordernumber = $input->param('ordernumber'); > my $biblionumber = $input->param('biblionumber'); > my $basketno = $input->param('basketno'); >-my $basket = Koha::Database->new()->schema()->resultset('Aqbasket')->find($basketno); >+my $basket = Koha::Acquisition::Baskets->find({ basketno => $basketno }, { prefetch => 'booksellerid' }); > my $referrer = $input->param('referrer') || $input->referer; > my $del_biblio = $input->param('del_biblio') ? 1 : 0; > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/cancelorder.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/cancelorder.tt >index c14748d..bae859b 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/cancelorder.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/cancelorder.tt >@@ -9,8 +9,8 @@ > <div id="breadcrumbs"> > <a href="/cgi-bin/koha/mainpage.pl">Home</a> › > <a href="/cgi-bin/koha/acqui/acqui-home.pl">Acquisitions</a> › >- <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% basket.booksellerid.id %]">[% basket.booksellerid.name | html %]</a> › >- <a href="/cgi-bin/koha/acqui/basket.pl?basketno=[% basket.basketno %]">Basket [% basket.basketname | html %] ([% basket.basketno %]) for [% basket.booksellerid.name | html %]</a> › >+ <a href="/cgi-bin/koha/acqui/supplier.pl?booksellerid=[% basket.bookseller.id %]">[% basket.bookseller.name | html %]</a> › >+ <a href="/cgi-bin/koha/acqui/basket.pl?basketno=[% basket.basketno %]">Basket [% basket.basketname | html %] ([% basket.basketno %]) for [% basket.bookseller.name | html %]</a> › > Cancel order > </div> > >-- >2.7.4
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 18584
:
64236
|
64237
|
64238
|
67095
|
67096
|
67097
|
67157
|
67158
|
67159
|
67160
|
67161
|
79734
|
79743
|
79758
|
79811
|
79953
|
81990
|
82337
|
82347
|
85966
|
85967
|
85968
|
87746
|
87750
|
87775
|
175456
|
175458
|
175610