From 27b9e55c701ed2c8e6594083f06d5d4c7f3ee1cd Mon Sep 17 00:00:00 2001 From: ivan Date: Tue, 1 Apr 2008 05:49:20 +0000 Subject: [PATCH] finish component-izing overlib links --- httemplate/view/cust_main/payment_history.html | 89 ++++++++++++++++++++------ 1 file changed, 71 insertions(+), 18 deletions(-) diff --git a/httemplate/view/cust_main/payment_history.html b/httemplate/view/cust_main/payment_history.html index 1eb18a6f8..11c0d36a7 100644 --- a/httemplate/view/cust_main/payment_history.html +++ b/httemplate/view/cust_main/payment_history.html @@ -3,12 +3,28 @@ % my $s = 0; % if ( $payby{'BILL'} && $curuser->access_right('Post payment') ) { <% $s++ ? ' | ' : '' %> - Enter check payment + <% include('/elements/popup_link-cust_main.html', + 'label' => 'Enter check payment', + 'action' => "${p}edit/cust_pay.cgi?popup=1;payby=BILL", + 'cust_main' => $cust_main, + 'actionlabel' => 'Enter check payment', + 'width' => 392, + #default# 'height' => 336, + ) + %> % } % if ( $payby{'CASH'} && $curuser->access_right('Post payment') ) { <% $s++ ? ' | ' : '' %> - Enter cash payment + <% include('/elements/popup_link-cust_main.html', + 'label' => 'Enter cash payment', + 'action' => "${p}edit/cust_pay.cgi?popup=1;payby=CASH", + 'cust_main' => $cust_main, + 'actionlabel' => 'Enter cash payment', + 'width' => 392, + #default# 'height' => 336, + ) + %> % } % if ( $payby{'WEST'} && $curuser->access_right('Post payment') ) { @@ -40,7 +56,15 @@
% if ( $curuser->access_right('Post credit') ) { - Enter credit + <% include('/elements/popup_link-cust_main.html', + 'label' => 'Enter credit', + 'action' => "${p}edit/cust_credit.cgi", + 'cust_main' => $cust_main, + 'actionlabel' => 'Enter credit', + 'width' => 392, + #default# 'height' => 336, + ) + %>
% } @@ -128,9 +152,15 @@ % $pre = 'Unapplied '; % $post = ''; % if ( $curuser->access_right('Apply payment') ) { -% $apply = qq! (apply)!; +% $apply = ' ('. include( '/elements/popup_link.html', +% 'label' => 'apply', +% 'action' => "${p}edit/cust_bill_pay.cgi?". +% $cust_pay->paynum, +% 'actionlabel' => 'Apply payment', +% 'width' => 392, +% #default# 'height' => 336, +% ). +% ')'; % } % } elsif ( scalar(@cust_bill_pay) == 1 % && scalar(@cust_pay_refund) == 0 @@ -167,17 +197,28 @@ % '$'. % $cust_pay->unapplied. ' unapplied'; % if ( $curuser->access_right('Apply payment') ) { -% $desc .= qq! (apply)!; +% $desc = ' ('. include( '/elements/popup_link.html', +% 'label' => 'apply', +% 'action' => "${p}edit/cust_bill_pay.cgi?". +% $cust_pay->paynum, +% 'actionlabel' => 'Apply payment', +% 'width' => 392, +% #default# 'height' => 336, +% ). +% ')'; % } % $desc .= '
'; % } % } % -% my $view = qq! (view receipt)!; +% my $view = +% ' ('. include('/elements/popup_link.html', +% 'label' => 'view receipt', +% 'action' => "${p}view/cust_pay.html?link=popup;paynum=". +% $cust_pay->paynum, +% 'actionlabel' => 'Payment Receipt', +% ). +% ')'; % % my $refund = ''; % my $refund_days = $conf->config('card_refund-days') || 120; @@ -310,9 +351,15 @@ % $pre = 'Unapplied '; % $post = ''; % if ( $curuser->access_right('Apply credit') ) { -% $apply = qq! (apply)!; +% $apply = ' ('. include( '/elements/popup_link.html', +% 'label' => 'apply', +% 'action' => "${p}edit/cust_credit_bill.cgi?". +% $cust_credit->crednum, +% 'actionlabel' => 'Apply credit', +% 'width' => 392, +% #default# 'height' => 336, +% ). +% ')'; % } % } elsif ( scalar(@cust_credit_bill) == 1 % && scalar(@cust_credit_refund) == 0 @@ -348,9 +395,15 @@ % $desc .= '  $'. % $cust_credit->credited. ' unapplied'; % if ( $curuser->access_right('Apply credit') ) { -% $desc .= qq! (apply)!; +% $desc = ' ('. include( '/elements/popup_link.html', +% 'label' => 'apply', +% 'action' => "${p}edit/cust_credit_bill.cgi?". +% $cust_credit->crednum, +% 'actionlabel' => 'Apply credit', +% 'width' => 392, +% #default# 'height' => 336, +% ). +% ')'; % } % $desc .= '
'; % } -- 2.11.0