Merge branch 'master' of git.freeside.biz:/home/git/freeside
[freeside.git] / httemplate / edit / agent_payment_gateway.html
index 08a2fa6..753bc76 100644 (file)
@@ -1,28 +1,9 @@
-%
-%
-%$cgi->param('agentnum') =~ /(\d+)$/ or die "illegal agentnum";
-%my $agent = qsearchs('agent', { 'agentnum' => $1 } );
-%die "agentnum $1 not found" unless $agent;
-%
-%#my @agent_payment_gateway;
-%if ( $cgi->param('error') ) {
-%}
-%
-%my $action = 'Add';
-%
-%
-
-
 <% include("/elements/header.html","$action payment gateway override for ". $agent->agent,  menubar(
-  'Main Menu' => $p,
   #'View all payment gateways' => $p. 'browse/payment_gateway.html',
-  'View all agents' => $p. 'browse/agent.html',
+  'View all agents' => $p. 'browse/agent.cgi',
 )) %>
-% if ( $cgi->param('error') ) { 
-
-<FONT SIZE="+1" COLOR="#ff0000">Error: <% $cgi->param('error') %></FONT>
-% } 
 
+<% include('/elements/error.html') %>
 
 <FORM ACTION="<%popurl(1)%>process/agent_payment_gateway.html" METHOD=POST>
 <INPUT TYPE="hidden" NAME="agentnum" VALUE="<% $agent->agentnum %>">
@@ -39,32 +20,24 @@ Use gateway <SELECT NAME="gatewaynum">
 </SELECT>
 <BR><BR>
 
-for <SELECT NAME="cardtype" MULTIPLE>
-% foreach my $cardtype (
-%  "",
-%  "VISA card",
-%  "MasterCard",
-%  "Discover card",
-%  "American Express card",
-%  "Diner's Club/Carte Blanche",
-%  "enRoute",
-%  "JCB",
-%  "BankCard",
-%  "Switch",
-%  "Solo",
-%  'ACH',
-%) { 
+<INPUT TYPE="submit" VALUE="Add gateway override">
+</FORM>
 
-  <OPTION VALUE="<% $cardtype %>"><% $cardtype || '(Default fallback)' %>
-% } 
+<% include('/elements/footer.html') %>
 
-</SELECT>
-<BR><BR>
+<%init>
 
-(optional) when invoice contains only items of taxclass <INPUT TYPE="text" NAME="taxclass">
-<BR><BR>
+die "access denied"
+  unless $FS::CurrentUser::CurrentUser->access_right('Configuration');
 
-<INPUT TYPE="submit" VALUE="Add gateway override">
-</FORM>
-</BODY>
-</HTML>
+$cgi->param('agentnum') =~ /(\d+)$/ or die "illegal agentnum";
+my $agent = qsearchs('agent', { 'agentnum' => $1 } );
+die "agentnum $1 not found" unless $agent;
+
+#my @agent_payment_gateway;
+if ( $cgi->param('error') ) {
+}
+
+my $action = 'Add';
+
+</%init>