summaryrefslogtreecommitdiff
path: root/httemplate/view/cust_main
diff options
context:
space:
mode:
Diffstat (limited to 'httemplate/view/cust_main')
-rw-r--r--httemplate/view/cust_main/billing.html2
-rw-r--r--httemplate/view/cust_main/contacts.html14
-rwxr-xr-xhttemplate/view/cust_main/packages.html5
-rw-r--r--httemplate/view/cust_main/packages/services.html44
-rw-r--r--httemplate/view/cust_main/packages/status.html6
-rw-r--r--httemplate/view/cust_main/payment_history.html22
-rw-r--r--httemplate/view/cust_main/payment_history/payment.html5
-rw-r--r--httemplate/view/cust_main/payment_history/pending_payment.html61
-rw-r--r--httemplate/view/cust_main/payment_history/voided_payment.html8
9 files changed, 22 insertions, 145 deletions
diff --git a/httemplate/view/cust_main/billing.html b/httemplate/view/cust_main/billing.html
index 014ddaba2..dd195236a 100644
--- a/httemplate/view/cust_main/billing.html
+++ b/httemplate/view/cust_main/billing.html
@@ -132,7 +132,7 @@ Billing information
<TR>
<TD ALIGN="right">Attention</TD>
- <TD BGCOLOR="#ffffff"><% $cust_main->payname |h %></TD>
+ <TD BGCOLOR="#ffffff"><% $cust_main->payname %></TD>
</TR>
% } elsif ( $cust_main->payby eq 'COMP' ) {
diff --git a/httemplate/view/cust_main/contacts.html b/httemplate/view/cust_main/contacts.html
index e91af54e6..e88c02ea5 100644
--- a/httemplate/view/cust_main/contacts.html
+++ b/httemplate/view/cust_main/contacts.html
@@ -10,7 +10,7 @@
<TR>
<TD ALIGN="right">Contact name</TD>
<TD COLSPAN=5 BGCOLOR="#ffffff">
- <% $cust_main->get("${pre}last"). ', '. $cust_main->get("${pre}first") |h %>
+ <% $cust_main->get("${pre}last"). ', '. $cust_main->get("${pre}first") %>
</TD>
% if ( $which eq '' && $conf->exists('show_ss') ) {
<TD ALIGN="right">SS#</TD>
@@ -19,11 +19,11 @@
</TR>
<TR>
<TD ALIGN="right">Company</TD>
- <TD COLSPAN=7 BGCOLOR="#ffffff"><% $cust_main->get("${pre}company") |h %></TD>
+ <TD COLSPAN=7 BGCOLOR="#ffffff"><% $cust_main->get("${pre}company") %></TD>
</TR>
<TR>
<TD ALIGN="right">Address</TD>
- <TD COLSPAN=7 BGCOLOR="#ffffff"><% $cust_main->get("${pre}address1") |h %></TD>
+ <TD COLSPAN=7 BGCOLOR="#ffffff"><% $cust_main->get("${pre}address1") %></TD>
</TR>
% if ( $cust_main->get("${pre}address2") ) {
@@ -36,20 +36,20 @@
<TR>
<TD ALIGN="right"><% $address2_label %></TD>
- <TD COLSPAN=7 BGCOLOR="#ffffff"><% $cust_main->get("${pre}address2") |h %></TD>
+ <TD COLSPAN=7 BGCOLOR="#ffffff"><% $cust_main->get("${pre}address2") %></TD>
</TR>
% }
<TR>
<TD ALIGN="right">City</TD>
- <TD BGCOLOR="#ffffff"><% $cust_main->get("${pre}city") |h %></TD>
+ <TD BGCOLOR="#ffffff"><% $cust_main->get("${pre}city") %></TD>
% if ( $cust_main->get("${pre}county") ) {
<TD ALIGN="right">County</TD>
- <TD BGCOLOR="#ffffff"><% $cust_main->get("${pre}county") |h %></TD>
+ <TD BGCOLOR="#ffffff"><% $cust_main->get("${pre}county") %></TD>
% }
<TD ALIGN="right">State</TD>
- <TD BGCOLOR="#ffffff"><% state_label( $cust_main->get("${pre}state"), $cust_main->get("${pre}country") ) |h %></TD>
+ <TD BGCOLOR="#ffffff"><% state_label( $cust_main->get("${pre}state"), $cust_main->get("${pre}country") ) %></TD>
<TD ALIGN="right">Zip</TD>
<TD BGCOLOR="#ffffff"><% $cust_main->get("${pre}zip") %></TD>
</TR>
diff --git a/httemplate/view/cust_main/packages.html b/httemplate/view/cust_main/packages.html
index 660d0ef86..811ac3c98 100755
--- a/httemplate/view/cust_main/packages.html
+++ b/httemplate/view/cust_main/packages.html
@@ -57,9 +57,7 @@ Current packages
<TD ALIGN="right">
<A HREF="<%$p%>search/report_cust_pkg.html?custnum=<% $cust_main->custnum %>">Package reports</A><BR>
Service reports:
- <A HREF="<%$p%>search/report_svc_acct.html?custnum=<% $cust_main->custnum %>">accounts</A><BR>
- Usage reports:
- <A HREF="<%$p%>search/report_cdr.html?custnum=<% $cust_main->custnum %>">CDRs</A>
+ <A HREF="<%$p%>search/report_svc_acct.html?custnum=<% $cust_main->custnum %>">accounts</A>
</TD>
</TR>
@@ -163,7 +161,6 @@ my %conf_opt = (
'legacy_link' => $conf->exists('legacy_link'),
'svc_broadband-manage_link' => scalar($conf->config('svc_broadband-manage_link')),
'maestro-status_test' => $conf->exists('maestro-status_test'),
- 'cust_pkg-large_pkg_size' => $conf->config('cust_pkg-large_pkg_size'),
);
#subroutines
diff --git a/httemplate/view/cust_main/packages/services.html b/httemplate/view/cust_main/packages/services.html
index 512efccc4..6e30922c5 100644
--- a/httemplate/view/cust_main/packages/services.html
+++ b/httemplate/view/cust_main/packages/services.html
@@ -4,40 +4,12 @@
<TD CLASS="inv" BGCOLOR="<% $bgcolor %>">
<TABLE CLASS="inv" BORDER=0 CELLSPACING=0 CELLPADDING=0 WIDTH="100%">
- <SCRIPT TYPE="text/javascript">
-function clearhint_search_cust_svc(obj, str) {
- if (obj.value == str) obj.value = '';
-}
- </SCRIPT>
% #foreach my $svcpart (sort {$a->{svcpart} <=> $b->{svcpart}} @{$pkg->{svcparts}}) {
% foreach my $part_svc ( $cust_pkg->part_svc ) {
-% if ( $opt{'cust_pkg-large_pkg_size'} > 0 and
-% $opt{'cust_pkg-large_pkg_size'} <= $cust_pkg->num_svcs ) {
-% # summarize
- <TR>
- <TD ALIGN="center" VALIGN="top">
-% my $href="${p}search/cust_pkg_svc.html?svcpart=".$part_svc->svcpart.
-% ";pkgnum=".$cust_pkg->pkgnum;
- <A HREF="<% $href %>"><% $part_svc->svc %></A>&nbsp;
- <A HREF="<% $href %>"><B>(view all <% $cust_pkg->num_svcs %>)</B></A>
-% my $hint = $hints{$part_svc->svcdb};
-% if ( $hint ) {
- <BR>
- <FORM name="svcpart<%$part_svc->svcpart%>_search" STYLE="display:inline"
- ACTION="<%$p%>search/cust_pkg_svc.html" METHOD="GET">
- <INPUT TYPE="hidden" NAME="svcpart" VALUE="<%$part_svc->svcpart%>">
- <INPUT TYPE="hidden" NAME="pkgnum" VALUE="<%$cust_pkg->pkgnum%>">
- <INPUT TYPE="text" NAME="search_svc"
- onfocus="clearhint_search_cust_svc(this, '<%$hint%>')" VALUE="<%$hint%>">
- <INPUT TYPE="submit" VALUE="Search"></FORM>
-% } #$hint
- </TD>
- </TR>
-% }
-% else {
-% foreach my $cust_svc ( @{ $part_svc->cust_pkg_svc } ) {
+% #foreach my $service (@{$svcpart->{services}}) {
+% foreach my $cust_svc ( @{ $part_svc->cust_pkg_svc } ) {
<TR>
<TD ALIGN="right" VALIGN="top"><% FS::UI::Web::svc_link($m, $part_svc, $cust_svc) %></TD>
@@ -93,8 +65,7 @@ function clearhint_search_cust_svc(obj, str) {
</TD>
</TR>
-% } #foreach $cust_svc
-% }
+% }
% if ( ! $cust_pkg->get('cancel')
% && $curuser->access_right('Provision customer service')
@@ -166,13 +137,4 @@ sub svc_unprovision_link {
qq!', 'Permanently unprovision and delete this service?')">Unprovision</A>!;
}
-my %hints = (
-svc_acct => '(user or email)',
-svc_domain => '(domain)',
-svc_broadband => '(ip or mac)',
-svc_forward => '(email)',
-svc_phone => '(phone)',
-svc_pbx => '(phone)',
-);
-
</%init>
diff --git a/httemplate/view/cust_main/packages/status.html b/httemplate/view/cust_main/packages/status.html
index c05cd5a94..a6868434b 100644
--- a/httemplate/view/cust_main/packages/status.html
+++ b/httemplate/view/cust_main/packages/status.html
@@ -54,11 +54,8 @@
<% pkg_status_row_changed( $cust_pkg, %opt, 'colspan'=>$colspan ) %>
<% pkg_status_row_if( $cust_pkg, $last_bill_or_renewed, 'last_bill', %opt, curuser=>$curuser ) %>
-% if ( $part_pkg->option('suspend_bill') ) {
- <% pkg_status_row_if( $cust_pkg, 'Next&nbsp;bill', 'bill', %opt, curuser=>$curuser ) %>
-% }
+% # pkg_status_row($cust_pkg, 'Next bill', 'bill', %opt)
<% pkg_status_row_if( $cust_pkg, 'Expires', 'expire', %opt, curuser=>$curuser ) %>
- <% pkg_status_row_if( $cust_pkg, 'Contract ends', 'contract_end', %opt ) %>
<TR>
<TD COLSPAN=<%$colspan%>>
@@ -170,7 +167,6 @@
<% pkg_status_row_if($cust_pkg, 'Will automatically suspend by', 'autosuspend', %opt) %>
<% pkg_status_row_if( $cust_pkg, 'Will suspend on', 'adjourn', %opt, curuser=>$curuser ) %>
<% pkg_status_row_if( $cust_pkg, 'Expires', 'expire', %opt, curuser=>$curuser ) %>
- <% pkg_status_row_if( $cust_pkg, 'Contract ends', 'contract_end', %opt ) %>
% if ( $part_pkg->freq ) {
diff --git a/httemplate/view/cust_main/payment_history.html b/httemplate/view/cust_main/payment_history.html
index 046899e5e..b84883a2f 100644
--- a/httemplate/view/cust_main/payment_history.html
+++ b/httemplate/view/cust_main/payment_history.html
@@ -1,7 +1,7 @@
%# payment links
% my $s = 0;
-% if ( $payby{'BILL'} && $curuser->access_right(['Post payment', 'Post check payment' ]) ) {
+% if ( $payby{'BILL'} && $curuser->access_right('Post payment') ) {
<% $s++ ? ' | ' : '' %>
<% include('/elements/popup_link-cust_main.html',
'label' => 'Enter check payment',
@@ -14,7 +14,7 @@
%>
% }
-% if ( $payby{'CASH'} && $curuser->access_right(['Post payment', 'Post cash payment']) ) {
+% if ( $payby{'CASH'} && $curuser->access_right('Post payment') ) {
<% $s++ ? ' | ' : '' %>
<% include('/elements/popup_link-cust_main.html',
'label' => 'Enter cash payment',
@@ -33,7 +33,7 @@
% }
% if ( ( $payby{'CARD'} || $payby{'DCRD'} )
-% && $curuser->access_right(['Process payment', 'Process credit card payment'])
+% && $curuser->access_right('Process payment')
% && ! $cust_main->is_encrypted($cust_main->payinfo)
% ) {
<% $s++ ? ' | ' : '' %>
@@ -41,7 +41,7 @@
% }
% if ( ( $payby{'CHEK'} || $payby{'DCHK'} )
-% && $curuser->access_right(['Process payment', 'Process Echeck payment'])
+% && $curuser->access_right('Process payment')
% && ! $cust_main->is_encrypted($cust_main->payinfo)
% ) {
<% $s++ ? ' | ' : '' %>
@@ -73,7 +73,7 @@
%# refund links
% $s = 0;
-% if ( $payby{'BILL'} && $curuser->access_right(['Post refund', 'Post check refund']) ) {
+% if ( $payby{'BILL'} && $curuser->access_right('Post refund') ) {
<% $s++ ? ' | ' : '' %>
<% include('/elements/popup_link-cust_main.html',
'label' => 'Enter check refund',
@@ -86,7 +86,7 @@
%>
% }
-% if ( $payby{'CASH'} && $curuser->access_right(['Post refund', 'Post cash refund']) ) {
+% if ( $payby{'CASH'} && $curuser->access_right('Post refund') ) {
<% $s++ ? ' | ' : '' %>
<% include('/elements/popup_link-cust_main.html',
'label' => 'Enter cash refund',
@@ -412,16 +412,6 @@ foreach my $cust_pay ($cust_main->cust_pay) {
};
}
-#pending payments
-foreach my $cust_pay_pending ($cust_main->cust_pay_pending) {
- push @history, {
- 'date' => $cust_pay_pending->_date,
- 'desc' => include('payment_history/pending_payment.html', $cust_pay_pending, %opt ),
- 'void_payment' => $cust_pay_pending->paid,
- };
-}
-
-
#voided payments
foreach my $cust_pay_void ($cust_main->cust_pay_void) {
push @history, {
diff --git a/httemplate/view/cust_main/payment_history/payment.html b/httemplate/view/cust_main/payment_history/payment.html
index e745864b7..6ec9fdb96 100644
--- a/httemplate/view/cust_main/payment_history/payment.html
+++ b/httemplate/view/cust_main/payment_history/payment.html
@@ -155,14 +155,11 @@ my $view =
my $refund = '';
my $refund_days = $opt{'card_refund-days'} || 120;
-my @rights = ('Refund payment');
-push @rights, 'Refund credit card payment' if $payby eq 'CARD';
-push @rights, 'Refund Echeck payment' if $payby eq 'CHEK';
if ( $cust_pay->closed !~ /^Y/i
&& $cust_pay->payby =~ /^(CARD|CHEK)$/
&& time-$cust_pay->_date < $refund_days*86400
&& $cust_pay->unrefunded > 0
- && $curuser->access_right(\@rights)
+ && $curuser->access_right('Refund payment')
) {
$refund = qq! (<A HREF="${p}edit/cust_refund.cgi?payby=$1;!.
qq!paynum=!. $cust_pay->paynum. '"'.
diff --git a/httemplate/view/cust_main/payment_history/pending_payment.html b/httemplate/view/cust_main/payment_history/pending_payment.html
deleted file mode 100644
index 40805b1aa..000000000
--- a/httemplate/view/cust_main/payment_history/pending_payment.html
+++ /dev/null
@@ -1,61 +0,0 @@
-<b><font size="+1" color="#FF0000">Pending payment </font></b> <% "$info $status ($link)" %>
-<%init>
-
-my( $cust_pay_pending, %opt ) = @_;
-
-my $conf = new FS::Conf;
-
-my $curuser = $FS::CurrentUser::CurrentUser;
-
-my $payby = $cust_pay_pending->payby;
-
-my $payinfo;
-if ( $payby eq 'CARD' ) {
- $payinfo = $cust_pay_pending->paymask;
-} elsif ( $payby eq 'CHEK' ) {
- my( $account, $aba ) = split('@', $cust_pay_pending->paymask );
- $payinfo = "ABA $aba, Acct #$account";
-} else {
- $payinfo = $cust_pay_pending->payinfo;
-}
-
-my $target = "$payby$payinfo";
-$payby =~ s/^BILL$/Check #/ if $payinfo;
-$payby =~ s/^CHEK$/Electronic check /;
-$payby =~ s/^PREP$/Prepaid card /;
-$payby =~ s/^CARD$/Credit card #/;
-$payby =~ s/^COMP$/Complimentary by /;
-$payby =~ s/^CASH$/Cash/;
-$payby =~ s/^WEST$/Western Union/;
-$payby =~ s/^MCRD$/Manual credit card/;
-$payby =~ s/^BILL$//;
-my $info = $payby ? "($payby$payinfo)" : '';
-
-my %statusaction = (
- 'new' => 'delete',
- 'pending' => 'complete',
- 'captured' => 'capture',
-);
-
-my $edit_pending =
- $FS::CurrentUser::CurrentUser->access_right('Edit customer pending payments');
-
-my $status = "Status: ".$cust_pay_pending->status;
-
-my $action = $statusaction{$cust_pay_pending->status};
-
-my $link = "";
-if ( $action && $edit_pending ) {
- $link = include('/elements/popup_link.html',
- 'action' => $p. 'edit/cust_pay_pending.html'.
- '?paypendingnum='. $cust_pay_pending->paypendingnum.
- ";action=$action",
- 'label' => $action,
- 'color' => '#ff0000',
- 'width' => 655,
- 'height' => ( $action eq 'delete' ? 480 : 575 ),
- 'actionlabel' => ucfirst($action). ' pending payment',
- );
-}
-
-</%init>
diff --git a/httemplate/view/cust_main/payment_history/voided_payment.html b/httemplate/view/cust_main/payment_history/voided_payment.html
index 5d7f60cf5..be68ff091 100644
--- a/httemplate/view/cust_main/payment_history/voided_payment.html
+++ b/httemplate/view/cust_main/payment_history/voided_payment.html
@@ -1,10 +1,6 @@
-<DEL>Payment <% $info %> by <% $cust_pay_void->otaker %></DEL>
+<DEL>Payment <% $info %></DEL>
<I>voided <% time2str($date_format, $cust_pay_void->void_date) %>
-% my $void_user = $cust_pay_void->void_access_user;
-% if ($void_user) {
- by <% $void_user->username %></I>
-% }
-<% $unvoid %>
+by <% $cust_pay_void->otaker %></I><% $unvoid %>
<%init>
my( $cust_pay_void, %opt ) = @_;