Ejemplo n.º 1
0
require_once "../includes/calendar.class.php";
require_once "../includes/rebill.class.php";
$sessionlogin = isset($HTTP_SESSION_VARS["sessionlogin"]) ? $HTTP_SESSION_VARS["sessionlogin"] : "";
/**************
Define functions to process form
**************/
$rebills = new rebill_class();
/****************
Process Form
****************/
if ($_REQUEST['frm_cancel_rebills'] == "1") {
    $rebills->set_access("admin");
    $rebills->cancel_rebills($_REQUEST['frm_cancel_ids']);
    unset($_REQUEST['frm_cancel_ids']);
    unset($_REQUEST['frm_cancel_rebills']);
    $params = $rebills->request_params("frm_");
    header("Location: rebillSummary.php?{$params}");
    exit;
}
/**************
Define pairs
**************/
$my_sql['pairs']['SubAccounts'] = array();
$my_sql['pairs']['SubAccounts'][] = array("display" => "All", "value" => "");
$my_sql['pairs']['Rebilling'] = array(array("display" => "Either", "value" => "0", "default" => 1), array("display" => "Pending", "value" => "1"), array("display" => "Processed", "value" => "2"));
$my_sql['pairs']['ResultsPerPage'] = array(array("display" => "All", "value" => "1000000"), array("display" => "10", "value" => "10"), array("display" => "25", "value" => "25"), array("display" => "50", "value" => "50"), array("display" => "100", "value" => "100"));
$my_sql['pairs']['DisplayRange'] = array(array("display" => "Display All", "value" => "", "default" => 1), array("display" => "Selected Dates", "value" => "1"));
$my_sql['pairs']['HideDuplicates'] = array(array("display" => "Yes", "value" => "1", "default" => 1), array("display" => "No", "value" => ""));
$my_sql['pairs']['SortBy'] = array(array("display" => "Name", "value" => "ss_billing_lastname", "default" => 1), array("display" => "Reference Number", "value" => "ss_subscription_id"), array("display" => "Amount", "value" => "ss_rebill_amount"), array("display" => "Next Rebill", "value" => "next_rebill_timestamp"));
$my_sql['pairs']['RebillTypes'] = array(array("display" => "Active", "value" => "active", "default" => 1), array("display" => "Inactive", "value" => "inactive"), array("display" => "Processing", "value" => "processing"));
$my_sql['pairs']['AccountTypes'] = array(array("display" => "All", "value" => "", "default" => 1), array("display" => "Active", "value" => "active"), array("display" => "Inactive", "value" => "inactive"));