Bug 33105: Redirect to 404 if no vendor exists
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This commit is contained in:
parent
2f5883c997
commit
6a55fad7b4
2 changed files with 7 additions and 1 deletions
|
@ -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' ) {
|
||||
|
|
|
@ -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>
|
||||
|
|
Loading…
Reference in a new issue