Bugzilla – Attachment 54737 Details for
Bug 16752
Remove the use of event attributes from some acquisitions templates
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[SIGNED-OFF] Bug 16752 - Remove the use of event attributes from some acquisitions templates - Uncertain prices
SIGNED-OFF-Bug-16752---Remove-the-use-of-event-att.patch (text/plain), 4.64 KB, created by
Aleisha Amohia
on 2016-08-23 03:11:16 UTC
(
hide
)
Description:
[SIGNED-OFF] Bug 16752 - Remove the use of event attributes from some acquisitions templates - Uncertain prices
Filename:
MIME Type:
Creator:
Aleisha Amohia
Created:
2016-08-23 03:11:16 UTC
Size:
4.64 KB
patch
obsolete
>From c5e7594a5cef82e68232abea2a68cc62fc1855fb Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Wed, 15 Jun 2016 10:51:34 -0400 >Subject: [PATCH] [SIGNED-OFF] Bug 16752 - Remove the use of event attributes > from some acquisitions templates - Uncertain prices > >This patch modifies the acquisitions uncertain prices template to remove >event attributes onclick and onchange. > >Also changed on the uncertain prices page: Added a label to the orders >filter, removed redundant form submit function. > >- Locate a vendor which has orders with uncertain prices >- Click the 'Uncertain prices' tab in the left-hand sidebar >- Enter invalid data in the "price" field for any order. Confirm that an > error is triggered when the field loses focus. > >Signed-off-by: Aleisha Amohia <aleishaamohia@hotmail.com> >--- > .../prog/en/modules/acqui/uncertainprice.tt | 29 +++++++++------------- > 1 file changed, 12 insertions(+), 17 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/uncertainprice.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/uncertainprice.tt >index 1853805..6dbb71d 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/uncertainprice.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/uncertainprice.tt >@@ -13,18 +13,16 @@ > ], > "sPaginationType": "four_button" > } ) ); >+ $(".check_uncertain").on("change",function(){ >+ var form = document.getElementById("uncertainprices"); >+ var ordernumber = $(this).data("ordernumber"); >+ uncheckbox( form, ordernumber ); >+ }); > }); > var MSG_INVALIDPRICE = _("ERROR: Price is not a valid number, please check the price and try again!"); > //]]> > </script> > <script type="text/javascript" src="[% interface %]/[% theme %]/js/acq.js"></script> >-<script type="text/javascript"> >-//<![CDATA[ >-function check(form) { >- form.submit(); >-} >-//]]> >-</script> > </head> > <body id="acq_uncertainprice" class="acq"> > [% INCLUDE 'header.inc' %] >@@ -75,10 +73,10 @@ function check(form) { > [% END %] > > <h2>Orders with uncertain prices</h2> >- <form action="[% scriptname %]" method="post" name="uncertainprices"> >+ <form action="[% scriptname %]" method="post"> > <input type="hidden" name="booksellerid" value="[% booksellerid %]" /> >- Orders from: >- <select name="owner"> >+ <label for="owner">Orders from:</label> >+ <select id="owner" name="owner"> > [% IF ( owner ) %] > <option value="0">Everyone</option> > <option value="1" selected="selected">me</option> >@@ -89,7 +87,7 @@ function check(form) { > </select> > <input type="submit" value="Filter" /> > </form> >- <form action="[% scriptname %]" method="post" name="uncertainprices"> >+ <form action="[% scriptname %]" method="post" id="uncertainprices"> > <input type="hidden" name="booksellerid" value="[% booksellerid %]" /> > <input type="hidden" name="op" value="validate" /> > <table id="uncertainpricet"> >@@ -122,24 +120,21 @@ function check(form) { > <input type="checkbox" name="uncertainprice[% uncertainpriceorder.ordernumber %]" value="1" checked="checked" /> > </td> > <td> >- <input type="text" size="10" name="price[% uncertainpriceorder.ordernumber %]" value="[% uncertainpriceorder.listprice %]" >- onchange="uncheckbox(this.form, [% uncertainpriceorder.ordernumber %]);" /> >+ <input class="check_uncertain" data-ordernumber="[% uncertainpriceorder.ordernumber %]" type="text" size="10" name="price[% uncertainpriceorder.ordernumber %]" value="[% uncertainpriceorder.listprice %]" /> > </td> > <td> >- > [% IF Koha.Preference('AcqCreateItem') == 'ordering' %] > [% uncertainpriceorder.quantity %] > <input type="hidden" name="qty[% uncertainpriceorder.ordernumber %]" value="[% uncertainpriceorder.quantity %]" /> > [% ELSE %] >- <input type="text" size="10" name="qty[% uncertainpriceorder.ordernumber %]" value="[% uncertainpriceorder.quantity %]" >- onchange="uncheckbox(this.form, [% uncertainpriceorder.ordernumber %]);" /> >+ <input class="check_uncertain" data-ordernumber="[% uncertainpriceorder.ordernumber %]" type="text" size="10" name="qty[% uncertainpriceorder.ordernumber %]" value="[% uncertainpriceorder.quantity %]" /> > [% END %] > </td> > </tr> > [% END %] > </tbody> > </table> >- <fieldset class="action"><input type="button" value="Save" onclick="check(this.form)" /></fieldset> >+ <fieldset class="action"><input type="button" value="Save" /></fieldset> > </form> > [% END %] > >-- >2.1.4
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 16752
:
52458
|
52459
|
52460
|
53569
|
54737
|
54738
|
54739
|
54933
|
54935
|
54936
|
54937