add admin timetable
This commit is contained in:
57
common/modules/event/views/event/_copy_week_search.php
Normal file
57
common/modules/event/views/event/_copy_week_search.php
Normal file
@@ -0,0 +1,57 @@
|
||||
<?php
|
||||
|
||||
use kartik\widgets\DatePicker;
|
||||
use kartik\widgets\DateTimePicker;
|
||||
use yii\helpers\Html;
|
||||
use yii\widgets\ActiveForm;
|
||||
|
||||
/* @var $this yii\web\View */
|
||||
/* @var $model backend\models\EventSearch */
|
||||
/* @var $form yii\widgets\ActiveForm */
|
||||
?>
|
||||
|
||||
<div class="event-search">
|
||||
|
||||
<?php $form = ActiveForm::begin([
|
||||
'action' => ['copy-week'],
|
||||
'method' => 'get',
|
||||
]); ?>
|
||||
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">Keresés</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="row">
|
||||
<div class="col-xs-3 col-sm-3 col-md-3 col-lg-3">
|
||||
<?= $form->field($model, 'sourceDateString')->widget(DatePicker::class, [
|
||||
'pluginOptions' => [
|
||||
'autoclose' => true,
|
||||
'format' => 'yyyy.mm.dd'
|
||||
],
|
||||
'options' => [
|
||||
'autocomplete' => 'off'
|
||||
]
|
||||
]) ?>
|
||||
</div>
|
||||
<div class="col-xs-3 col-sm-3 col-md-3 col-lg-3">
|
||||
<?= $form->field($model, 'targetDateString')->widget(DatePicker::class, [
|
||||
'pluginOptions' => [
|
||||
'autoclose' => true,
|
||||
'format' => 'yyyy.mm.dd'
|
||||
],
|
||||
'options' => [
|
||||
'autocomplete' => 'off'
|
||||
]
|
||||
]) ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel-footer">
|
||||
<?= Html::submitButton(Yii::t('event', 'Search'), ['class' => 'btn btn-primary']) ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php ActiveForm::end(); ?>
|
||||
|
||||
</div>
|
||||
46
common/modules/event/views/event/_timetable_search.php
Normal file
46
common/modules/event/views/event/_timetable_search.php
Normal file
@@ -0,0 +1,46 @@
|
||||
<?php
|
||||
|
||||
use kartik\widgets\DatePicker;
|
||||
use kartik\widgets\DateTimePicker;
|
||||
use yii\helpers\Html;
|
||||
use yii\widgets\ActiveForm;
|
||||
|
||||
/* @var $this yii\web\View */
|
||||
/* @var $model backend\models\EventSearch */
|
||||
/* @var $form yii\widgets\ActiveForm */
|
||||
?>
|
||||
|
||||
<div class="event-search">
|
||||
|
||||
<?php $form = ActiveForm::begin([
|
||||
'action' => ['timetable'],
|
||||
'method' => 'get',
|
||||
]); ?>
|
||||
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">Keresés</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="row">
|
||||
<div class="col-xs-3 col-sm-3 col-md-3 col-lg-3">
|
||||
<?= $form->field($model, 'startDateString')->widget(DatePicker::class, [
|
||||
'pluginOptions' => [
|
||||
'autoclose' => true,
|
||||
'format' => 'yyyy.mm.dd'
|
||||
],
|
||||
'options' => [
|
||||
'autocomplete' => 'off'
|
||||
]
|
||||
]) ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel-footer">
|
||||
<?= Html::submitButton(Yii::t('event', 'Search'), ['class' => 'btn btn-primary']) ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php ActiveForm::end(); ?>
|
||||
|
||||
</div>
|
||||
22
common/modules/event/views/event/copy_week.php
Normal file
22
common/modules/event/views/event/copy_week.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php use common\modules\event\models\copy\CopyWeekSearch;
|
||||
use common\modules\event\widgets\timetable\TimeTableMonthView;
|
||||
|
||||
/* @var $this yii\web\View */
|
||||
/* @var $tableHeaders string */
|
||||
/* @var $model CopyWeekSearch */
|
||||
|
||||
|
||||
use common\modules\event\models\timetable\TimeTableModel;
|
||||
use yii\grid\GridView as GridViewAlias; ?>
|
||||
<style>
|
||||
|
||||
</style>
|
||||
<h1>Hét másolása</h1>
|
||||
<?php
|
||||
|
||||
echo $this->render('_copy_week_search', ['model' => $model]);
|
||||
?>
|
||||
<h2>Forrás hét</h2>
|
||||
<?= TimeTableMonthView::widget(['timeTable' => $model->sourceTimeTable]) ?>
|
||||
<h2>Cél hét</h2>
|
||||
<?= TimeTableMonthView::widget(['timeTable' => $model->targetTimeTable]) ?>
|
||||
30
common/modules/event/views/event/timetable.php
Normal file
30
common/modules/event/views/event/timetable.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php use common\modules\event\models\timetable\TimeTableSearch;
|
||||
|
||||
/* @var $this yii\web\View */
|
||||
/* @var $tableHeaders string */
|
||||
/* @var $model TimeTableSearch */
|
||||
/* @var $tableModel TimeTableModel */
|
||||
|
||||
|
||||
$tableModel = $model->tableModel;
|
||||
$timeTable = $model->tableModel->timeTableMonth;
|
||||
|
||||
|
||||
use common\modules\event\models\timetable\TimeTableModel;
|
||||
use common\modules\event\widgets\timetable\TimeTableMonthView;
|
||||
|
||||
?>
|
||||
<style>
|
||||
|
||||
</style>
|
||||
|
||||
<h1>Órarend</h1>
|
||||
<?php echo $this->render('_timetable_search', ['model' => $model]); ?>
|
||||
|
||||
<h2>
|
||||
<?= $timeTable->interval->firstActiveDate->format("Y") ?>
|
||||
-
|
||||
<?= $timeTable->interval->firstActiveDate->format("m") ?>
|
||||
</h2>
|
||||
<?= TimeTableMonthView::widget(['timeTable' => $timeTable]) ?>
|
||||
|
||||
Reference in New Issue
Block a user