Dotclear


Ignore:
Timestamp:
11/19/16 10:56:00 (9 years ago)
Author:
franck <carnet.franck.paul@…>
Branch:
default
Message:

Separate dashboard items boxes (usually official DC infos/links) from dashboard contents boxes (usually 3rd party plugins), get advantage of flexbox system to display all of them

File:
1 edited

Legend:

Unmodified
Added
Removed
  • admin/index.php

    r3390 r3412  
    173173 
    174174# Dashboard content 
    175 $dashboardContents = ''; 
    176175$__dashboard_contents = new ArrayObject(array(new ArrayObject,new ArrayObject)); 
    177176$core->callBehavior('adminDashboardContents', $core, $__dashboard_contents); 
     
    312311} 
    313312 
    314 # Dashboard columns (processed first, as we need to know the result before displaying the icons.) 
     313# Dashboard items and contents (processed first, as we need to know the result before displaying the icons.) 
    315314$dashboardItems = ''; 
    316  
    317315foreach ($__dashboard_items as $i) 
    318316{ 
    319      if ($i->count() > 0) 
    320      { 
    321           $dashboardItems .= ''; 
    322           foreach ($i as $v) { 
    323                $dashboardItems .= $v; 
    324           } 
    325           $dashboardItems .= ''; 
    326      } 
    327 } 
    328  
    329 # Dashboard elements 
     317     foreach ($i as $v) { 
     318          $dashboardItems .= $v; 
     319     } 
     320} 
     321$dashboardContents = ''; 
     322foreach ($__dashboard_contents as $i) 
     323{ 
     324     foreach ($i as $v) { 
     325          $dashboardContents .= $v; 
     326     } 
     327} 
     328 
     329# Dashboard elements: icons then boxes (items then contents) 
    330330echo '<div id="dashboard-main">'; 
    331331 
     
    391391} 
    392392 
    393 foreach ($__dashboard_contents as $i) 
    394 { 
    395      if ($i->count() > 0) 
    396      { 
    397           $dashboardContents .= ''; 
    398           foreach ($i as $v) { 
    399                $dashboardContents .= $v; 
    400           } 
    401           $dashboardContents .= ''; 
    402      } 
    403 } 
    404  
    405393if ($dashboardContents != '' || $dashboardItems != '') { 
    406394     echo 
    407395     '<div id="dashboard-boxes">'. 
    408      '<div class="db-items">'.$dashboardItems.$dashboardContents.'</div>'. 
     396     '<div class="db-items">'.$dashboardItems.'</div>'. 
     397     '<div class="db-contents">'.$dashboardContents.'</div>'. 
    409398     '</div>'; 
    410399} 
Note: See TracChangeset for help on using the changeset viewer.

Sites map