Bugzilla – Attachment 194397 Details for
Bug 39723
Remove GetSuggestionInfoFromBiblionumber from C4/Suggestions.pm
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 39723: (follow-up) only use the suggestion object in template params
Bug-39723-follow-up-only-use-the-suggestion-object.patch (text/plain), 6.11 KB, created by
Baptiste Wojtkowski (bwoj)
on 2026-03-03 15:50:00 UTC
(
hide
)
Description:
Bug 39723: (follow-up) only use the suggestion object in template params
Filename:
MIME Type:
Creator:
Baptiste Wojtkowski (bwoj)
Created:
2026-03-03 15:50:00 UTC
Size:
6.11 KB
patch
obsolete
>From bb3e788e4bb1a6c2ac1e427df28f5b1ac2644458 Mon Sep 17 00:00:00 2001 >From: Baptiste Wojtkowski <baptiste.wojtkowski@biblibre.com> >Date: Tue, 3 Mar 2026 15:48:53 +0000 >Subject: [PATCH] Bug 39723: (follow-up) only use the suggestion object in > template params > >--- > acqui/basket.pl | 4 +--- > acqui/parcel.pl | 4 +--- > .../intranet-tmpl/prog/en/modules/acqui/basket.tt | 10 ++++------ > .../intranet-tmpl/prog/en/modules/acqui/parcel.tt | 4 ++-- > 4 files changed, 8 insertions(+), 14 deletions(-) > >diff --git a/acqui/basket.pl b/acqui/basket.pl >index bcddc385228..aff8b22112e 100755 >--- a/acqui/basket.pl >+++ b/acqui/basket.pl >@@ -659,9 +659,7 @@ sub get_order_infos { > } > > my $suggestion = Koha::Suggestions->search( { biblionumber => $line{biblionumber} } )->single; >- $line{suggestionid} = $suggestion->suggestionid; >- $line{surnamesuggestedby} = $suggestion->suggester->surname; >- $line{firstnamesuggestedby} = $suggestion->suggester->firstname; >+ $line{suggestion} = $suggestion; > > $line{estimated_delivery_date} = $order->{estimated_delivery_date}; > >diff --git a/acqui/parcel.pl b/acqui/parcel.pl >index 3ed89728066..067eebd702d 100755 >--- a/acqui/parcel.pl >+++ b/acqui/parcel.pl >@@ -151,9 +151,7 @@ for my $order (@orders) { > $total_tax_included += get_rounded_price( $line{unitprice_tax_included} ) * $line{quantity}; > > my $suggestion = Koha::Suggestions->search( { biblionumber => $line{biblionumber} } )->single; >- $line{suggestionid} = $suggestion->suggestionid; >- $line{surnamesuggestedby} = $suggestion->suggester->surname; >- $line{firstnamesuggestedby} = $suggestion->suggester->firstname; >+ $line{suggestion} = $suggestion; > > if ( $line{parent_ordernumber} != $line{ordernumber} ) { > if ( grep { $_->{ordernumber} == $line{parent_ordernumber} } @orders ) { >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt >index bae154948a0..a908c7c071b 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt >@@ -834,12 +834,10 @@ > [% books_loo.copyrightdate | html %] > [% END -%] > [%- IF ( books_loo.editionstatement ) %], [% books_loo.editionstatement | html %][% END -%] >- [%- IF ( books_loo.suggestionid ) %] >+ [%- IF ( books_loo.suggestion ) %] > <br /> >- Suggested by: [% books_loo.surnamesuggestedby | html %][% IF ( books_loo.firstnamesuggestedby ) %], [% books_loo.firstnamesuggestedby | html %][% END %] (<a >- href="/cgi-bin/koha/suggestion/suggestion.pl?suggestionid=[% books_loo.suggestionid | uri %]&op=show" >- >suggestion #[% books_loo.suggestionid | html %]</a >- >) >+ Suggested by: [% books_loo.suggestion.suggester.surname | html %][% IF ( books_loo.suggestion.suggester.firstname ) %], [% books_loo.suggestion.suggester.firstname | html %][% END %] >+ (<a href="/cgi-bin/koha/suggestion/suggestion.pl?suggestionid=[% books_loo.suggestion.suggestionid | uri %]&op=show">suggestion #[% books_loo.suggestion.suggestionid | html %]</a>) > [% END %] > </p> > [% IF ( books_loo.order_internalnote ) %] >@@ -962,7 +960,7 @@ > <a href="#" class="transfer_order" data-ordernumber="[% books_loo.ordernumber | html %]">Transfer</a> > <br /> > [% END %] >- [% UNLESS ( books_loo.suggestionid ) %] >+ [% UNLESS ( books_loo.suggestion.suggestionid ) %] > <a > data-action="/cgi-bin/koha/acqui/newordersuggestion.pl" > data-booksellerid="[% booksellerid | html %]" >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/parcel.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/parcel.tt >index 1970eebf1e4..87b448efd6d 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/parcel.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/parcel.tt >@@ -238,9 +238,9 @@ > [% order.copyrightdate | html %] > [% END %] > [% END %] >- [% IF ( order.suggestionid ) %] >+ [% IF ( order.suggestion ) %] > <br /> >- Suggested by: [% order.surnamesuggestedby | html %][% IF ( order.firstnamesuggestedby ) %], [% order.firstnamesuggestedby | html %][% END %] (<a >+ Suggested by: [% order.suggestion.suggester.surname | html %][% IF ( order.suggestion.suggester.firstname ) %], [% order.suggestion.suggester.firstname | html %][% END %] (<a > href="/cgi-bin/koha/suggestion/suggestion.pl?suggestionid=[% order.suggestionid | uri %]&op=show" > >suggestion #[% order.suggestionid | html %]</a > >) >-- >2.43.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 39723
:
181404
|
181419
|
192164
|
193481
|
193495
| 194397