149 lines
5.5 KiB
PHTML
149 lines
5.5 KiB
PHTML
<!DOCTYPE html>
|
|
<?php
|
|
/**
|
|
* @var \League\Plates\Template\Template $this
|
|
* @var \App\Auth $auth
|
|
* @var \AzuraCast\Acl\StationAcl $acl
|
|
* @var \App\Url $url
|
|
* @var \App\Flash $flash
|
|
* @var \AzuraCast\Customization $customization
|
|
* @var \AzuraCast\Assets $assets
|
|
* @var array $app_settings
|
|
*/
|
|
?>
|
|
<html>
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
|
|
<?php
|
|
if ($title)
|
|
$page_title = $title.' - '.$app_settings['name'];
|
|
else
|
|
$page_title = $app_settings['name'];
|
|
|
|
if (!APP_IN_PRODUCTION)
|
|
$page_title = '('.ucfirst(APP_APPLICATION_ENV).') '.$page_title;
|
|
?>
|
|
<title><?=$page_title ?></title>
|
|
|
|
<?=$this->fetch('partials/icons') ?>
|
|
|
|
<?php
|
|
$assets
|
|
->load('main_header')
|
|
->load('main_body')
|
|
->load('theme_'.$customization->getTheme());
|
|
?>
|
|
|
|
<?=$assets->css('header') ?>
|
|
<?=$assets->css('body') ?>
|
|
<?=$assets->js('header') ?>
|
|
|
|
<style type="text/css">
|
|
<?=$customization->getCustomInternalCss() ?>
|
|
</style>
|
|
<script type="text/javascript" nonce="<?=$assets->getCspNonce() ?>">
|
|
var APP_AppEnv = '<?=APP_APPLICATION_ENV ?>';
|
|
var APP_BaseUrl = '<?=$url->named('home') ?>';
|
|
var APP_ContentPath = '<?=$url->content('') ?>';
|
|
</script>
|
|
</head>
|
|
<body class="<?=$page_class ?>">
|
|
<a class="sr-only" href="#content"><?=__('Skip to main content') ?></a>
|
|
|
|
<header id="header" class="clearfix" data-ma-theme="blue" style="background-image: url('<?=$url->content('img/header_bg.png') ?>');" data-rjs="3">
|
|
<ul class="h-inner">
|
|
<?php if (!empty($sidebar)): ?>
|
|
<li class="hi-trigger ma-trigger" data-ma-action="sidebar-open" data-ma-target="#sidebar">
|
|
<div class="line-wrap">
|
|
<div class="line top"></div>
|
|
<div class="line center"></div>
|
|
<div class="line bottom"></div>
|
|
</div>
|
|
</li>
|
|
<?php endif; ?>
|
|
|
|
<li class="logo">
|
|
<a href="<?=$url->named('dashboard') ?>">
|
|
azura<strong>cast</strong> <?php if (!empty($customization->getInstanceName())): ?><small><?=$this->e($customization->getInstanceName()) ?></small><?php endif; ?>
|
|
</a>
|
|
</li>
|
|
|
|
<li class="pull-right">
|
|
<ul class="hi-menu" role="toolbar">
|
|
<?=$this->fetch('partials/radio_controls') ?>
|
|
|
|
<li class="dropdown">
|
|
<a data-toggle="dropdown" href="" aria-label="menu" title="<?=__('Open or Close Dropdown Menu') ?>"><i class="him-icon zmdi zmdi-more-vert"></i></a>
|
|
<ul class="dropdown-menu dm-icon pull-right">
|
|
<li><a href="<?=$url->named('dashboard') ?>"><i class="zmdi zmdi-home"></i> <?=__('Dashboard') ?></a></li>
|
|
<?php if ($acl->userAllowed($user, 'view administration')): ?>
|
|
<li><a href="<?=$url->named('admin:index:index') ?>"><i class="zmdi zmdi-settings"></i> <?=__('System Administration') ?></a></li>
|
|
<?php endif; ?>
|
|
<li><a href="<?=$url->named('profile:index') ?>"><i class="zmdi zmdi-account"></i> <?=__('My Account') ?></a></li>
|
|
<li><a href="<?=$url->named('api_keys:index') ?>"><i class="zmdi zmdi-key"></i> <?=__('My API Keys') ?></a></li>
|
|
<li class="divider"> </li>
|
|
<?php if ($auth->isMasqueraded()): ?>
|
|
<li><a href="<?=$url->named('account:endmasquerade') ?>"><i class="zmdi zmdi-power"></i> <?=__('End Session') ?></a></li>
|
|
<?php else: ?>
|
|
<li><a href="<?=$url->named('account:logout') ?>"><i class="zmdi zmdi-power"></i> <?=__('Sign Out') ?></a></li>
|
|
<?php endif; ?>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</header>
|
|
|
|
<section id="main">
|
|
<?php if (!empty($sidebar)): ?>
|
|
<nav id="sidebar" class="sidebar c-overflow" role="navigation">
|
|
<?=$sidebar ?>
|
|
</nav>
|
|
<?php endif; ?>
|
|
|
|
<section id="content" <?php if (empty($sidebar)): ?>class="content-alt"<?php endif; ?> role="main">
|
|
<div class="container">
|
|
<?php if ($manual): ?>
|
|
<?=$this->section('content') ?>
|
|
<?php else: ?>
|
|
<?php if ($header): ?>
|
|
<div class="block-header">
|
|
<h2><?=$header ?></h2>
|
|
</div>
|
|
<?php endif; ?>
|
|
<div class="card">
|
|
<div class="card-header ch-alt">
|
|
<h2><?=$title ?></h2>
|
|
</div>
|
|
<div class="card-body card-padding">
|
|
<?=$this->section('content') ?>
|
|
</div>
|
|
</div>
|
|
<?php endif; ?>
|
|
</div>
|
|
</section>
|
|
</section>
|
|
|
|
<footer id="footer" <?php if (empty($sidebar)): ?>class="footer-alt"<?php endif; ?> role="contentinfo">
|
|
<?=sprintf(__('Powered by %s'), '<a href="https://azuracast.com/" target="_blank">'.$app_settings['name'].'</a>'.' '.\AzuraCast\Version::getVersionText().' '.(APP_INSIDE_DOCKER ? '(Docker)' : '(Traditional)')) ?><br>
|
|
PHP <?=\PHP_VERSION ?>, SlimPHP 3
|
|
</footer>
|
|
|
|
<div id="radio-player"></div>
|
|
|
|
<?=$assets->js('body') ?>
|
|
|
|
<?php if ($flash->hasMessages()): ?>
|
|
<script type="text/javascript" nonce="<?=$assets->getCspNonce() ?>">
|
|
$(function() {
|
|
<?php foreach($flash->getMessages() as $message): ?>
|
|
notify("<?=str_replace(array('"', "\n"), array('\'', '<br>'), $message['text']) ?>", '<?=$message['color'] ?>', false);
|
|
<?php endforeach; ?>
|
|
});
|
|
</script>
|
|
<?php endif; ?>
|
|
</body>
|
|
</html>
|