add collections to backend
This commit is contained in:
@@ -2,12 +2,22 @@
|
||||
|
||||
use yii\helpers\Html;
|
||||
use yii\widgets\ActiveForm;
|
||||
use frontend\components\HtmlHelper;
|
||||
use kartik\widgets\DateTimePicker;
|
||||
use yii\helpers\ArrayHelper;
|
||||
|
||||
/* @var $this yii\web\View */
|
||||
/* @var $model backend\models\CollectionSearch */
|
||||
/* @var $form yii\widgets\ActiveForm */
|
||||
?>
|
||||
|
||||
<?php
|
||||
|
||||
$accountOptions = ['' =>Yii::t('frontend/collection','All')]+ HtmlHelper::mkAccountOptions($model->accounts);
|
||||
$userOptions = ['' =>Yii::t('frontend/collection','All')]+ ArrayHelper::map($model->users,'id','username');
|
||||
|
||||
?>
|
||||
|
||||
<div class="collection-search">
|
||||
|
||||
<?php $form = ActiveForm::begin([
|
||||
@@ -15,29 +25,35 @@ use yii\widgets\ActiveForm;
|
||||
'method' => 'get',
|
||||
]); ?>
|
||||
|
||||
<?= $form->field($model, 'id_collection') ?>
|
||||
|
||||
<?= $form->field($model, 'id_user') ?>
|
||||
|
||||
<?= $form->field($model, 'created_by') ?>
|
||||
|
||||
<?= $form->field($model, 'id_account') ?>
|
||||
|
||||
<?= $form->field($model, 'money') ?>
|
||||
|
||||
<?php // echo $form->field($model, 'start') ?>
|
||||
|
||||
<?php // echo $form->field($model, 'end') ?>
|
||||
|
||||
<?php // echo $form->field($model, 'type') ?>
|
||||
|
||||
<?php // echo $form->field($model, 'created_at') ?>
|
||||
|
||||
<?php // echo $form->field($model, 'updated_at') ?>
|
||||
<div class='row'>
|
||||
<div class='col-md-3'>
|
||||
<?= $form->field($model, 'id_account')->dropDownList( $accountOptions ) ?>
|
||||
</div>
|
||||
<div class='col-md-3'>
|
||||
<?= $form->field($model, 'id_user')->dropDownList( $userOptions ) ?>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<?= $form->field($model, 'start')->widget(DateTimePicker::classname(), [
|
||||
'pluginOptions' => [
|
||||
'autoclose'=>true,
|
||||
'format' => 'yyyy.mm.dd hh:ii'
|
||||
]
|
||||
]) ?>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<?= $form->field($model, 'end') ->widget(DateTimePicker::classname(), [
|
||||
'pluginOptions' => [
|
||||
'autoclose'=>true,
|
||||
'format' => 'yyyy.mm.dd hh:ii'
|
||||
]
|
||||
]) ?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<?= Html::submitButton(Yii::t('backend/collection', 'Search'), ['class' => 'btn btn-primary']) ?>
|
||||
<?= Html::resetButton(Yii::t('backend/collection', 'Reset'), ['class' => 'btn btn-default']) ?>
|
||||
<?= Html::submitButton(Yii::t('frontend/collection', 'Search'), ['class' => 'btn btn-primary']) ?>
|
||||
</div>
|
||||
|
||||
<?php ActiveForm::end(); ?>
|
||||
|
||||
Reference in New Issue
Block a user