new balance

This commit is contained in:
2019-06-25 12:37:09 +03:00
parent a783be26d1
commit 2f4f92bdec
16 changed files with 523 additions and 58 deletions

View File

@ -0,0 +1,18 @@
<?php
namespace backend\widgets;
use yii\base\Widget;
class DateRangeWidget extends Widget
{
public $model;
public function run()
{
return $this->render('date_range', ['model' => $this->model]);
}
}

View File

@ -0,0 +1,19 @@
<?php
namespace backend\widgets;
use yii\base\Widget;
class SummRangeWidget extends Widget
{
public $model;
public $range_attribute;
public function run()
{
return $this->render('summ_range', ['model' => $this->model]);
}
}

View File

@ -0,0 +1,21 @@
<?php
/**
* @var $model \yii\db\ActiveRecord
*/
use yii\jui\DatePicker;
echo DatePicker::widget([
'model' => $model,
'attribute' => 'dt_from',
'language' => 'ru',
'dateFormat' => 'dd-MM-yyyy',
]);
echo " - ";
echo DatePicker::widget([
'model' => $model,
'attribute' => 'dt_to',
'language' => 'ru',
'dateFormat' => 'dd-MM-yyyy',
]);

View File

@ -0,0 +1,12 @@
<?php
/**
* @var $model \yii\db\ActiveRecord
*/
echo \yii\helpers\Html::activeTextInput($model, 'summ_from', [
'placeholder' => 'От',
]);
echo ' - ';
echo \yii\helpers\Html::activeTextInput($model, 'summ_to', [
'placeholder' => 'До',
]);