<script src="js/d3.v3.min.js"></script>
<script src="js/d3plugins/gauge/gauge.js"></script>
<script src="js/d3plugins/gauge/plGauge.js"></script>

<?php

$this->renderTabMenu('systemOverview');

echo app()->params->applianceMode ? "<div class='leftGrid'>" : "";

$this->widget('ext.PlGrid.PlGridView', array(
        'id' => 'system-overview-grid',
        'enableHeaderTranslation' => false,
        'itemsCssClass' => 'plTable items table-fixed',
        'dataProvider' => $model->getCurrentSystemOverviewDataProvider(),
        'enableSearchButton' => false,
        'showAlertBlock' => true,
        'enableAddButton' => false,
        'summaryText' => false,
        'showNavbar' => false,
        'columns' => array(
            array(
                'header' => __('SYSTEM_OVERVIEW_TITLE_SYSTEM_OVERVIEW'),
                'headerHtmlOptions' => array('data-translation-id' => 'SYSTEM_OVERVIEW_TITLE_SYSTEM_OVERVIEW'),
                'type' => 'raw',
                'value' => array($this, 'renderSystemOverviewGridKeys'),
            ),
            array(
                'type' => 'raw',
                'value' => array($this, 'renderSystemOverviewGridValue'),
            ),
        ),
    )
);

echo app()->params->applianceMode ? "</div>" : "";
if (app()->params->applianceMode) {
    echo "<div class='rightGrid'>";
    echo $this->renderSystemLoadGaugeGrid($model);
    echo $this->renderMemoryGaugeGrid($model);
    echo "</div>";
}

$this->widget('ext.PlGrid.PlGridView', array(
    'id' => 'statistics-overview-grid',
    'enableHeaderTranslation' => false,
    'itemsCssClass' => 'plTable items',
    'dataProvider' => $model->getStatisticsOverview(),
    'enableSearchButton' => false,
    'showAlertBlock' => true,
    'enableAddButton' => false,
    'summaryText' => false,
    'showNavbar' => false,
    'columns' => $this->renderStatisticsOverviewColumns($model),
        )
);

?>
<script>
//FIXME : fix less files to overwrite .table css class
$('.gauge-grid table').css("width", "inherit")
</script>