page.list.dashboard.php 633 B

123456789101112131415161718192021
  1. <?php
  2. global $myUser,$conf;
  3. if(!$myUser->can('dashboard','read')) return;
  4. require_once(__DIR__.SLASH.'Dashboard.class.php');
  5. require_once(__DIR__.SLASH.'DashboardWidget.class.php');
  6. if(Dashboard::rowCount(array('scope'=>'home','uid'=>$myUser->login))==0){
  7. $dashboard = new Dashboard();
  8. $dashboard->uid = $myUser->login;
  9. $dashboard->scope = "home";
  10. $dashboard->save();
  11. }
  12. ?>
  13. <div class="plugin-dashboard">
  14. <div class="row">
  15. <div class="col-md-12">
  16. <div data-type="dashboard" id="home-dashboard" data-scope="home" data-uid="<?php echo $myUser->login ?>"></div>
  17. </div>
  18. </div>
  19. </div>