X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fmisc%2Forder_pkg.html;h=dcbc01636e7a752e2dcba15d437e3ddcf8709fee;hb=5c0d47bfe554a35c8906d97b9fabd9999be4f67e;hp=2511a3deb547ac7fd555fbe91db878d39e6f8a23;hpb=4117c20f85ce085d7dd42b8970ce9c65b95d7e27;p=freeside.git diff --git a/httemplate/misc/order_pkg.html b/httemplate/misc/order_pkg.html index 2511a3deb..dcbc01636 100644 --- a/httemplate/misc/order_pkg.html +++ b/httemplate/misc/order_pkg.html @@ -9,14 +9,14 @@ function enable_order_pkg () { if ( document.OrderPkgForm.pkgpart.selectedIndex > 0 ) { - document.OrderPkgForm.submit.disabled = false; + document.OrderPkgForm.submitButton.disabled = false; if ( document.OrderPkgForm.pkgpart.options[document.OrderPkgForm.pkgpart.selectedIndex].getAttribute('data-can_discount') == 1 ) { document.OrderPkgForm.discountnum.disabled = false; } else { document.OrderPkgForm.discountnum.disabled = true; } } else { - document.OrderPkgForm.submit.disabled = true; + document.OrderPkgForm.submitButton.disabled = true; document.OrderPkgForm.discountnum.disabled = true; } } @@ -28,6 +28,9 @@
+% if ( $svcpart ) { + +% } <% ntable("#cccccc", 2) %> <% include('/elements/tr-select-cust-part_pkg.html', @@ -38,34 +41,19 @@ ) %> -%# false laziness w/edit/quick-charge.html Start date - - + <% include('/elements/input-date-field.html',{ + 'name' => 'start_date', + 'format' => $date_format, + 'value' => $start_date, + 'noinit' => 1, + }) %> (leave blank to start immediately) - - % if ( $cust_main->payby =~ /^(CARD|CHEK)$/ ) { % my $what = lc(FS::payby->shortname($cust_main->payby)); @@ -99,10 +87,30 @@ ) %> + + Contract end date + + <% include('/elements/input-date-field.html',{ + 'name' => 'contract_end', + 'format' => $date_format, + 'value' => '', + 'noinit' => 1, + }) %> + + + +<% include( '/elements/standardize_locations.html', + 'form' => "OrderPkgForm", + 'onlyship' => 1, + 'no_company' => 1, + 'callback' => 'document.OrderPkgForm.submit();', + ) +%> +
-> +>
@@ -129,10 +137,11 @@ my $pkgpart = scalar($cgi->param('pkgpart')); my $format = $date_format. ' %T %z (%Z)'; #false laziness w/REAL_cust_pkg.cgi? my $start_date = ''; -if(! $conf->exists('order_pkg-no_start_date') ) { - warn "foo"; - $cust_main->next_bill_date; +if( ! $conf->exists('order_pkg-no_start_date') ) { + $start_date = $cust_main->next_bill_date; $start_date = $start_date ? time2str($format, $start_date) : ''; } +my $svcpart = $cgi->param('svcpart'); +