Commit 3326ca8c authored by nextime's avatar nextime

justgage for analogs now is working great, and few minor fixes in the gui

parent ee6d082a
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -40,6 +40,10 @@
}
.badge-primary {
background-color: #428bca;
}
.navbar-title {
font-size: 20px;
font-weight: 500;
......
<?
$GUIDEBUG=FALSE;
//$GUIDEBUG=TRUE;
//$GUIDEBUG=FALSE;
$GUIDEBUG=TRUE;
function getBaseGuiPath()
......
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -30,6 +30,17 @@
if('<?=$_DOMOTIKA["gui_theme"]?>'=='dmblack')
notifyColor='#000';
var stringColors = {
'red': '#ff0000',
'green': '#5cb85c',
'gray': '#999999',
'orange': '#f0ad4e',
'blue': '#428bca',
'azure': '#5bc0de',
'black': '#000000',
'white': '#ffffff'
};
//var scroller = new AppScroll({
// toolbar: $('#topbar')[0],
// scroller: $('#content')[0]
......@@ -516,6 +527,11 @@
$(this).text(v);
}
);
$("[data-domotika-gaugeid="+val[0]+"]").each(
function() {
$(this).data('gauge').refresh(val[1]/$(this).attr('data-dmval-divider'));
}
);
break;
......@@ -533,6 +549,9 @@
$("[data-domotika-act2col="+val[0]+"]").each(
function() {
if(val[2]>0) {
console.debug($(this));
console.debug($(this).attr('data-dmcolor-off'));
console.debug($(this).attr('data-dmcolor-on'));
$(this).alterClass($(this).attr('data-dmcolor-off'), $(this).attr('data-dmcolor-on'));
} else {
$(this).alterClass($(this).attr('data-dmcolor-on'), $(this).attr('data-dmcolor-off'));
......
......@@ -33,6 +33,8 @@ js/starthammer.js
../../resources/js/jqplot/plugins/jqplot.cursor.min.js
../../resources/js/jqplot/plugins/jqplot.canvasTextRenderer.min.js
../../resources/js/jqplot/plugins/jqplot.canvasAxisTickRenderer.min.js
../../resources/js/raphael.min.js
../../resources/js/justgage.js
js/fastclick.js
js/speech.js
js/domotika.js
......
......@@ -3,7 +3,7 @@
<?
$panels=FALSE;
if($GUISUBSECTION!="" && is_numeric($GUISUBSECTION))
if($GUISUBSECTION!="")
{
$v=DB::query("SELECT * FROM stats_charts WHERE websection='$GUISUBSECTION' AND active=1 order by webposition,id");
if(is_array($v) && count($v)>0) {
......
......@@ -4,7 +4,20 @@ $_SESSION['PANELS_CHARTS']=array();
if($panel && is_array($panel)) {
$days = getLastNDays(7, 'Y-m-d' );
$daysql = getLastNDays(7, 'Y-m-d');
$charts=DB::query("SELECT * FROM stats_charts WHERE active=1 AND DMDOMAIN(name, '".$panel['panel_content']."')=1 order by webposition");
if($panel['panel_websections']!="" && $panel['panel_websections']!="*") {
$ws=" AND (";
$wss=explode(",", $panel['panel_websections']);
$cws=count($wss);
$cwsc=1;
foreach($wss as $w) {
$ws.="websection='$w'";
if($cwsc<$cws)
$ws.=" OR ";
$cwsc++;
}
$ws.=")";
}
$charts=DB::query("SELECT * FROM stats_charts WHERE active=1 AND DMDOMAIN(name, '".$panel['panel_content']."')=1 $ws order by webposition");
if(is_numeric($panel['panel_height'])) $panel['panel_height'].="px";
$visible="";
if($panel['panel_visible']!="all") $visible=$panel['panel_visible'];
......@@ -40,10 +53,11 @@ if($panel && is_array($panel)) {
<?
foreach($charts as $chart) {
//print_r($chart);
$_SESSION['PANELS_CHARTS'][$chart['name']."-".$panel['id']]=$chart;
$_SESSION['PANELS_CHARTS'][$chart['name']."-".$chart['id']]=$chart;
?>
<div id="<?=$chart['name']."-".$panel['id']?>" style="height:200px;width:550px"></div>
<?
<div id="<?=$chart['name']."-".$chart['id']?>" style="height:200px;width:550px"></div>
<?
}?>
</div>
</div>
......
......@@ -31,7 +31,8 @@
<script type="text/javascript" src="/resources/js/jqplot/plugins/jqplot.cursor.min.js"></script>
<script type="text/javascript" src="/resources/js/jqplot/plugins/jqplot.canvasTextRenderer.min.js"></script>
<script type="text/javascript" src="/resources/js/jqplot/plugins/jqplot.canvasAxisTickRenderer.min.js"></script>
<script type="text/javascript" src="/resources/js/raphael.min.js"></script>
<script type="text/javascript" src="/resources/js/justgage.js"></script>
<script src="<?=$BASEGUIPATH;?>/js/fastclick.js"></script>
<script src="<?=$BASEGUIPATH;?>/js/speech.js"></script>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment