fetch_all(MYSQLI_ASSOC);
// Get services
$sql = "SELECT id, name, type, billing FROM services";
$stmt = mysqli_prepare($link, $sql);
mysqli_stmt_execute($stmt);
$result = mysqli_stmt_get_result($stmt);
$services = $result->fetch_all(MYSQLI_ASSOC);
// Get services
$sql = "SELECT id, service, name, client FROM orders";
$stmt = mysqli_prepare($link, $sql);
mysqli_stmt_execute($stmt);
$result = mysqli_stmt_get_result($stmt);
$orders = $result->fetch_all(MYSQLI_ASSOC);
function getservicebyid($id) {
global $services;
foreach ($services as $service) {
if ($service["id"] == $id) {
return $service;
}
}
}
function getclientbyid($id) {
global $users;
foreach ($users as $client) {
if ($client["id"] == $id) {
return $client;
}
}
}
?>
ARFNET CSTIMS
ARFNET Client Service Ticket and Invoice Management System
panel
Users
user | type | status |
".$user["username"]." | ".$user["type"]." | ".$user["status"]."\n";
}
?>
|
Service offerings
name | type | billing |
".$service["name"]." | ".$service["type"]." | ".$service["billing"]."\n";
}
?>
|
Orders
service | instance | client |
".getservicebyid($order["service"])["name"]." | ".$order["name"]." | ".getclientbyid($order["client"])["username"]."\n";
}
?>
|
Tickets
Invoices