default to a session cookie instead of setting an explicit timeout, weird timezone...
[freeside.git] / httemplate / edit / process / elements / ApplicationCommon.html
index a73b1bc..5007319 100644 (file)
@@ -24,9 +24,9 @@ Examples:
 %  my $query = $m->scomp('/elements/create_uri_query');
 <% $cgi->redirect(popurl(2). $opt{error_redirect}. "?$query") %>
 %} else {
-<% header("$src_thing application$to sucessful") %>
+<& /elements/header-popup.html, "$src_thing application$to successful" &>
   <SCRIPT TYPE="text/javascript">
-    window.top.location.reload();
+    topreload();
   </SCRIPT>
   </BODY>
   </HTML>
@@ -55,8 +55,12 @@ my $cust_main = qsearchs('cust_main', { 'custnum' => $src->custnum } )
 my $custnum = $cust_main->custnum;
 
 my @subnames = grep { /.+/ } map { /^subnum(\d+)$/ ? $1 : '' } $cgi->param;
-my @subitems = map { [ $cgi->param("subnum$_"), $cgi->param("subamount$_"), $cgi->param("taxXlocationnum$_") ] }
-               @subnames;
+my @subitems = map { [ scalar($cgi->param("subnum$_")),
+                       scalar($cgi->param("subamount$_")),
+                       scalar($cgi->param("taxXlocationnum$_"))
+                     ]
+                   }
+                 @subnames;
 { local $^W = 0; @subitems = grep { $_->[1] + 0 } @subitems; }
 
 my %options = ();
@@ -69,9 +73,9 @@ my $dbh = dbh;
 my $new;
 #  $new = new FS::cust_refund ( {
 #    'reason'  => 'Refunding payment', #enter reason in UI
-#    'refund'  => $cgi->param('amount'),
+#    'refund'  => scalar($cgi->param('amount')),
 #    'payby'   => 'BILL',
-#    #'_date'   => $cgi->param('_date'),
+#    #'_date'   => scalar($cgi->param('_date')),
 #    'payinfo' => 'Cash', #enter payinfo in UI
 #    'paynum' => $paynum,
 #  } );