This commit was generated by cvs2svn to compensate for changes in r6252,
[freeside.git] / httemplate / edit / cust_pay.cgi
index 855fbfc..92abb7b 100755 (executable)
@@ -4,10 +4,7 @@
   <%  include("/elements/header.html", $title, '') %>
 % } 
 
-% if ( $cgi->param('error') ) { 
-  <FONT SIZE="+1" COLOR="#ff0000">Error: <% $cgi->param('error') %></FONT>
-  <BR><BR>
-% } 
+<% include('/elements/error.html') %>
 
 <LINK REL="stylesheet" TYPE="text/css" HREF="../elements/calendar-win2k-2.css" TITLE="win2k-2">
 <SCRIPT TYPE="text/javascript" SRC="../elements/calendar_stripped.js"></SCRIPT>
@@ -89,6 +86,7 @@ Payment
 </HTML>
 
 <%once>
+
 my $conf = new FS::Conf;
 
 my %payby = (
@@ -99,9 +97,13 @@ my %payby = (
 );
 
 my $money_char = $conf->config('money_char') || '$';
-</%once>
 
+</%once>
 <%init>
+
+die "access denied"
+  unless $FS::CurrentUser::CurrentUser->access_right('Post payment');
+
 my($link, $linknum, $paid, $payby, $payinfo, $_date); 
 if ( $cgi->param('error') ) {
   $link     = $cgi->param('link');