index.php 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. <?php
  2. use yii\grid\GridView;
  3. use yii\helpers\Html;
  4. /* @var $this yii\web\View */
  5. /* @var $searchModel common\modules\i18n\models\search\I18nMessageSearch */
  6. /* @var $dataProvider yii\data\ActiveDataProvider */
  7. $this->title = Yii::t('backend', 'I18n Messages');
  8. $this->params['breadcrumbs'][] = $this->title;
  9. ?>
  10. <?php $this->beginBlock('content-header') ?>
  11. <?= $this->title . ' ' . Html::a(Yii::t('app', '新i18n信息'), ['create'], ['class' => 'btn btn-success']) ?>
  12. <?php $this->endBlock() ?>
  13. <div class="box box-success">
  14. <div class="box-body">
  15. <?php echo GridView::widget([
  16. 'dataProvider' => $dataProvider,
  17. //'filterModel' => $searchModel,
  18. 'columns' => [
  19. 'id',
  20. [
  21. 'attribute'=>'language',
  22. 'filter'=> $languages
  23. ],
  24. [
  25. 'attribute'=>'category',
  26. 'filter'=> $categories
  27. ],
  28. 'sourceMessage',
  29. 'translation:ntext',
  30. ['class' => 'yii\grid\ActionColumn', 'template'=>'{update} {delete}'],
  31. ],
  32. ]); ?>
  33. </div>
  34. </div>