50 lines
2.7 KiB
HTML
50 lines
2.7 KiB
HTML
|
{function sel_sem issave=0 sems='' save='' fo='' id_disc='' id_compet=''}
|
||
|
{*if count($save)}{assign var=sems value=$save}{/if*}
|
||
|
{if $issave==0}{assign var=sems value=$sems}{else}{assign var=sems value=$save}{/if}
|
||
|
{for $sem=1 to 12}
|
||
|
<input type="checkbox" class="form-check chk_{$id_disc}_{$id_compet}_{$fo}" id="chk_{$id_disc}_{$id_compet}_{$fo}_{$sem}" data-sem="{$sem}" style="display: inline;width: 20px;" {if in_array($sem,$sems)}CHECKED{/if}>
|
||
|
<!--label class="form-check-label" for="chk_{$id_disc}_{$id_compet}_{$fo}_{$sem}">{$sem}</label-->
|
||
|
{/for}
|
||
|
{/function}
|
||
|
{if count($comp.discs)}
|
||
|
<tr class="collapse_tds" id="tdsh_{$comp.id}">
|
||
|
<td style="padding: 0;"></td>
|
||
|
<td style="padding: 0;">
|
||
|
<div class="row">
|
||
|
<div class="col-md-2"></div>
|
||
|
<div class="col-md-10">
|
||
|
<div style="width: 6px;float: left;"> </div>
|
||
|
{for $sem=1 to 12}<div style="width: 20px;float: left;text-align: center;margin-right:4px;">{$sem}</div>{/for}
|
||
|
</div>
|
||
|
</div>
|
||
|
</td>
|
||
|
<td style="padding: 0;"></td>
|
||
|
</tr>
|
||
|
{/if}
|
||
|
{foreach from=$comp.discs item=disc key=k}
|
||
|
<tr class="collapse_tds" id="tds_{$comp.id}_{$k}">
|
||
|
<td>
|
||
|
<a href="#" class="btn btn-sm btn-danger btndeleCOMPSEM" data-trid="tds_{$comp.id}_{$k}" data-ucid="{$disc.ucid}" data-bs-toggle="tooltip" data-bs-placement="bottom" title="УДАЛЕНИЕ ДИСЦИПЛИНЫ!"><i class="bi bi-trash"></i></a>
|
||
|
<a href="#" class="btn btn-sm btn-warning btnsaveCOMPSEM" data-id_disc="{$disc.id}" data-id_compet="{$comp.id}" data-bs-toggle="tooltip" data-bs-placement="bottom" title="Сохранение семестров"><i class="bi bi-save"></i></a>
|
||
|
</td>
|
||
|
<td>
|
||
|
{assign var=issave value=0}{if count($disc.save)}{assign var=issave value=1}{/if}
|
||
|
<div class="row">
|
||
|
<div class="col-md-2">ОФО</div>
|
||
|
<div class="col-md-10">{sel_sem issave=$issave sems=$disc.sems save=$disc.save.ofo fo="ofo" id_disc=$disc.id id_compet=$comp.id}</div>
|
||
|
</div>
|
||
|
<div class="row">
|
||
|
<div class="col-md-2">ЗФО</div>
|
||
|
<div class="col-md-10">{sel_sem issave=$issave sems=$disc.sems1 save=$disc.save.zfo fo="zfo" id_disc=$disc.id id_compet=$comp.id}</div>
|
||
|
</div>
|
||
|
<div class="row">
|
||
|
<div class="col-md-2">ОЗФО</div>
|
||
|
<div class="col-md-10">{sel_sem issave=$issave sems=$disc.sems2 save=$disc.save.ofozfo fo="ofozfo" id_disc=$disc.id id_compet=$comp.id}</div>
|
||
|
</div>
|
||
|
</td>
|
||
|
<td>
|
||
|
{$disc.name}<br>
|
||
|
<span class="msgCS_{$disc.id}_{$comp.id}">{if count($disc.save)}есть сохранения семестров{else}<b class="text-danger">нет сохранения семестров</b>{/if}</span>
|
||
|
</td>
|
||
|
</tr>
|
||
|
{/foreach}
|