EIOS/inc/smarty/templates_c/ce8646292e56b260bfb19bee08a...

323 lines
19 KiB
PHP
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?php /* Smarty version Smarty-3.1.13, created on 2022-06-03 16:19:47
compiled from "tpl/tpl_rejt_admin2.html" */ ?>
<?php /*%%SmartyHeaderCode:446698786629a0a73867656-72563789%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
$_valid = $_smarty_tpl->decodeProperties(array (
'file_dependency' =>
array (
'ce8646292e56b260bfb19bee08a7e643e1b2814e' =>
array (
0 => 'tpl/tpl_rejt_admin2.html',
1 => 1552924755,
2 => 'file',
),
),
'nocache_hash' => '446698786629a0a73867656-72563789',
'function' =>
array (
),
'variables' =>
array (
'des' => 0,
'item' => 0,
'itemspolyas' => 0,
'it' => 0,
'razdels' => 0,
'ipis' => 0,
'polyas' => 0,
'it0' => 0,
'items' => 0,
),
'has_nocache_code' => false,
'version' => 'Smarty-3.1.13',
'unifunc' => 'content_629a0a738d7732_20390896',
),false); /*/%%SmartyHeaderCode%%*/?>
<?php if ($_valid && !is_callable('content_629a0a738d7732_20390896')) {function content_629a0a738d7732_20390896($_smarty_tpl) {?><div id="page-wrap">
<div class="row-fluid">
<div class="span12">
<?php if ($_smarty_tpl->tpl_vars['des']->value=="formula"){?>
<div class="widget blue">
<div class="widget-title">
<h4><i class="icon-reorder"></i>Редактирование формулы</h4>
<span class="tools"><a href="javascript:;" class="icon-chevron-down"></a></span>
</div>
<div class="widget-body">
<form action="" class="form-horizontal" method="POST" enctype="multipart/form-data">
<h2><?php echo $_smarty_tpl->tpl_vars['item']->value['name'];?>
</h2>
<h2>Заполняемые пользователем поля <span style="font-size:13px;color:gray;">могут участвовать в формуле</span></h2>
<?php $_smarty_tpl->tpl_vars['it'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['it']->_loop = false;
$_from = $_smarty_tpl->tpl_vars['itemspolyas']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['it']->key => $_smarty_tpl->tpl_vars['it']->value){
$_smarty_tpl->tpl_vars['it']->_loop = true;
?>
<a class="btn btn-info tooltips fadd" id="ip_<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
" href="#" data-placement="top" data-original-title="ip_<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
<?php if ($_smarty_tpl->tpl_vars['it']->value['polyas']!=0){?>У поля есть значение БАЛЛ<?php }?>"><?php echo $_smarty_tpl->tpl_vars['it']->value['name'];?>
<?php if ($_smarty_tpl->tpl_vars['it']->value['polyas']!=0){?><span class="badge badge-important"><?php echo $_smarty_tpl->tpl_vars['it']->value['polyas'];?>
</span><?php }?></a>
<?php } ?>
<hr>
<div class="control-group">
<label class="control-label span2">ФОРМУЛА</label>
<div class="controls span6">
<input type="text" class="span12 tooltips formula" data-trigger="hover" data-original-title="Формула" name="formula" value="<?php echo $_smarty_tpl->tpl_vars['item']->value['formuls'];?>
" /><br>
<a class="btn btn-warning tooltips fadd" id="ЕСЛИ[усл#истина#ложь]" href="#" data-placement="top" data-original-title="Вставка условия">ЕСЛИ</a>
<a class="btn btn-warning tooltips fadd" id="ИЛИ(усл1;усл2;усл3)" href="#" data-placement="top" data-original-title="Вставка в условие ИЛИ">ИЛИ</a>
<a class="btn btn-warning tooltips fadd" id="И(усл1;усл2;усл3)" href="#" data-placement="top" data-original-title="Вставка в условие И">И</a>
<a class="btn btn-warning tooltips fadd" id="=" href="#" data-placement="top" data-original-title="Равно">=</a>
<a class="btn btn-warning tooltips fadd" id="<>" href="#" data-placement="top" data-original-title="не равно"><></a>
<a class="btn btn-warning tooltips fadd" id="<" href="#" data-placement="top" data-original-title="меньше"><</a>
<a class="btn btn-warning tooltips fadd" id=">" href="#" data-placement="top" data-original-title="больше">></a>
<a class="btn btn-warning tooltips fadd" id=">=" href="#" data-placement="top" data-original-title="больше или равно">>=</a>
<a class="btn btn-warning tooltips fadd" id="<=" href="#" data-placement="top" data-original-title="меньше или равно"><=</a>
<a class="btn btn-warning tooltips fadd" id="+" href="#" data-placement="top" data-original-title="сложить">+</a>
<a class="btn btn-warning tooltips fadd" id="-" href="#" data-placement="top" data-original-title="вычесть">-</a>
<a class="btn btn-warning tooltips fadd" id="*" href="#" data-placement="top" data-original-title="умножить">*</a>
<a class="btn btn-warning tooltips fadd" id="/" href="#" data-placement="top" data-original-title="делить">/</a>
</div>
<label class="control-label span4">
<span style="color:gray;">[ip_1]</span><span style="color:blue;">*</span><span style="color:red;">ЕСЛИ</span><b>[</b><span style="color:red;">И</span><b>(</b><span style="color:gray;">[ip_2]</span><span style="color:blue;">=</span>оч<span style="color:red;">;</span><span style="color:gray;">[ip_3]</span><span style="color:blue;"><></span>50<b>)</b><span style="color:red;">#</span>2<span style="color:blue;">*</span><span style="color:gray;">[ip_4]</span><span style="color:red;">#</span>0<b>]</b><br><span style="color:gray;">[ip_1]</span>=5;<span style="color:gray;">[ip_2]</span>=оч;<span style="color:gray;">[ip_3]</span>=49;<span style="color:gray;">[ip_4]</span>=4; Результат: 40<br><span style="color:gray;">[ip_1]</span>=8;<span style="color:gray;">[ip_2]</span>=оч;<span style="color:gray;">[ip_3]</span>=50;<span style="color:gray;">[ip_4]</span>=2; Результат: 0
</label>
</div>
<div class="form-actions">
<button type="submit" name="admin2f_save" class="btn btn-success">Редактировать</button>
<input type="HIDDEN" name="id" value="<?php echo $_smarty_tpl->tpl_vars['item']->value['id'];?>
">
</div>
</form>
</div>
</div>
<script>$(document).ready(function(){
$(".fadd").click(function(){
var id=$(this).attr("id");
var text = $(".formula").val();
$(".formula").val(text + " " + id);
return false;
});
});</script>
<?php }?>
<?php if ($_smarty_tpl->tpl_vars['des']->value=="edit"||$_smarty_tpl->tpl_vars['des']->value=="add"){?>
<div class="widget blue">
<div class="widget-title">
<h4><i class="icon-reorder"></i><?php if ($_smarty_tpl->tpl_vars['des']->value=="edit"){?>Редактирование<?php }else{ ?>Добавление<?php }?></h4>
<span class="tools"><a href="javascript:;" class="icon-chevron-down"></a></span>
</div>
<div class="widget-body">
<form action="" class="form-horizontal" method="POST" enctype="multipart/form-data">
<div class="control-group">
<label class="control-label span2">Родительская категория</label>
<div class="controls span10">
<select data-placeholder="Родительская категория" class="span12" tabindex="1" name="id_razdel">
<option value="0">Корневая-без родителя</option>
<?php $_smarty_tpl->tpl_vars['it'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['it']->_loop = false;
$_from = $_smarty_tpl->tpl_vars['razdels']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['it']->key => $_smarty_tpl->tpl_vars['it']->value){
$_smarty_tpl->tpl_vars['it']->_loop = true;
?>
<option value="<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
"<?php if ($_smarty_tpl->tpl_vars['it']->value['id']==$_smarty_tpl->tpl_vars['item']->value['id_razdel']){?> SELECTED<?php }?>><?php echo $_smarty_tpl->tpl_vars['it']->value['name'];?>
</option>
<?php } ?>
</select>
</div>
</div>
<div class="control-group">
<label class="control-label span2">Название раздела</label>
<div class="controls span10">
<input type="text" class="span12 tooltips" data-trigger="hover" data-original-title="Название раздела" name="name" value="<?php echo $_smarty_tpl->tpl_vars['item']->value['name'];?>
" />
</div>
</div>
<div class="control-group">
<label class="control-label span2">Описание раздела</label>
<div class="controls span10">
<textarea class="span12 tooltips" data-trigger="hover" data-original-title="Описание раздела" name="descr"><?php echo $_smarty_tpl->tpl_vars['item']->value['descr'];?>
</textarea>
</div>
</div>
<div class="control-group">
<label class="control-label span2">Позиция</label>
<div class="controls span2">
<input type="text" class="span12 tooltips" data-trigger="hover" data-original-title="Номер позиции в списке" name="pos" value="<?php echo $_smarty_tpl->tpl_vars['item']->value['pos'];?>
" />
</div>
<label class="control-label span2">Тип</label>
<div class="controls span2">
<select data-placeholder="Дублируемая позиция или нет" class="span12" tabindex="1" name="tip">
<option value="1"<?php if ($_smarty_tpl->tpl_vars['item']->value['tip']==1){?> SELECTED<?php }?>>Дублируется</option>
<option value="0"<?php if ($_smarty_tpl->tpl_vars['item']->value['tip']==0){?> SELECTED<?php }?>>Не дублируется</option>
</select>
</div>
<label class="control-label span2">Статус</label>
<div class="controls span2">
<select data-placeholder="Статус, отображается на сайте или нет" class="span12" tabindex="1" name="status">
<option value="1"<?php if ($_smarty_tpl->tpl_vars['item']->value['status']==1){?> SELECTED<?php }?>>Доступен всем</option>
<option value="0"<?php if ($_smarty_tpl->tpl_vars['item']->value['status']==0){?> SELECTED<?php }?>>Черновик</option>
</select>
</div>
</div>
<hr>
<h2>Добавление заполняемых полей в раздел <span style="font-size:13px;color:gray;">эти поля заполняет пользователь</span></h2>
<div class="control-group">
<label class="control-label span6">Название поля</label>
<label class="control-label span2">Позиция</label>
<label class="control-label span2">Тип поля <span style="font-size:13px;color:gray;">или пусто или file</span></label>
<label class="control-label span2">Удалить</label>
</div>
<?php $_smarty_tpl->tpl_vars['it'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['it']->_loop = false;
$_from = $_smarty_tpl->tpl_vars['itemspolyas']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['it']->key => $_smarty_tpl->tpl_vars['it']->value){
$_smarty_tpl->tpl_vars['it']->_loop = true;
?>
<div class="control-group">
<div class="controls span6">
<input type="text" class="span12 tooltips" data-trigger="hover" data-original-title="Название поля" name="itemspolya[<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
][name]" value="<?php echo $_smarty_tpl->tpl_vars['it']->value['name'];?>
" />
</div>
<div class="controls span2">
<input type="text" class="span12 tooltips" data-trigger="hover" data-original-title="Номер позиции в списке" name="itemspolya[<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
][pos]" value="<?php echo $_smarty_tpl->tpl_vars['it']->value['pos'];?>
" />
</div>
<div class="controls span2">
<input type="text" class="span12 tooltips" data-trigger="hover" data-original-title="Если поле пустое - тогда пользователь пишет в поле свои значения, если написать file то пользователь сможет загрузить файл" name="itemspolya[<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
][value]" value="<?php echo $_smarty_tpl->tpl_vars['it']->value['value'];?>
" />
</div>
<div class="controls span2">
<?php if ($_smarty_tpl->tpl_vars['it']->value['id']>0){?>
<input type="CHECKBOX" class="span12 tooltips" data-trigger="hover" data-original-title="Удалить" name="itemspolya[<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
][del]" value="1" />
<?php }?>
</div>
</div>
<?php } ?>
<hr>
<h2>Добавление выбираемых полей в раздел <span style="font-size:13px;color:gray;">для одиночного поля укажите "название поля" равное "балл"</span></h2>
<?php if ($_smarty_tpl->tpl_vars['ipis']->value>0){?>
<table class="table table-bordered table-advance">
<thead>
<tr>
<th>Заполняемое поле</th>
<th>Название поля</th>
<th>Позиция</th>
<th>Значение</th>
<th>Удалить</th>
</tr>
</thead>
<tbody>
<?php $_smarty_tpl->tpl_vars['it'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['it']->_loop = false;
$_from = $_smarty_tpl->tpl_vars['polyas']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['it']->key => $_smarty_tpl->tpl_vars['it']->value){
$_smarty_tpl->tpl_vars['it']->_loop = true;
?>
<tr>
<td><select name="polyas[<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
][id_item]" class="span12"><?php $_smarty_tpl->tpl_vars['it0'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['it0']->_loop = false;
$_from = $_smarty_tpl->tpl_vars['itemspolyas']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['it0']->key => $_smarty_tpl->tpl_vars['it0']->value){
$_smarty_tpl->tpl_vars['it0']->_loop = true;
?><option value="<?php echo $_smarty_tpl->tpl_vars['it0']->value['id'];?>
"<?php if ($_smarty_tpl->tpl_vars['it']->value['id_item']==$_smarty_tpl->tpl_vars['it0']->value['id']){?> SELECTED<?php }?>><?php echo $_smarty_tpl->tpl_vars['it0']->value['name'];?>
</option><?php } ?></select></td>
<td><input type="text" class="span12 tooltips" data-trigger="hover" data-original-title="Название поля" name="polyas[<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
][name]" value="<?php echo $_smarty_tpl->tpl_vars['it']->value['name'];?>
" /></td>
<td><input type="text" class="span12 tooltips" data-trigger="hover" data-original-title="Номер позиции в списке" name="polyas[<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
][pos]" value="<?php echo $_smarty_tpl->tpl_vars['it']->value['pos'];?>
" /></td>
<td><input type="text" class="span12 tooltips" data-trigger="hover" data-original-title="Значение" name="polyas[<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
][value]" value="<?php echo $_smarty_tpl->tpl_vars['it']->value['value'];?>
" /></td>
<td><?php if ($_smarty_tpl->tpl_vars['it']->value['id']>0){?>
<input type="CHECKBOX" class="span12 tooltips" data-trigger="hover" data-original-title="Удалить" name="polyas[<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
][del]" value="1" />
<?php }?></td>
</tr>
<?php } ?>
</tbody>
</table>
<?php }else{ ?>
<p>Добавьте заполняемые поля в раздел!</p>
<?php }?>
<div class="form-actions">
<?php if ($_smarty_tpl->tpl_vars['des']->value=="add"){?>
<button type="submit" name="admin2_save" class="btn btn-warning">Добавить</button>
<?php }?>
<?php if ($_smarty_tpl->tpl_vars['des']->value=="edit"){?>
<button type="submit" name="admin2_edit" class="btn btn-success">Редактировать</button>
<input type="HIDDEN" name="id" value="<?php echo $_smarty_tpl->tpl_vars['item']->value['id'];?>
">
<?php }?>
</div>
</form>
</div>
</div>
<?php }?>
<?php if ($_smarty_tpl->tpl_vars['des']->value=="show"){?>
<div class="widget blue">
<div class="widget-title">
<h4><i class="icon-reorder"></i>Админ подразделы</h4>
<span class="tools"><a href="javascript:;" class="icon-chevron-down"></a></span>
</div>
<div class="widget-body">
<table class="table table-striped table-bordered table-advance table-hover">
<thead>
<tr>
<th>№</th>
<th>Категория</th>
<th>Название раздела</th>
<th>Тип</th>
<th>Формула</th>
<th><a class="btn btn-warning tooltips" data-trigger="hover" data-original-title="Добавить позицию" href="/rejt/admin2/add/"><i class="icon-plus"></i></a></th>
</tr>
</thead>
<tbody>
<?php $_smarty_tpl->tpl_vars['it'] = new Smarty_Variable; $_smarty_tpl->tpl_vars['it']->_loop = false;
$_from = $_smarty_tpl->tpl_vars['items']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array');}
foreach ($_from as $_smarty_tpl->tpl_vars['it']->key => $_smarty_tpl->tpl_vars['it']->value){
$_smarty_tpl->tpl_vars['it']->_loop = true;
?>
<tr>
<td><?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
</td>
<td><?php echo $_smarty_tpl->tpl_vars['it']->value['razdel'][0]['name'];?>
</td>
<td><?php echo $_smarty_tpl->tpl_vars['it']->value['name'];?>
</td>
<td><?php echo $_smarty_tpl->tpl_vars['it']->value['tip'];?>
</td>
<td>
<?php if ($_smarty_tpl->tpl_vars['it']->value['formuls']!=''){?>
<a class="btn btn-danger tooltips" data-trigger="hover" data-original-title="<?php echo $_smarty_tpl->tpl_vars['it']->value['formuls'];?>
" href="/rejt/admin2/formula/<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
/"><i class="icon-superscript"></i></a>
<?php }else{ ?>
<a class="btn btn-default tooltips" data-trigger="hover" data-original-title="Редактировать формулу" href="/rejt/admin2/formula/<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
/"><i class="icon-superscript"></i></a>
<?php }?>
</td>
<td nowrap>
<a class="btn btn-info tooltips" href="#" data-placement="top" data-original-title="Значений всего"><?php echo $_smarty_tpl->tpl_vars['it']->value['ipolej'];?>
</a>
<a class="btn btn-danger tooltips" data-trigger="hover" data-original-title="Удалить позицию" href="/rejt/admin2/dele/<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
/"><i class="icon-trash"></i></a>
<a class="btn btn-success tooltips" data-trigger="hover" data-original-title="Редактировать позицию" href="/rejt/admin2/edit/<?php echo $_smarty_tpl->tpl_vars['it']->value['id'];?>
/"><i class="icon-pencil"></i></a>
</td>
</tr>
<?php } ?>
</tbody>
</table>
</div>
</div>
<?php }?>
</div>
</div>
</div><?php }} ?>