eb7e82fb
Administrator
29.02.16
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
<?php
/**
* @var PortfolioSearch $searchModel
* @var ActiveDataProvider $dataProvider
*/
use common\models\PortfolioSearch;
use yii\data\ActiveDataProvider;
use yii\grid\ActionColumn;
use yii\grid\GridView;
use yii\helpers\Html;
use yii\jui\DatePicker;
$this->title = 'Портфолио';
$this->params[ 'breadcrumbs' ][] = $this->title;
?>
<div class="login-left-column-title"><?= $this->title ?></div>
<div class="admin-all-pages-add">
|
06ec2844
Administrator
28.03.16
|
18
|
<?= Html::a(Yii::t('app', 'add'), [ 'portfolio-create' ], [ 'class' => 'btn btn-success' ]) ?>
|
eb7e82fb
Administrator
29.02.16
|
19
20
21
|
</div>
<div class="admin-table-portfolio">
<?= GridView::widget([
|
f0a961be
Yarik
test
|
22
|
'options' => [ 'class' => 'style admin-all-pages-wr' ],
|
eb7e82fb
Administrator
29.02.16
|
23
24
25
26
27
28
29
30
31
32
|
'dataProvider' => $dataProvider,
'filterModel' => $searchModel,
'columns' => [
[
'attribute' => 'portfolio_id',
'label' => 'ID',
],
'name',
[
'attribute' => 'date_add',
|
f0a961be
Yarik
test
|
33
34
35
36
37
38
|
'filter' => "<div class=\"input-group input-group-xs input-daterange\">
<span class='field-teamsearch-experience_from_from'>" . DatePicker::widget([
'model' => $searchModel,
'attribute' => 'date_add_from',
'language' => 'ru',
'dateFormat' => 'yyyy-MM-dd',
|
eb7e82fb
Administrator
29.02.16
|
39
|
'clientOptions' => [
|
f0a961be
Yarik
test
|
40
|
'changeYear' => true,
|
eb7e82fb
Administrator
29.02.16
|
41
42
|
'changeMonth' => true,
],
|
f0a961be
Yarik
test
|
43
|
]) . "</span>
|
eb7e82fb
Administrator
29.02.16
|
44
45
46
|
<span class=\"input-group-addon kv-field-separator\">
<i class=\"glyphicon glyphicon-resize-horizontal\"></i>
</span>
|
f0a961be
Yarik
test
|
47
48
49
50
51
|
<span class='field-teamsearch-experience_from_to'>" . DatePicker::widget([
'model' => $searchModel,
'attribute' => 'date_add_to',
'language' => 'ru',
'dateFormat' => 'yyyy-MM-dd',
|
eb7e82fb
Administrator
29.02.16
|
52
|
'clientOptions' => [
|
f0a961be
Yarik
test
|
53
|
'changeYear' => true,
|
eb7e82fb
Administrator
29.02.16
|
54
55
|
'changeMonth' => true,
],
|
f0a961be
Yarik
test
|
56
|
]) . "</span>
|
eb7e82fb
Administrator
29.02.16
|
57
|
</div>",
|
f0a961be
Yarik
test
|
58
|
'format' => 'html',
|
eb7e82fb
Administrator
29.02.16
|
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
|
],
'view_count',
[
'value' => function($model, $key, $index, $column) {
return 0;
},
'label' => 'Рейтинг',
],
[
'value' => function($model, $key, $index, $column) {
return 0;
},
'label' => 'Комментарии',
],
[
'attribute' => 'specializationString',
],
[
'class' => ActionColumn::className(),
'buttons' => [
'update' => function($url, $model, $key) {
return Html::a('<img src="/images/ico_pencil.png" alt="">', [
'portfolio-update',
'id' => $model->portfolio_id,
|
f0a961be
Yarik
test
|
83
84
|
], [
'title' => 'Редактировать',
|
eb7e82fb
Administrator
29.02.16
|
85
86
87
88
89
90
91
|
]);
},
'delete' => function($url, $model, $key) {
return Html::a('<img src="/images/delete-ico.png" alt="">', [
'portfolio-delete',
'id' => $model->portfolio_id,
], [
|
06ec2844
Administrator
28.03.16
|
92
93
|
'title' => Yii::t('app', 'delete'),
'aria-label' => Yii::t('app', 'delete'),
|
f0a961be
Yarik
test
|
94
|
'data-confirm' => Yii::t('app', 'delete_confirm'),
|
eb7e82fb
Administrator
29.02.16
|
95
96
97
98
99
100
101
102
103
104
|
'data-method' => 'post',
'data-pjax' => '0',
]);
},
],
'template' => '{update} {delete}',
],
],
]); ?>
</div>
|