Advertisement
Guest User

Untitled

a guest
Oct 4th, 2015
95
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.31 KB | None | 0 0
  1. <div class="sidebar-shortcuts" id="sidebar-shortcuts" data-step="4" data-intro="ShortCut Menu, Jalan pintas ke Halaman favorit anda.">
  2. <div class="sidebar-shortcuts-large" id="sidebar-shortcuts-large">
  3. <?php
  4. $dolevel = $this->session->userdata('status');
  5. if($dolevel=='8'){
  6. ?>
  7. <a href="<?php echo site_url('CHome/HomeNotification'); ?>" data-rel="tooltip" title="Notifikasi" id="sidebar-shortcuts" data-step="5" data-intro="ShortCut ke Notifikasi Harian."/>
  8. <button class="btn btn-small btn-success" >
  9. <i class="icon-signal"></i>
  10. </button>
  11. </a>
  12. <?php
  13. }
  14. ?>
  15. <a href="<?php echo site_url('CCustomer/AddCustomer'); ?>" data-rel="tooltip" title="Add Customer" data-rel="tooltip" title="Notifikasi" id="sidebar-shortcuts" data-step="6" data-intro="ShortCut ke Add Customer."/>
  16. <button class="btn btn-small btn-info">
  17. <i class="icon-pencil"></i>
  18. </button>
  19. </a>
  20.  
  21. <a href="<?php echo site_url('CTimeline/index'); ?>" data-rel="tooltip" title="Timeline" data-rel="tooltip" title="Notifikasi" id="sidebar-shortcuts" data-step="7" data-intro="ShortCut ke Chatting."/>
  22. <button class="btn btn-small btn-warning">
  23. <i class="icon-group"></i>
  24. </button>
  25. </a>
  26.  
  27. <a href="<?php echo site_url('CUser/setting'); ?>" data-rel="tooltip" title="User Setting" data-rel="tooltip" title="Notifikasi" id="sidebar-shortcuts" data-step="8" data-intro="ShortCut ke Setting Profille Anda."/>
  28. <button class="btn btn-small btn-danger">
  29. <i class="icon-cogs"></i>
  30. </button>
  31. </a>
  32. </div>
  33.  
  34. <div class="sidebar-shortcuts-mini" id="sidebar-shortcuts-mini">
  35. <span class="btn btn-success"></span>
  36. <span class="btn btn-info"></span>
  37. <span class="btn btn-warning"></span>
  38. <span class="btn btn-danger"></span>
  39. </div>
  40. </div>
  41.  
  42.  
  43. <?php
  44.  
  45. $sesmenu = $this->session->userdata('clasmenu');
  46. $sessparent = $this->session->userdata('clasparent');
  47. $level = $this->session->userdata('status');
  48. $this->ci =& get_instance(); // get a reference to CodeIgniter.
  49. $getmenu = $this->db->query("SELECT m_id,m_parent_id,m_name,m_url,m_icon,m_number,m_urut,m_desc
  50. FROM menu WHERE m_parent_id = '0' AND m_level LIKE '%$level%' AND m_active='1'
  51. ORDER BY m_urut ASC ")->result();
  52. ?>
  53. <ul class='nav nav-list' data-step='8' data-intro='Menu Navigasi, Menu utama pada aplikasi ini,dan menu customer merupakan menu yg wajib anda Buka '>
  54. <?php
  55. foreach($getmenu as $first){
  56.  
  57. if($sesmenu==$first->m_desc){
  58. $addclass = 'active';
  59. }else{
  60. $addclass = '';
  61. }
  62.  
  63. if($sessparent==$first->m_desc){
  64. $addclass = 'active';
  65. }else{
  66. $addclass = '';
  67. }
  68.  
  69.  
  70.  
  71.  
  72. $curr = $first->m_id;
  73. $ico = $first->m_icon;
  74. $chk = $this->db->query("SELECT m_id FROM menu where m_parent_id='$curr'");
  75.  
  76. if($chk->num_rows()>0)
  77. {
  78.  
  79. ?>
  80. <li class='<?php echo $addclass;?>'>
  81. <a href='<?php echo site_url($first->m_url);?>' class='dropdown-toggle'>
  82. <i class='<?php echo $ico;?>'></i>
  83. <span class='menu-text'> <?php echo $first->m_name;?></span>
  84. <b class='arrow icon-angle-down'></b>
  85. </a>
  86.  
  87. <?php
  88. $getpar = $this->db->query("SELECT m_id,m_parent_id,m_name,m_url,m_icon,m_number,m_urut,m_desc
  89. FROM menu WHERE m_parent_id = '$curr' AND m_level LIKE '%$level%' AND m_active='1' ORDER BY m_name ASC")->result();
  90. ?>
  91.  
  92. <ul class='submenu'>
  93. <?php
  94. foreach($getpar as $second)
  95. {
  96. $sec = "$second->m_url";
  97.  
  98. if($sesmenu==$second->m_desc){
  99. $addclass = 'active';
  100. }else{
  101. $addclass = '';
  102. }
  103. ?>
  104. <li class='<?php echo $addclass;?>'>
  105. <a href='<?php echo base_url($second->m_url);?>'>
  106. <i class='icon-double-angle-right'></i>
  107. <?php echo $second->m_name;?>
  108. </a>
  109. </li>
  110. <?php
  111. }
  112. ?>
  113. </ul>
  114. </li>
  115. <?php
  116.  
  117. }
  118. else
  119. {
  120. ?>
  121. <li class='<?php echo $addclass;?>'>
  122. <?php
  123. $urlf = "$first->m_url"; ?>
  124. <a href='<?php echo base_url($urlf);?>'>
  125. <i class='<?php echo $ico;?>'></i>
  126. <span class='menu-text'> <?php echo $first->m_name;?> </span>
  127. </a>
  128. </li>
  129. <?php
  130.  
  131. }
  132. }
  133. ?>
  134. </ul>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement