2023-05-27 20:53:50 +00:00
|
|
|
<?php
|
|
|
|
$root = $_SERVER['DOCUMENT_ROOT'];
|
|
|
|
require "$root/Libraries/table/class.php";
|
|
|
|
use table\Table;
|
|
|
|
$db = new SQLite3("../webcron.db");
|
|
|
|
?>
|
2023-05-13 18:21:52 +00:00
|
|
|
<!Doctype html>
|
|
|
|
<html>
|
|
|
|
<head>
|
|
|
|
<!-- <script src="https://cdn.tailwindcss.com"></script> -->
|
|
|
|
<link rel="stylesheet" href="css/main.css">
|
|
|
|
<script src="main.js"> </script>
|
|
|
|
<title><?php
|
|
|
|
$filename = ucfirst(explode('.',basename($_SERVER['SCRIPT_FILENAME']))[0]);
|
|
|
|
echo $filename;
|
|
|
|
?> Management</title>
|
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<nav>
|
|
|
|
<a class='nav-button' href='index.php'>Log Management</a>
|
|
|
|
<?php
|
2023-05-27 21:42:12 +00:00
|
|
|
$items = scandir($root);
|
2023-05-13 18:21:52 +00:00
|
|
|
foreach ($items as $item){
|
|
|
|
if (preg_match('/\.php$/', $item) && $item != "index.php"){
|
|
|
|
$item_name=ucfirst(explode('.', $item)[0]);
|
|
|
|
echo "<a class='nav-button' href='$item'>$item_name Management</a>";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
</nav>
|
|
|
|
|
|
|
|
<div class="content_area bordered rounded_border">
|
|
|
|
|
2023-05-27 21:42:12 +00:00
|
|
|
<div class="single_width menu_bar bordered_right cell border_rounded_left">
|
2023-05-13 18:21:52 +00:00
|
|
|
<button class="menu_button" onclick="setCrontabStats()"> View Crontab Statistics </button>
|
2023-05-13 18:28:00 +00:00
|
|
|
<button class="menu_button" onclick="getTable('job_history')">View Script Run History</button>
|
2023-05-21 19:14:28 +00:00
|
|
|
<button class="menu_button" onclick="listCrontabs()">View Crontabs</button>
|
2023-05-15 21:45:18 +00:00
|
|
|
<button class="menu_button" onclick="test()">Test</button>
|
2023-05-13 18:21:52 +00:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<div id="content" class="content cell">
|
|
|
|
</div>
|
|
|
|
|
2023-05-27 21:42:12 +00:00
|
|
|
<div class="double_width menu_bar bordered_left cell border_rounded_right">
|
2023-05-27 20:53:50 +00:00
|
|
|
<?php
|
|
|
|
$columns = array(
|
|
|
|
'crontab_path AS "Crontab Path"',
|
|
|
|
'crontab_created_timestamp AS "Created At"',
|
|
|
|
'crontab_modified_timestamp AS "Last Modified At"'
|
|
|
|
);
|
|
|
|
$table = new Table("crontabs");
|
|
|
|
$table->set_pretty_name("Crontabs");
|
|
|
|
$query = $table->get_query();
|
|
|
|
$query->set_columns($columns);
|
|
|
|
$table->Load($db);
|
|
|
|
echo $table->get_html();
|
|
|
|
?>
|
2023-05-13 18:21:52 +00:00
|
|
|
|
|
|
|
</div>
|
2023-05-27 20:53:50 +00:00
|
|
|
</div>
|
2023-05-13 18:21:52 +00:00
|
|
|
|
|
|
|
</body>
|
|
|
|
</html>
|