left.php 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. <aside class="main-sidebar">
  2. <section class="sidebar">
  3. <!-- Sidebar user panel -->
  4. <div class="user-panel">
  5. <div class="pull-left image">
  6. <img src="<?= $directoryAsset ?>/img/user2-160x160.jpg" class="img-circle" alt="User Image"/>
  7. </div>
  8. <div class="pull-left info">
  9. <p><?=Yii::$app->user->identity->username?></p>
  10. <a href="#"><i class="fa fa-circle text-success"></i> Online</a>
  11. </div>
  12. </div>
  13. <!-- search form -->
  14. <form action="#" method="get" class="sidebar-form">
  15. <div class="input-group">
  16. <input type="text" name="q" class="form-control" placeholder="Search..."/>
  17. <span class="input-group-btn">
  18. <button type='submit' name='search' id='search-btn' class="btn btn-flat"><i class="fa fa-search"></i>
  19. </button>
  20. </span>
  21. </div>
  22. </form>
  23. <!-- /.search form -->
  24. <?= dmstr\widgets\Menu::widget(
  25. [
  26. 'options' => ['class' => 'sidebar-menu tree', 'data-widget'=> 'tree'],
  27. 'items' => [
  28. ['label' => 'Menu Yii2', 'options' => ['class' => 'header']],
  29. ['label' => 'Gii', 'icon' => 'file-code-o', 'url' => ['/gii']],
  30. ['label' => 'Debug', 'icon' => 'dashboard', 'url' => ['/debug']],
  31. ['label' => 'Login', 'url' => ['site/login'], 'visible' => Yii::$app->user->isGuest],
  32. [
  33. 'label' => 'Some tools',
  34. 'icon' => 'share',
  35. 'url' => '#',
  36. 'items' => [
  37. ['label' => 'Gii', 'icon' => 'file-code-o', 'url' => ['/gii'],],
  38. ['label' => 'Debug', 'icon' => 'dashboard', 'url' => ['/debug'],],
  39. [
  40. 'label' => 'Level One',
  41. 'icon' => 'circle-o',
  42. 'url' => '#',
  43. 'items' => [
  44. ['label' => 'Level Two', 'icon' => 'circle-o', 'url' => '#',],
  45. [
  46. 'label' => 'Level Two',
  47. 'icon' => 'circle-o',
  48. 'url' => '#',
  49. 'items' => [
  50. ['label' => 'Level Three', 'icon' => 'circle-o', 'url' => '#',],
  51. ['label' => 'Level Three', 'icon' => 'circle-o', 'url' => '#',],
  52. ],
  53. ],
  54. ],
  55. ],
  56. ],
  57. ],
  58. ],
  59. ]
  60. ) ?>
  61. </section>
  62. </aside>