diff options
author | Mark Wells <mark@freeside.biz> | 2013-08-08 18:10:45 -0700 |
---|---|---|
committer | Mark Wells <mark@freeside.biz> | 2013-08-08 18:10:45 -0700 |
commit | c9d51796516657eebb115d6295ba3c0e2e08f697 (patch) | |
tree | 5d0d3fd98e7e952bb30f3d28ce01cc7d275b77a0 /fs_selfservice | |
parent | 5a6c740c8152b1e8fa61d449808a50cdd7de07ab (diff) |
new thirdparty payment framework, #22395, etc.
Diffstat (limited to 'fs_selfservice')
52 files changed, 228 insertions, 197 deletions
diff --git a/fs_selfservice/FS-SelfService/SelfService.pm b/fs_selfservice/FS-SelfService/SelfService.pm index d44f978a5..9da40b9a3 100644 --- a/fs_selfservice/FS-SelfService/SelfService.pm +++ b/fs_selfservice/FS-SelfService/SelfService.pm @@ -109,6 +109,9 @@ $socket .= '.'.$tag if defined $tag && length($tag); 'call_time' => 'PrepaidPhone/call_time', 'call_time_nanpa' => 'PrepaidPhone/call_time_nanpa', 'phonenum_balance' => 'PrepaidPhone/phonenum_balance', + + 'start_thirdparty' => 'MyAccount/start_thirdparty', + 'finish_thirdparty' => 'MyAccount/finish_thirdparty', ); @EXPORT_OK = ( keys(%autoload), diff --git a/fs_selfservice/FS-SelfService/cgi/ach_payment_results.html b/fs_selfservice/FS-SelfService/cgi/ach_payment_results.html index 9cdb65e36..9c6022290 100644 --- a/fs_selfservice/FS-SelfService/cgi/ach_payment_results.html +++ b/fs_selfservice/FS-SelfService/cgi/ach_payment_results.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Payment results') %> <%= if ( $error ) { diff --git a/fs_selfservice/FS-SelfService/cgi/agent_customer_menu.html b/fs_selfservice/FS-SelfService/cgi/agent_customer_menu.html index 603fc0bd2..1e986e1ea 100644 --- a/fs_selfservice/FS-SelfService/cgi/agent_customer_menu.html +++ b/fs_selfservice/FS-SelfService/cgi/agent_customer_menu.html @@ -1,4 +1,4 @@ -<%= $url = "$selfurl?session=$session_id;custnum=$custnum;action="; ''; %> +<%= $url = "$selfurl?action="; ''; %> <TD VALIGN="top" HEIGHT=384 BGCOLOR="#dddddd"> <A HREF="<%= $url %>agent_provision">Setup services</A><BR><BR> <A HREF="<%= $url %>agent_order_pkg">Purchase additional package</A><BR><BR> diff --git a/fs_selfservice/FS-SelfService/cgi/change_bill.html b/fs_selfservice/FS-SelfService/cgi/change_bill.html index 7941971ba..06ea12b9b 100755 --- a/fs_selfservice/FS-SelfService/cgi/change_bill.html +++ b/fs_selfservice/FS-SelfService/cgi/change_bill.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Edit billing address') %> <%= if ( $error ) { @@ -6,7 +5,6 @@ } ''; %> <FORM NAME="ChangeBillForm" ACTION="<%= $selfurl %>" METHOD=POST onSubmit="document.bottomform.submit.disabled=true;"> -<INPUT TYPE="hidden" NAME="session" VALUE="<%= $session_id %>"> <INPUT TYPE="hidden" NAME="action" VALUE="process_change_bill"> <TABLE BGCOLOR="#cccccc" BORDER=0 CELLSPACING=0> diff --git a/fs_selfservice/FS-SelfService/cgi/change_password.html b/fs_selfservice/FS-SelfService/cgi/change_password.html index 68b6fd824..22d897362 100644 --- a/fs_selfservice/FS-SelfService/cgi/change_password.html +++ b/fs_selfservice/FS-SelfService/cgi/change_password.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Change password') %> <%= if ( $error ) { @@ -6,7 +5,6 @@ } ''; %> <FORM ACTION="<%= $selfurl %>" METHOD="POST"> -<INPUT TYPE="hidden" NAME="session" VALUE="<%= $session_id %>"> <INPUT TYPE="hidden" NAME="action" VALUE="process_change_password"> <TABLE BGCOLOR="#cccccc"> diff --git a/fs_selfservice/FS-SelfService/cgi/change_pay.html b/fs_selfservice/FS-SelfService/cgi/change_pay.html index 9633e8920..6898dc7f8 100644 --- a/fs_selfservice/FS-SelfService/cgi/change_pay.html +++ b/fs_selfservice/FS-SelfService/cgi/change_pay.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Change payment information') %> <%= if ( $error ) { @@ -13,7 +12,7 @@ my $preauto = '<TR><TD COLSPAN=3><INPUT TYPE="checkbox" NAME="auto" VALUE="1"'; my $postauto = '>Charge future payments to this card automatically</TD></TR>'; - my $tail = qq(</TABLE><INPUT TYPE="hidden" NAME="session" VALUE="$session_id">). + my $tail = qq(</TABLE>). qq(<INPUT TYPE="hidden" NAME="action" VALUE="process_change_pay">). qq(<BR>). qq(<INPUT TYPE="submit" NAME="process" ). diff --git a/fs_selfservice/FS-SelfService/cgi/change_pkg.html b/fs_selfservice/FS-SelfService/cgi/change_pkg.html index 2d7b488ab..50067061d 100644 --- a/fs_selfservice/FS-SelfService/cgi/change_pkg.html +++ b/fs_selfservice/FS-SelfService/cgi/change_pkg.html @@ -12,7 +12,6 @@ function enable_change_pkg () { $OUT .= qq!<FONT SIZE="+1" COLOR="#ff0000">$error</FONT><BR><BR>!; } ''; %> <FORM NAME="ChangePkgForm" ACTION="<%= $selfurl %>" METHOD=POST> -<INPUT TYPE="hidden" NAME="session" VALUE="<%= $session_id %>"> <INPUT TYPE="hidden" NAME="action" VALUE="process_change_pkg"> <INPUT TYPE="hidden" NAME="pkgnum" VALUE="<%= encode_entities($pkgnum) %>"> <INPUT TYPE="hidden" NAME="pkg" VALUE="<%= encode_entities($pkg) %>"> diff --git a/fs_selfservice/FS-SelfService/cgi/change_ship.html b/fs_selfservice/FS-SelfService/cgi/change_ship.html index 59f91767a..ecd20dc92 100755 --- a/fs_selfservice/FS-SelfService/cgi/change_ship.html +++ b/fs_selfservice/FS-SelfService/cgi/change_ship.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Edit service address') %> <%= if ( $error ) { @@ -6,7 +5,6 @@ } ''; %> <FORM NAME="OneTrueForm" ACTION="<%= $selfurl %>" METHOD=POST onSubmit="document.bottomform.submit.disabled=true;"> -<INPUT TYPE="hidden" NAME="session" VALUE="<%= $session_id %>"> <INPUT TYPE="hidden" NAME="action" VALUE="process_change_ship"> <TABLE BGCOLOR="#cccccc" BORDER=0 CELLSPACING=0> diff --git a/fs_selfservice/FS-SelfService/cgi/customer_change_pkg.html b/fs_selfservice/FS-SelfService/cgi/customer_change_pkg.html index 37dccaaf2..047f8802c 100644 --- a/fs_selfservice/FS-SelfService/cgi/customer_change_pkg.html +++ b/fs_selfservice/FS-SelfService/cgi/customer_change_pkg.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Change package') %> <%= include('change_pkg') %> diff --git a/fs_selfservice/FS-SelfService/cgi/customer_order_pkg.html b/fs_selfservice/FS-SelfService/cgi/customer_order_pkg.html index 192c29fa4..5fcf77fac 100755 --- a/fs_selfservice/FS-SelfService/cgi/customer_order_pkg.html +++ b/fs_selfservice/FS-SelfService/cgi/customer_order_pkg.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Purchase additional package') %> <%= include('order_pkg') %> diff --git a/fs_selfservice/FS-SelfService/cgi/delete_svc.html b/fs_selfservice/FS-SelfService/cgi/delete_svc.html index 80a14f85c..e2b26789d 100644 --- a/fs_selfservice/FS-SelfService/cgi/delete_svc.html +++ b/fs_selfservice/FS-SelfService/cgi/delete_svc.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Remove service') %> <%= if ( $error ) { diff --git a/fs_selfservice/FS-SelfService/cgi/finish_thirdparty_payment.html b/fs_selfservice/FS-SelfService/cgi/finish_thirdparty_payment.html new file mode 100644 index 000000000..79c02cc60 --- /dev/null +++ b/fs_selfservice/FS-SelfService/cgi/finish_thirdparty_payment.html @@ -0,0 +1,22 @@ +<%= include('header', 'Payment confirmation') %> + +<TABLE BGCOLOR="#cccccc"> +<%= if ( $error ) { + $OUT .= '<FONT SIZE=+1><B>Payment processing error</B></FONT><BR>'.$error; +} else { + $OUT .= ' +<TR><TH COLSPAN=2><FONT SIZE=+1><B>Your payment details</B></FONT></TH></TR> +<TR> + <TD ALIGN="right">Payment #</TD> + <TD BGCOLOR="#ffffff"><B>' . $paynum . '</B></TD> +</TR> +<TR> + <TD ALIGN="right">Payment amount</TH> + <TD BGCOLOR="#ffffff"><B>' . sprintf('$%.2f', $paid) . '</B></TD> +</TR> +<TR> + <TD ALIGN="right">Processing #</TD> + <TD BGCOLOR="#ffffff"><B>' . $order_number . '</B></TD> +</TR>'; +} %> +<%= include('footer') %> diff --git a/fs_selfservice/FS-SelfService/cgi/invoices.html b/fs_selfservice/FS-SelfService/cgi/invoices.html index d155b9343..752805123 100644 --- a/fs_selfservice/FS-SelfService/cgi/invoices.html +++ b/fs_selfservice/FS-SelfService/cgi/invoices.html @@ -1,4 +1,4 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> +<%= $url = "$selfurl?action="; ''; %> <%= include('header', 'All Invoices') %> <%= diff --git a/fs_selfservice/FS-SelfService/cgi/list_customers.html b/fs_selfservice/FS-SelfService/cgi/list_customers.html index 7fe7fa493..974634729 100644 --- a/fs_selfservice/FS-SelfService/cgi/list_customers.html +++ b/fs_selfservice/FS-SelfService/cgi/list_customers.html @@ -1,6 +1,6 @@ <HTML><HEAD><TITLE>Reseller</TITLE></HEAD> <BODY BGCOLOR="#eeeeee"><FONT SIZE=5>Reseller</FONT><BR><BR> -<%= $url = "$selfurl?session=$session_id;action="; ''; %> +<%= $url = "$selfurl?action="; ''; %> <TABLE BORDER=0 CELLPADDING=4><TR> <%= include('agent_menu') %> <TD VALIGN="top"> diff --git a/fs_selfservice/FS-SelfService/cgi/login.html b/fs_selfservice/FS-SelfService/cgi/login.html index f7473b1d5..68f3ae465 100644 --- a/fs_selfservice/FS-SelfService/cgi/login.html +++ b/fs_selfservice/FS-SelfService/cgi/login.html @@ -10,7 +10,7 @@ <FONT SIZE="+1" COLOR="#ff0000"><%= $error %></FONT> <FORM ACTION="<%= $self_url %>" METHOD=POST> -<INPUT TYPE="hidden" NAME="session" VALUE="login"> +<INPUT TYPE="hidden" NAME="action" VALUE="myaccount"> <INPUT TYPE="hidden" NAME="agentnum" VALUE="<%= $agentnum %>"> <TABLE BGCOLOR="<%= $box_bgcolor || '#c0c0c0' %>" BORDER=0 CELLSPACING=2 CELLPADDING=0> @@ -65,7 +65,6 @@ if ( $phone_login ) { <B>OR</B><BR><BR> <FORM ACTION="$self_url" METHOD=POST> - <INPUT TYPE="hidden" NAME="session" VALUE="login"> <TABLE BGCOLOR="$box_bgcolor" BORDER=0 CELLSPACING=2 CELLPADDING=0> <TR> <TH ALIGN="right">Phone number </TH> diff --git a/fs_selfservice/FS-SelfService/cgi/logout.html b/fs_selfservice/FS-SelfService/cgi/logout.html index 5e22ad80c..834ef13f2 100644 --- a/fs_selfservice/FS-SelfService/cgi/logout.html +++ b/fs_selfservice/FS-SelfService/cgi/logout.html @@ -1,5 +1,6 @@ <HTML> <HEAD> + <META HTTP-EQUIV="refresh" CONTENT="5;URL=<%= $cgi->url(-absolute => 1) %>"> <TITLE>MyAccount</TITLE> <%= $head %> </HEAD> diff --git a/fs_selfservice/FS-SelfService/cgi/make_ach_payment.html b/fs_selfservice/FS-SelfService/cgi/make_ach_payment.html index 5b81b00a4..e33ad574c 100644 --- a/fs_selfservice/FS-SelfService/cgi/make_ach_payment.html +++ b/fs_selfservice/FS-SelfService/cgi/make_ach_payment.html @@ -1,8 +1,6 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Make a payment') %> <FORM NAME="OneTrueForm" METHOD="POST" ACTION="<%=$selfurl%>" onSubmit="document.OneTrueForm.process.disabled=true"> -<INPUT TYPE="hidden" NAME="session" VALUE="<%=$session_id%>"> <INPUT TYPE="hidden" NAME="action" VALUE="ach_payment_results"> <TABLE BGCOLOR="#cccccc"> <TR> diff --git a/fs_selfservice/FS-SelfService/cgi/make_payment.html b/fs_selfservice/FS-SelfService/cgi/make_payment.html index defd4a551..915714cc3 100644 --- a/fs_selfservice/FS-SelfService/cgi/make_payment.html +++ b/fs_selfservice/FS-SelfService/cgi/make_payment.html @@ -1,8 +1,6 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Make a payment') %> <FORM NAME="OneTrueForm" METHOD="POST" ACTION="<%=$selfurl%>" onSubmit="document.OneTrueForm.process.disabled=true"> -<INPUT TYPE="hidden" NAME="session" VALUE="<%=$session_id%>"> <INPUT TYPE="hidden" NAME="action" VALUE="payment_results"> <TABLE BGCOLOR="#cccccc"> <TR> diff --git a/fs_selfservice/FS-SelfService/cgi/make_thirdparty_payment.html b/fs_selfservice/FS-SelfService/cgi/make_thirdparty_payment.html index 59ee93b00..9a5678e8f 100755 --- a/fs_selfservice/FS-SelfService/cgi/make_thirdparty_payment.html +++ b/fs_selfservice/FS-SelfService/cgi/make_thirdparty_payment.html @@ -1,15 +1,12 @@ -<%= $url = "$selfurl?session=$session_id;action="; - $cgi = new CGI; - ''; %> <%= include('header', 'Make a payment') %> +<%= if ( $error ) { + $OUT .= qq!<FONT SIZE="+1" COLOR="#ff0000">$error</FONT><BR><BR>!; +} ''; %> <FORM NAME="OneTrueForm" METHOD="POST" ACTION="<%=$selfurl%>" onSubmit="document.OneTrueForm.process.disabled=true"> -<INPUT TYPE="hidden" NAME="session" VALUE="<%=$session_id%>"> <INPUT TYPE="hidden" NAME="action" VALUE="post_thirdparty_payment"> -<INPUT TYPE="hidden" NAME="payby_method" VALUE="<%= -$cgi->param('payby_method') =~ /(CC|ECHECK|PAYPAL)/; -$1 %>"> +<INPUT TYPE="hidden" NAME="payby_method" VALUE="<%= $payby_method %>"> <TABLE BGCOLOR="#cccccc"> <TR> <TH ALIGN="right">Balance due</TH> diff --git a/fs_selfservice/FS-SelfService/cgi/myaccount.html b/fs_selfservice/FS-SelfService/cgi/myaccount.html index a6352e07a..66e2c692e 100644 --- a/fs_selfservice/FS-SelfService/cgi/myaccount.html +++ b/fs_selfservice/FS-SelfService/cgi/myaccount.html @@ -1,4 +1,4 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> +<%= $url = "$selfurl?action="; ''; %> <%= include('header', 'My Account') %> Hello <%= $name %>!<BR><BR> diff --git a/fs_selfservice/FS-SelfService/cgi/myaccount_menu.html b/fs_selfservice/FS-SelfService/cgi/myaccount_menu.html index cf719e849..7d1a5f793 100644 --- a/fs_selfservice/FS-SelfService/cgi/myaccount_menu.html +++ b/fs_selfservice/FS-SelfService/cgi/myaccount_menu.html @@ -1,4 +1,4 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> +<%= $url = "$selfurl?action="; ''; %> <TABLE BORDER=0><TR> <TD VALIGN="top" BGCOLOR="<%= $menu_bgcolor || $box_bgcolor || '#c0c0c0' %>"> diff --git a/fs_selfservice/FS-SelfService/cgi/order_pkg.html b/fs_selfservice/FS-SelfService/cgi/order_pkg.html index 79335a0c2..84a10abcb 100644 --- a/fs_selfservice/FS-SelfService/cgi/order_pkg.html +++ b/fs_selfservice/FS-SelfService/cgi/order_pkg.html @@ -12,7 +12,6 @@ function enable_order_pkg () { $OUT .= qq!<FONT SIZE="+1" COLOR="#ff0000">$error</FONT><BR><BR>!; } ''; %> <FORM NAME="OrderPkgForm" ACTION="<%= $selfurl %>" METHOD=POST> -<INPUT TYPE="hidden" NAME="session" VALUE="<%= $session_id %>"> <INPUT TYPE="hidden" NAME="action" VALUE="process_order_pkg"> <INPUT TYPE="hidden" NAME="custnum" VALUE="<%= $custnum %>"> <TABLE BGCOLOR="#cccccc" BORDER=0 CELLSPACING=0> diff --git a/fs_selfservice/FS-SelfService/cgi/payment_results.html b/fs_selfservice/FS-SelfService/cgi/payment_results.html index be727cb7d..04a0611d0 100644 --- a/fs_selfservice/FS-SelfService/cgi/payment_results.html +++ b/fs_selfservice/FS-SelfService/cgi/payment_results.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Payment results') %> <%= if ( $error ) { diff --git a/fs_selfservice/FS-SelfService/cgi/post_thirdparty_payment.html b/fs_selfservice/FS-SelfService/cgi/post_thirdparty_payment.html index 17710b2e5..ed7c2a32b 100644 --- a/fs_selfservice/FS-SelfService/cgi/post_thirdparty_payment.html +++ b/fs_selfservice/FS-SelfService/cgi/post_thirdparty_payment.html @@ -1,42 +1,21 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> -<%= include('header', 'Pay now') %> - -<SCRIPT TYPE="text/javascript" SRC="overlibmws.js"></SCRIPT> -<SCRIPT TYPE="text/javascript" SRC="overlibmws_iframe.js"></SCRIPT> -<SCRIPT TYPE="text/javascript" SRC="overlibmws_draggable.js"></SCRIPT> -<SCRIPT TYPE="text/javascript" SRC="overlibmws_crossframe.js"></SCRIPT> -<SCRIPT TYPE="text/javascript" SRC="iframecontentmws.js"></SCRIPT> - -<%= if ( $error ) { - $OUT .= qq!<FONT SIZE="+1" COLOR="#ff0000">$error</FONT><BR><BR>!; -}else{ - $OUT .= <<EOF; - You are about to contact our payment processor to pay $amount.<BR><BR> - Your transaction reference number is $reference <BR><BR> - <FORM METHOD="POST" ACTION="$popup_url"> -EOF - -#<FORM NAME="collect_popper" method="post" action="javascript:void(0)" onSubmit="popcollect()"> - my %itemhash = @collectitems; -# my $query = join(';', -# map { uri_escape($_) . '=' . uri_escape($itemhash{$_}) } -# keys(%itemhash) -# ); - foreach my $input (keys(%itemhash)) { - $OUT .= qq!<INPUT NAME="$input" TYPE="hidden" VALUE="$itemhash{$input}">\n!; - } - $OUT .= qq!<INPUT NAME="submit" TYPE="submit" VALUE="Pay now"></FORM>! +<HTML> + <HEAD> + <TITLE>Redirecting to payment processor...</TITLE> + </HEAD> + <BODY> + <H1>Redirecting to payment processor...</H1> + <FORM ID="autoform" ENCTYPE="multipart/form-data" ACTION="<%= $url %>" METHOD="POST" STYLE="display:none"> +<%= foreach my $name (keys %post_params) { + my $value = encode_entities($post_params{$name}); + $OUT .= ' + <INPUT NAME="' . $name . '" TYPE="hidden" VALUE="' . $value . '">'; +} %> + <INPUT TYPE="submit" VALUE="submit"> + </FORM> + <SCRIPT TYPE="text/javascript"> +window.onload = function() { + document.getElementById('autoform').submit(); } -%> - -<%= -#<SCRIPT TYPE="text/javascript"> -# function popcollect() { -# overlib( OLiframeContent('<%= $popup_url %>', 336, 550, 'Secure Payment Area', 0, 'auto' ), CAPTION, 'Pay now', STICKY, AUTOSTATUSCAP, MIDX, 0, MIDY, 0, DRAGGABLE, CLOSECLICK, BGCOLOR, '#333399', CGCOLOR, '#333399', CLOSETEXT, 'Close' ); -# overlib( OLpostAJAX('<%= $popup_url %>', -# return false; -# } -#</SCRIPT> -%> - -<%= include('footer') %> + </SCRIPT> + </BODY> +</HTML> diff --git a/fs_selfservice/FS-SelfService/cgi/process_change_bill.html b/fs_selfservice/FS-SelfService/cgi/process_change_bill.html index bf7ad778d..795cc12b0 100644 --- a/fs_selfservice/FS-SelfService/cgi/process_change_bill.html +++ b/fs_selfservice/FS-SelfService/cgi/process_change_bill.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Information updated successfully') %> <FONT SIZE=4>Information updated successfully.</FONT> <%= include('footer') %> diff --git a/fs_selfservice/FS-SelfService/cgi/process_change_password.html b/fs_selfservice/FS-SelfService/cgi/process_change_password.html index 4eca91fb6..d16c460c3 100644 --- a/fs_selfservice/FS-SelfService/cgi/process_change_password.html +++ b/fs_selfservice/FS-SelfService/cgi/process_change_password.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', "Password changed" ) %> <FONT SIZE=4>Password changed for <%= $value %> <%= $label %>.</FONT> diff --git a/fs_selfservice/FS-SelfService/cgi/process_change_pay.html b/fs_selfservice/FS-SelfService/cgi/process_change_pay.html index e399aea17..8fb33b299 100644 --- a/fs_selfservice/FS-SelfService/cgi/process_change_pay.html +++ b/fs_selfservice/FS-SelfService/cgi/process_change_pay.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Information updated successfully' ) %> <FONT SIZE=4>Information updated successfully.</FONT> <%= include('footer') %> diff --git a/fs_selfservice/FS-SelfService/cgi/process_change_pkg.html b/fs_selfservice/FS-SelfService/cgi/process_change_pkg.html index bf15b6ea6..126e2a454 100644 --- a/fs_selfservice/FS-SelfService/cgi/process_change_pkg.html +++ b/fs_selfservice/FS-SelfService/cgi/process_change_pkg.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Package change successful') %> <%= include('footer') %> diff --git a/fs_selfservice/FS-SelfService/cgi/process_change_ship.html b/fs_selfservice/FS-SelfService/cgi/process_change_ship.html index bf7ad778d..795cc12b0 100644 --- a/fs_selfservice/FS-SelfService/cgi/process_change_ship.html +++ b/fs_selfservice/FS-SelfService/cgi/process_change_ship.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Information updated successfully') %> <FONT SIZE=4>Information updated successfully.</FONT> <%= include('footer') %> diff --git a/fs_selfservice/FS-SelfService/cgi/process_order_pkg.html b/fs_selfservice/FS-SelfService/cgi/process_order_pkg.html index 649d92092..b76dafbaa 100755 --- a/fs_selfservice/FS-SelfService/cgi/process_order_pkg.html +++ b/fs_selfservice/FS-SelfService/cgi/process_order_pkg.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Package order successful') %> <FONT SIZE=4>Package order successful.</FONT> diff --git a/fs_selfservice/FS-SelfService/cgi/process_order_recharge.html b/fs_selfservice/FS-SelfService/cgi/process_order_recharge.html index 4a16ec56a..659f110df 100644 --- a/fs_selfservice/FS-SelfService/cgi/process_order_recharge.html +++ b/fs_selfservice/FS-SelfService/cgi/process_order_recharge.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', "$svc recharged successfully") %> <FONT SIZE=4><%= $svc %> recharged successfully.</FONT> diff --git a/fs_selfservice/FS-SelfService/cgi/process_suspend_pkg.html b/fs_selfservice/FS-SelfService/cgi/process_suspend_pkg.html index d5c62f4f1..2a9805f18 100644 --- a/fs_selfservice/FS-SelfService/cgi/process_suspend_pkg.html +++ b/fs_selfservice/FS-SelfService/cgi/process_suspend_pkg.html @@ -1,3 +1,2 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Package suspended') %> <%= include('footer') %> diff --git a/fs_selfservice/FS-SelfService/cgi/process_svc_acct.html b/fs_selfservice/FS-SelfService/cgi/process_svc_acct.html index d6515e7f4..48f6a85ce 100644 --- a/fs_selfservice/FS-SelfService/cgi/process_svc_acct.html +++ b/fs_selfservice/FS-SelfService/cgi/process_svc_acct.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', "$svc setup successfully") %> <FONT SIZE=4><%= $svc %> setup successfully.</FONT> diff --git a/fs_selfservice/FS-SelfService/cgi/process_svc_external.html b/fs_selfservice/FS-SelfService/cgi/process_svc_external.html index c20aae02c..48d70b04e 100644 --- a/fs_selfservice/FS-SelfService/cgi/process_svc_external.html +++ b/fs_selfservice/FS-SelfService/cgi/process_svc_external.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', "$svc setup successfully") %> <FONT SIZE=4><%= $svc %> setup successfully.</FONT> diff --git a/fs_selfservice/FS-SelfService/cgi/process_svc_phone.html b/fs_selfservice/FS-SelfService/cgi/process_svc_phone.html index d6515e7f4..48f6a85ce 100644 --- a/fs_selfservice/FS-SelfService/cgi/process_svc_phone.html +++ b/fs_selfservice/FS-SelfService/cgi/process_svc_phone.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', "$svc setup successfully") %> <FONT SIZE=4><%= $svc %> setup successfully.</FONT> diff --git a/fs_selfservice/FS-SelfService/cgi/provision.html b/fs_selfservice/FS-SelfService/cgi/provision.html index cd8028a0d..808e4b54d 100644 --- a/fs_selfservice/FS-SelfService/cgi/provision.html +++ b/fs_selfservice/FS-SelfService/cgi/provision.html @@ -1,5 +1,4 @@ -<%= $url = "$selfurl?session=$session_id;action="; - $heading1 = "Setup my services"; +<%= $heading1 = "Setup my services"; $heading1 = "Package list" if $wholesale_view; $provision_list = "provision_list"; $provision_list = "ws_list" if $wholesale_view; diff --git a/fs_selfservice/FS-SelfService/cgi/provision_svc_acct.html b/fs_selfservice/FS-SelfService/cgi/provision_svc_acct.html index bae57305e..c63a838df 100644 --- a/fs_selfservice/FS-SelfService/cgi/provision_svc_acct.html +++ b/fs_selfservice/FS-SelfService/cgi/provision_svc_acct.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Setup account') %> <%= include('svc_acct') %> diff --git a/fs_selfservice/FS-SelfService/cgi/provision_svc_phone.html b/fs_selfservice/FS-SelfService/cgi/provision_svc_phone.html index 9a07e7da1..9ac039d74 100644 --- a/fs_selfservice/FS-SelfService/cgi/provision_svc_phone.html +++ b/fs_selfservice/FS-SelfService/cgi/provision_svc_phone.html @@ -1,5 +1,4 @@ -<%= $url = "$selfurl?session=$session_id;action="; - $heading2 = $lnp ? "Port-In Number" : "Setup phone number"; +<%= $heading2 = $lnp ? "Port-In Number" : "Setup phone number"; ''; %> <%= include('header', $heading2) %> @@ -15,8 +14,7 @@ if($error) { } %> -<FORM name="OneTrueForm" action="<%= $url %>" METHOD="POST"> -<INPUT TYPE="hidden" NAME="session" VALUE="<%= $session_id %>"> +<FORM name="OneTrueForm" action="<%= $selfurl %>" METHOD="POST"> <INPUT TYPE="hidden" NAME="action" VALUE="process_svc_phone"> <INPUT TYPE="hidden" NAME="pkgnum" VALUE="<%= $pkgnum %>"> <INPUT TYPE="hidden" NAME="svcpart" VALUE="<%= $svcpart %>"> diff --git a/fs_selfservice/FS-SelfService/cgi/recharge_prepay.html b/fs_selfservice/FS-SelfService/cgi/recharge_prepay.html index c716e8242..e47f8003a 100644 --- a/fs_selfservice/FS-SelfService/cgi/recharge_prepay.html +++ b/fs_selfservice/FS-SelfService/cgi/recharge_prepay.html @@ -1,8 +1,6 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Recharge with prepaid card') %> <FORM NAME="OneTrueForm" METHOD="POST" ACTION="<%=$selfurl%>" onSubmit="document.OneTrueForm.process.disabled=true"> -<INPUT TYPE="hidden" NAME="session" VALUE="<%=$session_id%>"> <INPUT TYPE="hidden" NAME="action" VALUE="recharge_results"> <TABLE BGCOLOR="#cccccc"> <!-- diff --git a/fs_selfservice/FS-SelfService/cgi/recharge_results.html b/fs_selfservice/FS-SelfService/cgi/recharge_results.html index 147b66bbe..919977a73 100644 --- a/fs_selfservice/FS-SelfService/cgi/recharge_results.html +++ b/fs_selfservice/FS-SelfService/cgi/recharge_results.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Recharge results') %> <%= if ( $error ) { diff --git a/fs_selfservice/FS-SelfService/cgi/selfservice.cgi b/fs_selfservice/FS-SelfService/cgi/selfservice.cgi index 40fe98af2..ea2a40bfa 100755 --- a/fs_selfservice/FS-SelfService/cgi/selfservice.cgi +++ b/fs_selfservice/FS-SelfService/cgi/selfservice.cgi @@ -1,10 +1,11 @@ -#!/usr/bin/perl -Tw +#!/usr/bin/perl -w use strict; use vars qw($DEBUG $cgi $session_id $form_max $template_dir); use subs qw(do_template); use CGI; use CGI::Carp qw(fatalsToBrowser); +use CGI::Cookie; use Text::Template; use HTML::Entities; use Date::Format; @@ -20,6 +21,7 @@ use FS::SelfService qw( myaccount_passwd list_invoices create_ticket get_ticket did_report adjust_ticket_priority mason_comp port_graph + start_thirdparty finish_thirdparty ); $template_dir = '.'; @@ -29,49 +31,85 @@ $DEBUG = 0; $form_max = 255; $cgi = new CGI; +my %cookies = CGI::Cookie->fetch; -unless ( defined $cgi->param('session') ) { - my $login_info = login_info( 'agentnum' => scalar($cgi->param('agentnum')) ); +my $login_rv; - do_template('login', $login_info ); - exit; -} +if ( exists($cookies{'session'}) ) { -if ( $cgi->param('session') eq 'login' ) { + $session_id = $cookies{'session'}->value; - $cgi->param('username') =~ /^\s*([a-z0-9_\-\.\&]{0,$form_max})\s*$/i - or die "illegal username"; - my $username = $1; + if ( $session_id eq 'login' ) { + # then we've just come back from the login page - $cgi->param('domain') =~ /^\s*([\w\-\.]{0,$form_max})\s*$/ - or die "illegal domain"; - my $domain = $1; + $cgi->param('username') =~ /^\s*([a-z0-9_\-\.\&]{0,$form_max})\s*$/i; + my $username = $1; - $cgi->param('password') =~ /^(.{0,$form_max})$/ - or die "illegal password"; - my $password = $1; + $cgi->param('domain') =~ /^\s*([\w\-\.]{0,$form_max})\s*$/; + my $domain = $1; - my $rv = login( - 'username' => $username, - 'domain' => $domain, - 'password' => $password, - ); - if ( $rv->{error} ) { - my $login_info = login_info( 'agentnum' => $cgi->param('agentnum') ); - do_template('login', { - 'error' => $rv->{error}, - 'username' => $username, - 'domain' => $domain, - %$login_info, - } ); - exit; - } else { - $cgi->param('session' => $rv->{session_id} ); - $cgi->param('action' => 'myaccount' ); - } + $cgi->param('password') =~ /^(.{0,$form_max})$/; + my $password = $1; + + if ( $username and $domain and $password ) { + + # authenticate + $login_rv = login( + 'username' => $username, + 'domain' => $domain, + 'password' => $password, + ); + $session_id = $login_rv->{'session_id'}; + + } elsif ( $username or $domain or $password ) { + + my $error = 'Illegal '; #XXX localization... + my $count = 0; + if ( !$username ) { + $error .= 'username'; + $count++; + } + if ( !$domain ) { + $error .= ', ' if $count; + $error .= 'domain'; + $count++; + } + if ( !$password ) { + $error .= ', ' if $count; + $error .= 'and ' if $count > 1; + $error .= 'password'; + $count++; + } + $error .= '.'; + $login_rv = { + 'username' => $username, + 'domain' => $domain, + 'password' => $password, + 'error' => $error, + }; + $session_id = undef; # attempt login again + + } # else there was no input, so show no error message + } # else session_id ne 'login' + +} else { + # there is no session cookie + $login_rv = {}; } -$session_id = $cgi->param('session'); +if ( !$session_id ) { + # XXX why are we getting agentnum from a CGI param? surely it should + # be some kind of configuration option. + # + # show the login page + $session_id = 'login'; # set state + my $login_info = login_info( 'agentnum' => scalar($cgi->param('agentnum')) ); + + do_template('login', { %$login_rv, %$login_info }); + exit; +} + +# at this point $session_id is a real session #order|pw_list XXX ??? my @actions = ( qw( @@ -87,6 +125,8 @@ my @actions = ( qw( make_term_payment make_thirdparty_payment post_thirdparty_payment + finish_thirdparty_payment + cancel_thirdparty_payment payment_results ach_payment_results recharge_prepay @@ -120,10 +160,15 @@ my @actions = ( qw( customer_suspend_pkg process_suspend_pkg )); - -$cgi->param('action') =~ ( '^(' . join('|', @actions) . ')$' ) - or die "unknown action ". $cgi->param('action'); -my $action = $1; + +my $action = 'myaccount'; # sensible default +if ( $cgi->param('action') =~ /^(\w+)$/ ) { + if (grep {$_ eq $1} @actions) { + $action = $1; + } else { + warn "WARNING: unrecognized action '$1'\n"; + } +} warn "calling $action sub\n" if $DEBUG; @@ -136,6 +181,7 @@ warn Dumper($result) if $DEBUG; if ( $result->{error} && ( $result->{error} eq "Can't resume session" || $result->{error} eq "Expired session") ) { #ick + $session_id = 'login'; my $login_info = login_info(); do_template('login', $login_info); exit; @@ -663,7 +709,13 @@ sub ach_payment_results { } sub make_thirdparty_payment { - payment_info('session_id' => $session_id); + my $payment_info = payment_info('session_id' => $session_id); + $cgi->param('payby_method') =~ /^(CC|ECHECK|PAYPAL)$/ + or die "illegal payby method"; + $payment_info->{'payby_method'} = $1; + $payment_info->{'error'} = $cgi->param('error'); + + $payment_info; } sub post_thirdparty_payment { @@ -673,17 +725,32 @@ sub post_thirdparty_payment { $cgi->param('amount') =~ /^(\d+(\.\d*)?)$/ or die "illegal amount"; my $amount = $1; - # realtime_collect() returns the result from FS::cust_main->realtime_collect - # which returns realtime_bop() - # which returns a hashref of popup_url, collectitems, and reference - my $result = realtime_collect( + my $result = start_thirdparty( 'session_id' => $session_id, 'method' => $method, 'amount' => $amount, ); + if ( $result->{error} ) { + $cgi->param('action', 'make_thirdparty_payment'); + $cgi->param('error', $result->{error}); + print $cgi->redirect( $cgi->self_url ); + exit; + } + $result; } +sub finish_thirdparty_payment { + my %param = $cgi->Vars; + finish_thirdparty( 'session_id' => $session_id, %param ); + # result contains either 'error' => error message, or the payment details +} + +sub cancel_thirdparty_payment { + $action = 'make_thirdparty_payment'; + finish_thirdparty( 'session_id' => $session_id, '_cancel' => 1 ); +} + sub make_term_payment { $cgi->param('amount') =~ /^(\d+\.\d{2})$/ or die "illegal payment amount"; @@ -933,54 +1000,63 @@ sub do_template { $cgi->delete_all(); $fill_in->{'selfurl'} = $cgi->self_url; $fill_in->{'cgi'} = \$cgi; + $fill_in->{'error'} = $cgi->param('error') if $cgi->param('error'); - my $access_info = $session_id + my $access_info = ($session_id and $session_id ne 'login') ? access_info( 'session_id' => $session_id ) : {}; $fill_in->{$_} = $access_info->{$_} foreach keys %$access_info; - - if($result && ref($result) && $result->{'format'} && $result->{'content'} - && $result->{'format'} eq 'csv') { - print $cgi->header('-expires' => 'now', - '-Content-Type' => 'text/csv', - '-Content-Disposition' => "attachment;filename=output.csv", - ), - $result->{'content'}; - } - elsif($result && ref($result) && $result->{'format'} && $result->{'content'} - && $result->{'format'} eq 'xls') { - print $cgi->header('-expires' => 'now', - '-Content-Type' => 'application/vnd.ms-excel', - '-Content-Disposition' => "attachment;filename=output.xls", - '-Content-Length' => length($result->{'content'}), - ), - $result->{'content'}; - } - elsif($result && ref($result) && $result->{'format'} && $result->{'content'} - && $result->{'format'} eq 'png') { - print $cgi->header('-expires' => 'now', - '-Content-Type' => 'image/png', - ), - $result->{'content'}; - } - else { - my $source = "$template_dir/$name.html"; - my $template = new Text::Template( TYPE => 'FILE', - SOURCE => $source, - DELIMITERS => [ '<%=', '%>' ], - UNTAINT => 1, - ) - or die $Text::Template::ERROR; - - my $data = $template->fill_in( - PACKAGE => 'FS::SelfService::_selfservicecgi', - HASH => $fill_in, - ) || "Error processing template $source"; # at least print _something_ - print $cgi->header( '-expires' => 'now' ); - print $data; + # update the user's authentication + my $timeout = $access_info->{'timeout'} || '60'; + my $cookie = CGI::Cookie->new('-name' => 'session', + '-value' => $session_id, + '-expires' => '+'.$timeout, + #'-secure' => 1, # would be a good idea... + ); + if ( $name eq 'logout' ) { + $cookie->expires(0); + } + + if ( $fill_in->{'format'} ) { + # then override content-type, and return $fill_in->{'content'} instead + # of filling in a template + if ( $fill_in->{'format'} eq 'csv') { + print $cgi->header('-expires' => 'now', + '-Content-Type' => 'text/csv', + '-Content-Disposition' => "attachment;filename=output.csv", + ); + } elsif ( $fill_in->{'format'} eq 'xls' ) { + print $cgi->header('-expires' => 'now', + '-Content-Type' => 'application/vnd.ms-excel', + '-Content-Disposition' => "attachment;filename=output.xls", + '-Content-Length' => length($fill_in->{'content'}), + ); + } elsif ( $fill_in->{'format'} eq 'png' ) { + print $cgi->header('-expires' => 'now', + '-Content-Type' => 'image/png', + ); } - } + print $fill_in->{'content'}; + } else { # the usual case + my $source = "$template_dir/$name.html"; + my $template = new Text::Template( + TYPE => 'FILE', + SOURCE => $source, + DELIMITERS => [ '<%=', '%>' ], + UNTAINT => 1, + ) + or die $Text::Template::ERROR; + + my $data = $template->fill_in( + PACKAGE => 'FS::SelfService::_selfservicecgi', + HASH => $fill_in, + ) || "Error processing template $source"; # at least print _something_ + print $cgi->header( '-cookie' => $cookie, + '-expires' => 'now' ); + print $data; + } +} #*FS::SelfService::_selfservicecgi::include = \&Text::Template::fill_in_file; @@ -1011,4 +1087,4 @@ sub include { } -1; + diff --git a/fs_selfservice/FS-SelfService/cgi/svc_acct.html b/fs_selfservice/FS-SelfService/cgi/svc_acct.html index 00244386b..09d9163a1 100644 --- a/fs_selfservice/FS-SelfService/cgi/svc_acct.html +++ b/fs_selfservice/FS-SelfService/cgi/svc_acct.html @@ -5,7 +5,6 @@ '</FONT><BR><BR>'; } ''; %> <FORM ACTION="<%= $selfurl %>" METHOD=POST> -<INPUT TYPE="hidden" NAME="session" VALUE="<%= $session_id %>"> <INPUT TYPE="hidden" NAME="action" VALUE="process_svc_acct"> <INPUT TYPE="hidden" NAME="custnum" VALUE="<%= $custnum %>"> <INPUT TYPE="hidden" NAME="pkgnum" VALUE="<%= $pkgnum %>"> diff --git a/fs_selfservice/FS-SelfService/cgi/ticket_summary.html b/fs_selfservice/FS-SelfService/cgi/ticket_summary.html index 4333c4e92..94043bfb6 100644 --- a/fs_selfservice/FS-SelfService/cgi/ticket_summary.html +++ b/fs_selfservice/FS-SelfService/cgi/ticket_summary.html @@ -12,7 +12,6 @@ my $can_set_priority = if ( $can_set_priority ) { $OUT .= qq!<FORM ACTION="$selfurl" METHOD="POST">! . - qq!<INPUT TYPE="hidden" NAME="session" VALUE="$session_id">! . qq!<INPUT TYPE="hidden" NAME="action" VALUE="ticket_priority">!; } $date_format ||= '%Y-%m-%d'; diff --git a/fs_selfservice/FS-SelfService/cgi/tktcreate.html b/fs_selfservice/FS-SelfService/cgi/tktcreate.html index de7ff60b8..1e1ecb659 100644 --- a/fs_selfservice/FS-SelfService/cgi/tktcreate.html +++ b/fs_selfservice/FS-SelfService/cgi/tktcreate.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Create a ticket') %> <%= @@ -10,7 +9,6 @@ if ( $ticket_id ) { Please fill in both the subject and message <br><br> <FORM ACTION="$selfurl" METHOD=POST> - <input type="hidden" name="session" value="$session_id"> <input type="hidden" name="action" value="tktcreate"> <table> <tr> diff --git a/fs_selfservice/FS-SelfService/cgi/tktview.html b/fs_selfservice/FS-SelfService/cgi/tktview.html index 72634fee2..974dd6b01 100644 --- a/fs_selfservice/FS-SelfService/cgi/tktview.html +++ b/fs_selfservice/FS-SelfService/cgi/tktview.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', "View ticket #$ticket_id") %> <%= @@ -20,7 +19,6 @@ else { %> <BR><BR><BR> <FORM ACTION="<%=$selfurl%>" METHOD=POST> - <input type="hidden" name="session" value="<%=$session_id%>"> <input type="hidden" name="ticket_id" value="<%=$ticket_id%>"> <%= if ( $edit_ticket_subject ) { $OUT .= ' Subject:<BR><input type="text" name="subject" value="' . diff --git a/fs_selfservice/FS-SelfService/cgi/view_cdr_details.html b/fs_selfservice/FS-SelfService/cgi/view_cdr_details.html index 0ee8e9635..f39668247 100644 --- a/fs_selfservice/FS-SelfService/cgi/view_cdr_details.html +++ b/fs_selfservice/FS-SelfService/cgi/view_cdr_details.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', ($inbound ? 'Received calls' : 'Dialed calls' ) . ' for '. Date::Format::time2str('%b %o %Y', $beginning). diff --git a/fs_selfservice/FS-SelfService/cgi/view_customer.html b/fs_selfservice/FS-SelfService/cgi/view_customer.html index 5bfb9b6fd..a40cd5a45 100644 --- a/fs_selfservice/FS-SelfService/cgi/view_customer.html +++ b/fs_selfservice/FS-SelfService/cgi/view_customer.html @@ -1,6 +1,5 @@ <HTML><HEAD><TITLE>Reseller</TITLE></HEAD> <BODY BGCOLOR="#eeeeee"><FONT SIZE=5>Reseller</FONT><BR><BR> -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <TABLE BORDER=0 CELLPADDING=4><TR> <%= include('agent_menu') %> <TD VALIGN="top"> diff --git a/fs_selfservice/FS-SelfService/cgi/view_invoice.html b/fs_selfservice/FS-SelfService/cgi/view_invoice.html index 072a4147c..d49a466d2 100644 --- a/fs_selfservice/FS-SelfService/cgi/view_invoice.html +++ b/fs_selfservice/FS-SelfService/cgi/view_invoice.html @@ -1,4 +1,3 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> <%= include('header', 'Invoice') %> <%= $invoice_html %> diff --git a/fs_selfservice/FS-SelfService/cgi/view_port_graph.html b/fs_selfservice/FS-SelfService/cgi/view_port_graph.html index d42f405b9..0d32a88c4 100644 --- a/fs_selfservice/FS-SelfService/cgi/view_port_graph.html +++ b/fs_selfservice/FS-SelfService/cgi/view_port_graph.html @@ -1,4 +1,4 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> +<%= $url = "$selfurl?action="; ''; %> <%= include('header', "Service usage details for $start - $end") %> <%= if ( $error ) { diff --git a/fs_selfservice/FS-SelfService/cgi/view_support_details.html b/fs_selfservice/FS-SelfService/cgi/view_support_details.html index 104b061bc..b401be4f4 100644 --- a/fs_selfservice/FS-SelfService/cgi/view_support_details.html +++ b/fs_selfservice/FS-SelfService/cgi/view_support_details.html @@ -1,4 +1,4 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> +<%= $url = "$selfurl?action="; ''; %> <%= include('header', 'Usage details') %> <FONT SIZE=4>Support usage details for diff --git a/fs_selfservice/FS-SelfService/cgi/view_usage.html b/fs_selfservice/FS-SelfService/cgi/view_usage.html index 35d128998..f50f77078 100644 --- a/fs_selfservice/FS-SelfService/cgi/view_usage.html +++ b/fs_selfservice/FS-SelfService/cgi/view_usage.html @@ -1,4 +1,4 @@ -<%= $url = "$selfurl?session=$session_id;action="; +<%= $url = "$selfurl?action="; %by_pkg_label = (); # not used yet, but I'm sure it will be... @svc_acct = (); @svc_phone = (); @@ -196,8 +196,7 @@ foreach my $svc_port ( @svc_port ) { $OUT .= '<TR><TD>'. $svc_port->{'label'}. ': '. $svc_port->{'value'}.'</TD>'; $OUT .= qq! <TD><FORM ACTION="$url" METHOD="GET"> <INPUT TYPE="hidden" name="svcnum" value="$svcnum"> - <INPUT TYPE="hidden" name="action" value="view_port_graph"> - <INPUT TYPE="hidden" name="session" value="$session_id"> !; + <INPUT TYPE="hidden" name="action" value="view_port_graph"> !; $OUT .= preset_range($default_start,$default_end,'Last Day',$date_format,$svcnum) .' | '.preset_range($default_end-86400*7,$default_end,'Last Week',$date_format,$svcnum) .' | '.preset_range($default_end-86400*30,$default_end,'Last Month',$date_format,$svcnum) diff --git a/fs_selfservice/FS-SelfService/cgi/view_usage_details.html b/fs_selfservice/FS-SelfService/cgi/view_usage_details.html index c4cc177e1..0388c2fad 100644 --- a/fs_selfservice/FS-SelfService/cgi/view_usage_details.html +++ b/fs_selfservice/FS-SelfService/cgi/view_usage_details.html @@ -1,4 +1,4 @@ -<%= $url = "$selfurl?session=$session_id;action="; ''; %> +<%= $url = "$selfurl?;action="; ''; %> <%= include('header', 'Service usage details for '. Date::Format::time2str('%b %o %Y', $beginning). ' - '. |