v1.2 initial commit
This commit is contained in:
68
pub/bin/pages/pageDashboard.php
Normal file
68
pub/bin/pages/pageDashboard.php
Normal file
@@ -0,0 +1,68 @@
|
||||
<?php
|
||||
if (!defined('APP_INIT')) {
|
||||
exit;
|
||||
}
|
||||
|
||||
# IDE Section
|
||||
|
||||
# Includes Section
|
||||
use api\classes\API;
|
||||
|
||||
require_once $_SERVER['DOCUMENT_ROOT'] . '/api/classes/API.php';
|
||||
$API = new API();
|
||||
|
||||
function showCard($module_name, $page_name, $width = 3)
|
||||
{
|
||||
$page = $GLOBALS['pages'][$module_name][$page_name];
|
||||
?>
|
||||
<div class="col">
|
||||
<a href="<?php echo $page['page_url'] ?>">
|
||||
<div class="card-pricing2 card-<?php echo $page['page_color'] ?> text-center h-100">
|
||||
<div class="pricing-header">
|
||||
<h3 class="fw-bold mb-3 text-center"><?php echo __($page['page_name']) ?></h3>
|
||||
</div>
|
||||
<div class="price-value">
|
||||
<div class="value ">
|
||||
<span class="amount"><i class="text-<?php echo $page['page_color'] ?> <?php echo $page['page_icon'] ?> mt-4"></i><span></span></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="mt-5">
|
||||
<small>
|
||||
<br>
|
||||
<?php echo __($page['page_description']) ?>
|
||||
</small>
|
||||
</div>
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
<div class="row row-cols-1 row-cols-md-3 row-cols-sm-2 g-3">
|
||||
<?php
|
||||
if ($GLOBALS['modules_enabled']['customers'] && $API->checkPermissions('customer-companies', 'RO', true)) {
|
||||
showCard('customers', 'companies', '6');
|
||||
}
|
||||
|
||||
if ($GLOBALS['modules_enabled']['servers'] && $API->checkPermissions('servers', 'RO', true)) {
|
||||
showCard('servers', 'server_overview', '6');
|
||||
}
|
||||
|
||||
if ($GLOBALS['modules_enabled']['office'] && $API->checkPermissions('ofice-stompjes', 'RO', true)) {
|
||||
showCard('office', 'stompjeslist');
|
||||
}
|
||||
|
||||
if ($GLOBALS['modules_enabled']['autop']) {
|
||||
showCard('autop', 'platforms');
|
||||
showCard('autop', 'vendors');
|
||||
showCard('autop', 'devices');
|
||||
showCard('autop', 'device_settings');
|
||||
showCard('autop', 'provisioning');
|
||||
showCard('autop', 'phonebooks');
|
||||
}
|
||||
|
||||
if ($GLOBALS['modules_enabled']['system']) {
|
||||
showCard('system', 'access_control');
|
||||
showCard('system', 'systemconfig');
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
Reference in New Issue
Block a user