예제 #1
0
*/
$pagetitle = "Invoices";
$navtitle = 'Invoices';
$keywords = '';
$description = '';
include "/srv/athenace/lib/shared/common.php";
include "/srv/athenace/lib/intranet/common.php";
include "/srv/athenace/lib/shared/functions_form.php";
if (!is_numeric($_GET['id'])) {
    header("Location: /invoices/?id=notFound");
    exit;
}
if (isset($_GET['go']) && $_GET['go'] == "y") {
    $invoicesDelete = new Invoices();
    $invoicesDelete->setInvoicesid($_GET['id']);
    $invoicesDelete->deleteFromDB();
    header("Location: /invoices/?ItemDeleted=y");
    exit;
}
include "../tmpl/header.php";
$invoices = new Invoices();
// Load DB data into object
$invoices->setInvoicesid($_GET['id']);
$invoices->loadInvoices();
$all = $invoices->getAll();
if (isset($all)) {
    ?>

<div class="panel panel-info">
	<div class="panel-heading">
		<strong>Viewing <?php