diff options
| author | ivan <ivan> | 2008-10-05 06:07:37 +0000 |
|---|---|---|
| committer | ivan <ivan> | 2008-10-05 06:07:37 +0000 |
| commit | 06c64249c1420d61e4379a7791305c9375e1236f (patch) | |
| tree | 5d94a6e0b533d45aa27dd53462be8cc0f79500d9 /httemplate/edit | |
| parent | a209674e4c0d38dfc9d0becbcbde23ba2201bb12 (diff) | |
finish UI improvements wrt refunds: now you have to post a check or cash refund explicitly, no more implicit creation by 'applying' credits. don't show useless application links. don't enable apply button until you pick an invoice/refund. RT#3812
Diffstat (limited to 'httemplate/edit')
| -rw-r--r-- | httemplate/edit/elements/ApplicationCommon.html | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/httemplate/edit/elements/ApplicationCommon.html b/httemplate/edit/elements/ApplicationCommon.html index 0e6c49975..a485d37de 100644 --- a/httemplate/edit/elements/ApplicationCommon.html +++ b/httemplate/edit/elements/ApplicationCommon.html @@ -43,7 +43,7 @@ Examples: <% include('/elements/error.html') %> -<FORM ACTION="<% $p1. $opt{'form_action'} %>" METHOD=POST> +<FORM ACTION="<% $p1. $opt{'form_action'} %>" NAME="ApplicationForm" ID="ApplicationForm" METHOD=POST> <% $src_thing %> #<B><% $src_pkeyvalue %></B><BR> <INPUT TYPE="hidden" NAME="<% $src_pkey %>" VALUE="<% $src_pkeyvalue %>"> @@ -79,6 +79,13 @@ Examples: function changed(what) { dst = what.options[what.selectedIndex].value; + if ( dst == '' ) { + what.form.submit.disabled=true; + return true; + } + + what.form.submit.disabled=false; + % foreach my $dst ( @dst ) { if ( dst == <% $dst->$dst_pkey %> ) { @@ -97,7 +104,7 @@ Apply to: <TR> <TD ALIGN="right"><% $dst_thing %>: </TD> <TD><SELECT NAME="<% $dst_pkey %>" SIZE=1 onChange="changed(this)"> -<OPTION VALUE=""> +<OPTION VALUE="">Select <% $dst_thing %> % foreach my $dst ( @dst ) { <OPTION<% $dst->$dst_pkey eq $dst_pkeyvalue ? ' SELECTED' : '' %> VALUE="<% $dst->$dst_pkey %>">#<% $dst->$dst_pkey %> - <% time2str("%D", $dst->_date) %> - $<% $dst->$dst_unapplied %> @@ -115,7 +122,7 @@ Apply to: </TABLE> <BR> -<CENTER><INPUT TYPE="submit" VALUE="Apply"></CENTER> +<CENTER><INPUT TYPE="submit" VALUE="Apply" NAME="submit" ID="submit" DISABLED></CENTER> </FORM> |
