projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
c6ab4d5
)
UI spring cleaning: prorate day dropdown
author
Ivan Kohler
<ivan@freeside.biz>
Thu, 18 Jun 2015 07:50:23 +0000
(
00:50
-0700)
committer
Ivan Kohler
<ivan@freeside.biz>
Thu, 18 Jun 2015 07:50:23 +0000
(
00:50
-0700)
httemplate/edit/cust_main/billing.html
patch
|
blob
|
history
diff --git
a/httemplate/edit/cust_main/billing.html
b/httemplate/edit/cust_main/billing.html
index
c3e8922
..
6f716c1
100644
(file)
--- a/
httemplate/edit/cust_main/billing.html
+++ b/
httemplate/edit/cust_main/billing.html
@@
-128,11
+128,25
@@
% if ( $conf->exists('cust_main-select-prorate_day') ) {
<TR>
% if ( $conf->exists('cust_main-select-prorate_day') ) {
<TR>
- <TH ALIGN="right" WIDTH="200"><% mt('Prorate day
(1-28)
') |h %> </TD>
+ <TH ALIGN="right" WIDTH="200"><% mt('Prorate day') |h %> </TD>
<TD>
<TD>
- <INPUT TYPE="text" NAME="prorate_day" VALUE="<% $cust_main->prorate_day %>" SIZE=3 MAXLENGTH=2>
+ <SELECT NAME="prorate_day">
+ <% prorate_day_options($cust_main->prorate_day) %>
+ </SELECT>
</TD>
</TR>
</TD>
</TR>
+
+% sub prorate_day_options {
+% my $curr_value = shift;
+% my $ret = '';
+% for my $prorate_day ( 1 .. 28 ) {
+% my $sel = '';
+% $sel = "SELECTED='SELECTED'" if $curr_value == $prorate_day;
+% $ret .= "<OPTION VALUE='$prorate_day' $sel>$prorate_day</OPTION>";
+% }
+% $ret;
+% }
+
% } else {
<INPUT TYPE="hidden" NAME="prorate_day" VALUE="<% $cust_main->prorate_day %>">
% }
% } else {
<INPUT TYPE="hidden" NAME="prorate_day" VALUE="<% $cust_main->prorate_day %>">
% }