From 318fafb0c8da8c4d5d03bb0053e83764a4ade18a Mon Sep 17 00:00:00 2001 From: Baptiste Wojtkowski Date: Fri, 8 Aug 2025 14:34:51 +0000 Subject: [PATCH] Bug 39721: tidy --- .../prog/en/modules/suggestion/suggestion.tt | 13 ++++++++++++- suggestion/suggestion.pl | 15 +++++++-------- 2 files changed, 19 insertions(+), 9 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt index f146e1e5c9..7ec2b023d1 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt @@ -535,7 +535,18 @@ - [% INCLUDE 'date-format.inc' %] + + + [% INCLUDE 'date-format.inc' %] + [% IF ( suggestion.suggester.borrowernumber ) %] diff --git a/suggestion/suggestion.pl b/suggestion/suggestion.pl index e4009a9e33..a604c43bd2 100755 --- a/suggestion/suggestion.pl +++ b/suggestion/suggestion.pl @@ -99,7 +99,7 @@ my $columns = ' ' . join( ' ', $schema->source('Suggestion')->columns ) my $suggestion_only = { map { $columns =~ / $_ / ? ( $_ => $suggestion_ref->{$_} ) : () } keys %$suggestion_ref }; $suggestion_only->{STATUS} = $suggestion_ref->{STATUS}; - qw( suggestedbyme op displayby tabcode notify filter_archived koha_login_context auth_forwarded_hash password userid ); +qw( suggestedbyme op displayby tabcode notify filter_archived koha_login_context auth_forwarded_hash password userid ); delete $suggestion_only->{branchcode} if $suggestion_only->{branchcode} eq '__ANY__'; delete $suggestion_only->{budgetid} if $suggestion_only->{budgetid} eq '__ANY__'; @@ -256,9 +256,9 @@ if ( $op =~ /cud-save/ ) { } elsif ( $op eq 'add_form' ) { $template->param( - default_suggester => $librarian, - default_suggesteddate => dt_from_string, - default_branch => C4::Context->userenv->{"branch"}, + default_suggester => $librarian, + default_suggesteddate => dt_from_string, + default_branch => C4::Context->userenv->{"branch"}, ); $op = 'save'; } elsif ( $op eq 'edit_form' ) { @@ -272,9 +272,9 @@ if ( $op =~ /cud-save/ ) { } $other_reason = 0 unless $stored_suggestion->reason; $template->param( - other_reason => $other_reason, - default_manageddate => dt_from_string, - default_branch => C4::Context->userenv->{"branch"}, + other_reason => $other_reason, + default_manageddate => dt_from_string, + default_branch => C4::Context->userenv->{"branch"}, ); $op = 'save'; } elsif ( $op eq "cud-update_status" ) { @@ -498,7 +498,6 @@ $template->param( reasonsloop => $reasonsloop, ); - if ( defined($returnsuggested) and $returnsuggested ne "no_one" ) { print $input->redirect( "/cgi-bin/koha/members/moremember.pl?borrowernumber=" . $returnsuggested . "#suggestions" ); } -- 2.43.0