EIOS/integration/tpl/templates_c/3a2b07832d00a8c3043a0eb2680...

109 lines
4.7 KiB
PHP
Raw Permalink Normal View History

2023-12-28 15:39:22 +03:00
<?php
/* Smarty version 4.0.0-rc.0, created on 2023-09-19 11:25:55
from '/home/admin/web/eios.mkgtu.ru/public_html/rabprog/tpl/mod_header.html' */
/* @var Smarty_Internal_Template $_smarty_tpl */
if ($_smarty_tpl->_decodeProperties($_smarty_tpl, array (
'version' => '4.0.0-rc.0',
'unifunc' => 'content_65095b13147825_08391393',
'has_nocache_code' => false,
'file_dependency' =>
array (
'3a2b07832d00a8c3043a0eb2680b45c08c125cb6' =>
array (
0 => '/home/admin/web/eios.mkgtu.ru/public_html/rabprog/tpl/mod_header.html',
1 => 1695021117,
2 => 'file',
),
),
'includes' =>
array (
),
),false)) {
function content_65095b13147825_08391393 (Smarty_Internal_Template $_smarty_tpl) {
?><header class="navbar navbar-dark sticky-top bg-dark flex-md-nowrap p-0 shadow">
<a class="navbar-brand col-md-3 col-lg-2 me-0 px-3" href="#">Рабочие программы</a>
<button class="navbar-toggler position-absolute d-md-none collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#sidebarMenu" aria-controls="sidebarMenu" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="container-fluid">
<div class="row w-100">
<div class="col-md-4">
<input class="form-control form-control-dark w-100" type="text" placeholder="Добро пожаловать" aria-label="Search" id="search_input">
</div>
<div class="col-md-4">
<a href="#" class="btn <?php if ($_smarty_tpl->tpl_vars['year_cur']->value == 2022) {?>btn-success<?php } else { ?>btn-secondary<?php }?> year_chng" data-year="2022">2022</a>
<a href="#" class="btn <?php if ($_smarty_tpl->tpl_vars['year_cur']->value == 2023) {?>btn-success<?php } else { ?>btn-secondary<?php }?> year_chng" data-year="2023">2023</a>
</div>
<div class="col-md-4">
<?php if ((isset($_smarty_tpl->tpl_vars['PREPOD_ALL']->value))) {?>
<select class="form-control form-select prepod_chenge_ADM">
<?php
$_from = $_smarty_tpl->smarty->ext->_foreach->init($_smarty_tpl, $_smarty_tpl->tpl_vars['PREPOD_ALL']->value, 'prepod');
$_smarty_tpl->tpl_vars['prepod']->do_else = true;
if ($_from !== null) foreach ($_from as $_smarty_tpl->tpl_vars['prepod']->value) {
$_smarty_tpl->tpl_vars['prepod']->do_else = false;
?>
<?php if ($_smarty_tpl->tpl_vars['prepod']->value['fio'] != '') {?><option value="<?php echo $_smarty_tpl->tpl_vars['prepod']->value['id'];?>
" <?php if ($_smarty_tpl->tpl_vars['aUSER']->value['id'] == $_smarty_tpl->tpl_vars['prepod']->value['id']) {?>SELECTED<?php }?>><?php echo $_smarty_tpl->tpl_vars['prepod']->value['fio'];?>
</option><?php }?>
<?php
}
$_smarty_tpl->smarty->ext->_foreach->restore($_smarty_tpl, 1);?>
</select>
<?php echo '<script'; ?>
>$(document).ready(function(){
$(".prepod_chenge_ADM").change(function(){
let id = $('option:selected',this).val();
$.ajax({url: '/rabprog/index.php',cache:false,datatype:'json',method:'post',
data: 'prepod_chenge_ADM='+id,
success:function(data){
//window.location.reload();
window.location.href = 'https://eios.mkgtu.ru/rabprog/';
}
});
})
})<?php echo '</script'; ?>
>
<?php }?>
</div>
</div>
</div>
<div class="navbar-nav">
<div class="nav-item text-nowrap">
<a class="nav-link px-3" href="#">Помощь</a>
</div>
</div>
</header>
<?php echo '<script'; ?>
>$(document).ready(function(){
$(".year_chng").click(function(e){
let year = $(this).data('year');
$.ajax({url: '/rabprog/',cache:false,datatype:'json',method:'post',
data: 'year_change='+year,
success:function(data){
window.location.reload();
}
});
return false;
});
$("#search_input").keyup(function(e){
let word = $(this).val();
if(e.keyCode == 13){
$(this).trigger("enterKey");
window.ToastShow1("Поиск",'ищем...',0);
$("#main_body").html('ищем...');
$.ajax({url: '/rabprog/search/',cache:false,datatype:'json',method:'post',
data: 'ajdes=SEASRCH&word='+word,
success:function(data){
$("#main_body").html(data.html);
}
});
}
});
})<?php echo '</script'; ?>
><?php }
}