You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

41 lines
1018 B

  1. <?php
  2. use yii\helpers\Html;
  3. use blobt\grid\GridView;
  4. //use yii\grid\GridView;
  5. /* @var $this yii\web\View */
  6. /* @var $searchModel common\models\CategorySearch */
  7. /* @var $dataProvider yii\data\ActiveDataProvider */
  8. $this->title = 'Categories';
  9. $this->params['breadcrumbs'][] = $this->title;
  10. ?>
  11. <div class="row">
  12. <div class="col-xs-12">
  13. <?php
  14. echo GridView::widget([
  15. 'dataProvider' => $dataProvider,
  16. 'columns' => [
  17. [
  18. 'attribute' => 'id',
  19. 'label' => 'Id',
  20. "width" => "30px",
  21. 'align' => 'center'
  22. ],
  23. [
  24. 'attribute' => 'cat_name',
  25. 'label' => '类名'
  26. ],
  27. 'icon',
  28. 'icon_type',
  29. 'description:ntext',
  30. [
  31. 'class' => 'yii\grid\ActionColumn',
  32. ],
  33. ],
  34. ]);
  35. ?>
  36. </div>
  37. </div>