$company = new SI_Company(); $companies = $company->getCompanysWithUnbilledAmount(); if($companies === FALSE){ $error_msg .= "Could not retrieve Outstanding Hours list!\n"; debug_message($company->getLastError()); } $user = new SI_User(); $users = $user->getUnpaidUsers(); if($users === FALSE){ $error_msg .= "Could not retrieve Unpaid Users's list!\n"; debug_message($user->getLastError()); } $invoice = new SI_Invoice(); $invoices = $invoice->getOutstanding(); if($invoices === FALSE){ $error_msg .= "Could not retrieve Outstanding Invoice list!\n"; debug_message($invoice->getLastError()); } $check = new SI_Check(); $checks = $check->retrieveSet("ORDER BY timestamp DESC LIMIT 5"); if($checks === FALSE){ $error_msg .= "Could not retrieve Check list!\n"; debug_message($check->getLastError()); } $ps = new SI_PaymentSchedule(); $time = time() + 30 * (24 * (60 * 60)); $ps_items = $ps->getUpcoming($time);
} $balance = $company->getBalance(); if($balance === FALSE){ $error_msg .= "Error getting your outstanding balance!"; debug_message($company->getLastError()); } $transactions = $company->getTransactions(NULL, 5); if($transactions === FALSE){ $error_msg .= "Error getting transactions for company!\n"; debug_message($company->getLastError()); } $invoice = new SI_Invoice(); $invoices = $invoice->getOutstanding($company->id); if($invoices === FALSE){ $error_msg .= "Could not retrieve Outstanding Invoice list!\n"; debug_message($invoice->getLastError()); } $project = new SI_Project(); $active_projects = TRUE; if(isset($_REQUEST['show_all']) && $_REQUEST['show_all'] == 'Y'){ $active_projects = FALSE; } $projects = $project->getCompanyProjects($company->id, $active_projects); if($projects === FALSE){ $error_msg .= "Could not retrieve active project list!\n"; debug_message($project->getLastError()); }