Bugzilla – Attachment 153137 Details for
Bug 33105
Add vendor issues
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 33105: Redirect to 404 if no vendor exists
Bug-33105-Redirect-to-404-if-no-vendor-exists.patch (text/plain), 1.94 KB, created by
Marcel de Rooy
on 2023-07-07 09:15:48 UTC
(
hide
)
Description:
Bug 33105: Redirect to 404 if no vendor exists
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2023-07-07 09:15:48 UTC
Size:
1.94 KB
patch
obsolete
>From 8691529c5ce26fd6a71eb65188f2dddaa93f7e33 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Fri, 7 Jul 2023 10:03:36 +0200 >Subject: [PATCH] Bug 33105: Redirect to 404 if no vendor exists >Content-Type: text/plain; charset=utf-8 > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > acqui/vendor_issues.pl | 5 +++++ > .../intranet-tmpl/prog/en/modules/acqui/vendor_issues.tt | 3 ++- > 2 files changed, 7 insertions(+), 1 deletion(-) > >diff --git a/acqui/vendor_issues.pl b/acqui/vendor_issues.pl >index 561769c28e..48a8ef703e 100755 >--- a/acqui/vendor_issues.pl >+++ b/acqui/vendor_issues.pl >@@ -48,6 +48,11 @@ if ( $issue_id ) { > } > my $vendor = Koha::Acquisition::Booksellers->find($booksellerid); > >+unless ( $vendor ) { >+ print $input->redirect("/cgi-bin/koha/errors/404.pl"); >+ exit; >+} >+ > if ( $op eq 'add_form' || $op eq 'show' ) { > $template->param( issue => $issue ); > } elsif ( $op eq 'add_validate' ) { >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/vendor_issues.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/vendor_issues.tt >index 4a6a672875..0a9de738a7 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/vendor_issues.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/vendor_issues.tt >@@ -137,7 +137,8 @@ > <input type="hidden" name="issue_id" value="[% issue.issue_id | html %]" /> > <button type="submit" class="approve"><i class="fa fa-fw fa-check"></i> Yes, delete</button> > </form> >- <form action="/cgi-bin/koha/acqui/vendor_issues.pl?booksellerid=[% vendor.id | uri %]" method="get"> >+ <form action="/cgi-bin/koha/acqui/vendor_issues.pl" method="get"> >+ <input type="hidden" name="booksellerid" value="[% vendor.id | html %]" /> > <button type="submit" class="deny"><i class="fa fa-fw fa-remove"></i> No, do not delete</button> > </form> > </div> >-- >2.30.2
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 33105
:
149509
|
149510
|
149511
|
149512
|
149513
|
149514
|
149515
|
149530
|
149531
|
149532
|
149556
|
149557
|
149558
|
149559
|
149560
|
149561
|
149562
|
152894
|
152895
|
152896
|
152897
|
152898
|
152899
|
152900
|
153117
|
153118
|
153119
|
153122
|
153123
|
153125
|
153126
|
153127
|
153128
|
153129
|
153130
|
153131
|
153132
|
153133
|
153134
|
153135
|
153136
| 153137 |
153730
|
153731