Bug 7317: Do not use GET for deletion requests
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Thu, 9 Nov 2017 15:50:00 +0000 (12:50 -0300)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Thu, 9 Nov 2017 15:51:59 +0000 (12:51 -0300)
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt

index b0bbdcb..7739bd8 100644 (file)
 
                     <div class="dialog alert">
                         <h3>Are you sure you wish to delete this request?</h3>
-                        <p>
-                            <a class="btn btn-default btn-sm approve" href="?method=delete&amp;illrequest_id=[% request.id %]&amp;confirmed=1"><i class="fa fa-fw fa-check"></i>Yes</a>
-                            <a class="btn btn-default btn-sm deny" href="?method=illview&amp;illrequest_id=[% request.id %]"><i class="fa fa-fw fa-remove"></i>No</a>
-                        </p>
+                        <form action="/cgi-bin/koha/ill/ill-requests.pl" method="post">
+                            <input type="hidden" name="method" value="delete" />
+                            <input type="hidden" name="confirmed" value="1" />
+                            <input type="hidden" name="illrequest_id" value="[% request.id %]" />
+                            <button type="submit" class="btn btn-default btn-sm approve"><i class="fa fa-fw fa-check"></i> Yes, delete</button>
+                        </form>
+                        <a class="btn btn-default btn-sm deny" href="/cgi-bin/koha/ill/ill-requests.pl?method=illview&amp;illrequest_id=[% request.id %]"><i class="fa fa-fw fa-remove"></i>No, do not delete</a>
                     </div>
 
-
                 [% ELSIF query_type == 'illview' %]
                     [% actions = request.available_actions %]
                     [% capabilities = request.capabilities %]