backend/group-training : improve delete© week
This commit is contained in:
@@ -1,33 +0,0 @@
|
||||
<?php /** @noinspection PhpUnhandledExceptionInspection */
|
||||
|
||||
use common\modules\event\models\copy\CopyWeekSearch;
|
||||
use yii\helpers\Html;
|
||||
use yii\widgets\ActiveForm;
|
||||
|
||||
/* @var $model CopyWeekSearch */
|
||||
|
||||
|
||||
?>
|
||||
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">Másolás</div>
|
||||
<div class="panel-body">
|
||||
|
||||
<?php $form = ActiveForm::begin(['options' =>['class' => 'form-inline' ]]); ?>
|
||||
<?= $form->field($model, 'sourceDateString')->hiddenInput()->label(false) ?>
|
||||
<?= $form->field($model, 'targetDateString')->hiddenInput()->label(false) ?>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="inpSourceEvent">Forrás hét: </label>
|
||||
|
||||
<input type="text" id="inpSourceEvent" disabled class="form-control" value="<?=$model->sourceTimeTable->getWeekByIndex(0)->getWeekString()?>">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="inpTargetEvent">Cél hét:</label>
|
||||
<input type="text" id="inpTargetEvent" disabled class="form-control" value="<?=$model->targetTimeTable->getWeekByIndex(0)->getWeekString()?>">
|
||||
</div>
|
||||
<?= Html::submitButton( 'Másol', ['class' => 'btn btn-success' ]) ?>
|
||||
|
||||
<?php ActiveForm::end(); ?>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1,7 +1,10 @@
|
||||
<?php /** @noinspection PhpUnhandledExceptionInspection */
|
||||
|
||||
use common\modules\event\models\copy\CopyWeekContext;
|
||||
use common\modules\event\models\copy\CopyWeekSearch;
|
||||
use common\modules\event\widgets\timetable\TimeTableMonthView;
|
||||
use yii\helpers\Html;
|
||||
use yii\widgets\ActiveForm;
|
||||
|
||||
/* @var $this yii\web\View */
|
||||
/* @var $tableHeaders string */
|
||||
@@ -12,11 +15,56 @@ use common\modules\event\widgets\timetable\TimeTableMonthView;
|
||||
<?php
|
||||
|
||||
echo $this->render('_copy_week_search', ['model' => $model]);
|
||||
echo $this->render('_copy_week_form', ['model' => $model]);
|
||||
|
||||
?>
|
||||
|
||||
|
||||
<?php $form = ActiveForm::begin(['options' =>['class' => 'form-inline' ]]); ?>
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">Másolás</div>
|
||||
<div class="panel-body">
|
||||
|
||||
<?= $form->field($model, 'sourceDateString')->hiddenInput()->label(false) ?>
|
||||
<?= $form->field($model, 'targetDateString')->hiddenInput()->label(false) ?>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="inpSourceEvent">Forrás hét: </label>
|
||||
|
||||
<input type="text" id="inpSourceEvent" disabled class="form-control" value="<?=$model->sourceTimeTable->getWeekByIndex(0)->getWeekString()?>">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="inpTargetEvent">Cél hét:</label>
|
||||
<input type="text" id="inpTargetEvent" disabled class="form-control" value="<?=$model->targetTimeTable->getWeekByIndex(0)->getWeekString()?>">
|
||||
</div>
|
||||
<?= Html::submitButton( 'Forrás hét másolása', ['class' => 'btn btn-success', 'value' => 'copy', 'name' => 'command' ]) ?>
|
||||
<?= Html::submitButton( 'Forrás hét törlése', ['class' => 'btn btn-danger', 'value' => 'delete', 'name' => 'command' ]) ?>
|
||||
<p>
|
||||
<small>
|
||||
Ha egy esemény sincsen kiválasztva, akkor a másolás/törlés, minden eseményt érinteni fog.
|
||||
(Nincs esemény kiválasztva = Minden esemény kiválasztva)
|
||||
</small>
|
||||
</p>
|
||||
<p>
|
||||
<small>Ha valamelyik esemény ki van választva, akkor a másolás/törlés, csak a kiválasztott esemény(eke)t fogja érinteni</small>
|
||||
</p>
|
||||
<p>
|
||||
<small><strong>Esemény törlése:</strong> a már regisztrált vendégek kártyájára visszakerül az alkalom</small>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h2>Forrás hét</h2>
|
||||
<?= TimeTableMonthView::widget(['timeTable' => $model->sourceTimeTable]) ?>
|
||||
<?= TimeTableMonthView::widget(
|
||||
[
|
||||
'timeTable' => $model->sourceTimeTable,
|
||||
'copyWeekContext' =>new CopyWeekContext(
|
||||
[
|
||||
'copyWeekForm' => $form,
|
||||
'copyWeekFormModel' => $model
|
||||
]
|
||||
)
|
||||
]
|
||||
) ?>
|
||||
<?php ActiveForm::end(); ?>
|
||||
<h2>Cél hét</h2>
|
||||
<?= TimeTableMonthView::widget(['timeTable' => $model->targetTimeTable]) ?>
|
||||
|
||||
Reference in New Issue
Block a user