From a0c37cca3cea5a5167650e3338234dd17a1e81c1 Mon Sep 17 00:00:00 2001 From: Ivan Kohler Date: Sun, 18 Jan 2015 14:48:36 -0800 Subject: [PATCH] fix order package for quotes: don't display irrelevant fields, RT#22232 et al --- httemplate/misc/order_pkg.html | 72 ++++++++++++++++++++++-------------------- 1 file changed, 38 insertions(+), 34 deletions(-) diff --git a/httemplate/misc/order_pkg.html b/httemplate/misc/order_pkg.html index d777e17da..36f1f5f37 100644 --- a/httemplate/misc/order_pkg.html +++ b/httemplate/misc/order_pkg.html @@ -75,43 +75,47 @@ <& /elements/tr-input-pkg-quantity.html, curr_value => $quantity &> -% if ( $cust_main && $cust_main->payby =~ /^(CARD|CHEK)$/ ) { -% my $what = lc(FS::payby->shortname($cust_main->payby)); +% unless ( $quotationnum ) { + +% if ( $cust_main && $cust_main->payby =~ /^(CARD|CHEK)$/ ) { +% my $what = lc(FS::payby->shortname($cust_main->payby)); + + <% mt("Disable automatic $what charge") |h %> + + +% } + - <% mt("Disable automatic $what charge") |h %> - + <% mt('Start') |h %> + + param('start') eq '' ? 'CHECKED' : ''%>>Now +   + param('start') eq 'on_hold' ? 'CHECKED' : ''%>>On hold +   + param('start') eq 'date' ? 'CHECKED' : ''%>>On date + + <& /elements/input-date-field.html,{ + 'name' => 'start_date', + 'format' => $date_format, + 'value' => '', + 'noinit' => 1, + } &> + -% } - - <% mt('Start') |h %> - - param('start') eq '' ? 'CHECKED' : ''%>>Now -   - param('start') eq 'on_hold' ? 'CHECKED' : ''%>>On hold -   - param('start') eq 'date' ? 'CHECKED' : ''%>>On date - - <& /elements/input-date-field.html,{ - 'name' => 'start_date', - 'format' => $date_format, - 'value' => '', - 'noinit' => 1, - } &> - - - - - <% mt('Contract end date') |h %> - - <& /elements/input-date-field.html,{ - 'name' => 'contract_end', - 'format' => $date_format, - 'value' => '', - 'noinit' => 1, - } &> - - + + <% mt('Contract end date') |h %> + + <& /elements/input-date-field.html,{ + 'name' => 'contract_end', + 'format' => $date_format, + 'value' => '', + 'noinit' => 1, + } &> + + + +% }
-- 2.11.0