<?php
$baseUrl = Yii::app()->theme->baseUrl;
$url = Yii::app()->baseUrl."/";
$cs = Yii::app()->getClientScript();
?>

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="description" content="">
    <meta name="author" content="">
    <link rel="shortcut icon" href="<?php echo $baseUrl; ?>/admin/assets/img/logo-fav.png">
    <title><?php echo $this->pageTitle; ?> - <?php echo Setting::model()->name(); ?></title>
    <link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>/admin/assets/lib/perfect-scrollbar/css/perfect-scrollbar.min.css"/>
    <link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>/admin/assets/lib/material-design-icons/css/material-design-iconic-font.min.css"/>
    <!--[if lt IE 9]>
    <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
    <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
<![endif]-->
<!-- <link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>/admin/assets/lib/datetimepicker/css/bootstrap-datetimepicker.min.css"/> -->
<!-- <link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>/admin/assets/lib/daterangepicker/css/daterangepicker.css"/> -->
<!-- <link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>/admin/assets/lib/select2/css/select2.min.css"/> -->
<!-- <link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>/admin/assets/lib/bootstrap-slider/css/bootstrap-slider.css"/> -->
<link rel="stylesheet" href="<?php echo $baseUrl; ?>/admin/assets/css/style.css" type="text/css"/>
<!-- <link rel="stylesheet" type="text/css" href="<?php echo $baseUrl; ?>/admin/assets/lib/jquery.gritter/css/jquery.gritter.css"/> -->

<link rel="stylesheet" href="https://cdn.datatables.net/1.10.22/css/jquery.dataTables.min.css">
<link rel="stylesheet" href="https://cdn.datatables.net/buttons/1.6.5/css/buttons.dataTables.min.css">

</head>
<body>
    <div class="be-wrapper">
        <nav class="navbar navbar-default navbar-fixed-top be-top-header">
            <div class="container-fluid" style="background-color: #4285f4;">
                <div class="navbar-header" style="background-color: #FFF;">
                    <!-- <a href="#" class="text-white be-toggle-left-sidebar"><span class="icon mdi mdi-menu"></span></a> -->
                    <a href="<?php echo YII::app()->baseUrl; ?>/main/paper/admin" class="navbar-brand"></a>
                </div>
                <div class="be-right-navbar">
                    <ul class="nav navbar-nav navbar-right be-user-nav">
                        <!-- <li><a href="#" class="be-toggle-left-sidebar"><span class="icon mdi mdi-dns"></span></a></li> -->
                        <li class="dropdown"><a href="#" data-toggle="dropdown" role="button" aria-expanded="false" class="dropdown-toggle"><img src="<?php echo $url; ?>image/favicon/avatar.png" alt="Avatar"><span class="user-name"><?php echo YII::app()->user->name; ?></span></a>
                            <ul role="menu" class="dropdown-menu">
                                <li>
                                    <div class="user-info">
                                        <div class="user-name"><?php echo Users::model()->showFullname(YII::app()->user->id); ?></div>
                                        <div class="user-position online"><?php echo Users::model()->level(YII::app()->user->record->level); ?></div>
                                    </div>
                                </li>

                                <li><a href="<?php echo $url; ?>profile"><span class="icon mdi mdi-face"></span> Edit Profil</a></li>
                                <li><a href="<?php echo $url; ?>password"><span class="icon mdi mdi-lock"></span> Ganti Password</a></li>
                                <!-- <li><a href="<?php echo $url; ?>image/<?php echo YII::app()->user->id; ?>"><span class="icon mdi mdi-image"></span> Image</a></li>  -->
                                <?php if(YII::app()->user->record->level==1): ?>
                                    <!--<li><a href="<?php echo $url; ?>setting/site"><span class="icon mdi mdi-settings"></span> Konfigurasi</a></li>-->
                                <?php endif; ?>
                                <li><a href="<?php echo $url; ?>site/logout"><span class="icon mdi mdi-power"></span> Logout</a></li>
                            </ul>
                        </li>
                    </ul>
                    <!-- <div class="page-title"><span><?php echo YII::app()->name; ?></span></div> -->


                </div>
            </div>
        </nav>

        <?php require_once('backend/tpl_sidebar.php'); ?>

        <div class="be-content">
         <div class="main-content container-fluid">
          <div class="row">
           <div class="col-sm-12">

            <?php echo $content; ?>

        </div>

    </div>
</div>
</div>
</div>



</div>

<?php Yii::app()->clientScript->registerCoreScript('jquery'); ?>
<script src="<?php echo $baseUrl; ?>/admin/assets/lib/perfect-scrollbar/js/perfect-scrollbar.jquery.min.js" type="text/javascript"></script>
<script src="<?php echo $baseUrl; ?>/admin/assets/js/main.js" type="text/javascript"></script>
<script src="<?php echo $baseUrl; ?>/admin/assets/lib/bootstrap/dist/js/bootstrap.min.js" type="text/javascript"></script>
<script src="<?php echo $baseUrl; ?>/admin/assets/lib/jquery-ui/jquery-ui.min.js" type="text/javascript"></script>
<!-- <script src="<?php echo $baseUrl; ?>/admin/assets/lib/jquery.nestable/jquery.nestable.js" type="text/javascript"></script> -->
<!-- <script src="<?php echo $baseUrl; ?>/admin/assets/lib/moment.js/min/moment.min.js" type="text/javascript"></script> -->
<!-- <script src="<?php echo $baseUrl; ?>/admin/assets/lib/datetimepicker/js/bootstrap-datetimepicker.min.js" type="text/javascript"></script> -->
<!-- <script src="<?php echo $baseUrl; ?>/admin/assets/lib/daterangepicker/js/daterangepicker.js" type="text/javascript"></script> -->
<!-- <script src="<?php echo $baseUrl; ?>/admin/assets/lib/select2/js/select2.min.js" type="text/javascript"></script> -->
<!-- <script src="<?php echo $baseUrl; ?>/admin/assets/lib/select2/js/select2.full.min.js" type="text/javascript"></script> -->
<!-- <script src="<?php echo $baseUrl; ?>/admin/assets/lib/bootstrap-slider/js/bootstrap-slider.js" type="text/javascript"></script> -->
<!-- <script src="<?php echo $baseUrl; ?>/admin/assets/lib/jquery.gritter/js/jquery.gritter.js" type="text/javascript"></script> -->

<script type="text/javascript">
    $(document).ready(function(){
        App.init();
        App.formElements();
        App.uiNotifications();
    });
</script>

<script src="https://code.jquery.com/jquery-3.5.1.js"></script>
<script src="https://cdn.datatables.net/1.10.22/js/jquery.dataTables.min.js"></script>
<script src="https://cdn.datatables.net/buttons/1.6.5/js/dataTables.buttons.min.js"></script>
<script src="https://cdn.datatables.net/buttons/1.6.5/js/buttons.flash.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.53/pdfmake.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.53/vfs_fonts.js"></script>
<script src="https://cdn.datatables.net/buttons/1.6.5/js/buttons.html5.min.js"></script>
<script src="https://cdn.datatables.net/buttons/1.6.5/js/buttons.print.min.js"></script>

<script type="text/javascript">
    $(document).ready(function() {
        $('#example').DataTable( {
            dom: 'Bfrtip',
            buttons: [
            'copy', 'csv', 'excel', 'pdf', 'print'
            ]
        } );
    } );
</script>


</body>
</html>