Fixed group status icon

This commit is contained in:
danielmaya 2017-12-13 17:10:05 +01:00
parent 009f2c1b54
commit 14d5bb04c1
1 changed files with 17 additions and 39 deletions

View File

@ -2719,26 +2719,18 @@ function createItem(type, values, id_data) {
break;
case 'group_item':
switch (type) {
case 'group_item':
class_type = "group_item";
break;
case 'static_graph':
class_type = "static_graph";
break;
}
class_type = "group_item";
img_src = "images/spinner.gif";
img_src = "images/spinner.gif";
item = $('<div></div>')
.attr('id', id_data)
.attr('class', 'item ' + class_type)
.css('text-align', 'left')
.css('position', 'absolute')
.css('display', 'inline-block')
.css('top', values['top'] + 'px')
.css('left', values['left'] + 'px');
item = $('<div></div>')
.attr('id', id_data)
.attr('class', 'item ' + class_type)
.css('text-align', 'left')
.css('position', 'absolute')
.css('display', 'inline-block')
.css('top', values['top'] + 'px')
.css('left', values['left'] + 'px');
@ -2839,7 +2831,7 @@ function createItem(type, values, id_data) {
if(values['label_position'] == 'up'){
if(values['image'] == '' || values['image'] == 'none'){
if((values['image'] == '' || values['image'] == 'none') && values['show_statistics'] != 1){
item
.append('<table style="width:70px"><tr><td></td></tr><tr><td><span id="text_'+id_data+'" class="text">'+values['label']+'</span></td></tr><tr><td></td></tr></table>')
.append($input);
@ -2848,14 +2840,12 @@ function createItem(type, values, id_data) {
item
.append('<table style="width:70px"><tr><td></td></tr><tr><td><span id="text_'+id_data+'" class="text">'+values['label']+'</span></td></tr><tr><td></td></tr></table>')
.append($image)
.append($image)
.append($input);
}
}
else if(values['label_position'] == 'down'){
if(values['image'] == '' || values['image'] == 'none'){
if((values['image'] == '' || values['image'] == 'none') && values['show_statistics'] != 1){
item
.append('<table style="width:70px"><tr><td></td></tr><tr><td><span id="text_'+id_data+'" class="text">'+values['label']+'</span></td></tr><tr><td></td></tr></table>')
.append($input);
@ -2863,7 +2853,6 @@ function createItem(type, values, id_data) {
}
else{
item
.append($image)
.append($image)
.append('<table style="width:70px"><tr><td></td></tr><tr><td><span id="text_'+id_data+'" class="text">'+values['label']+'</span></td></tr><tr><td></td></tr></table>')
.append($input);
@ -2881,14 +2870,13 @@ function createItem(type, values, id_data) {
.append('<table style="float:left;height:'+values['height']+'px"><tr><td></td></tr><tr><td><span id="text_'+id_data+'" class="text">'+values['label']+'</span></td></tr><tr><td></td></tr></table>')
}
if(values['image'] == '' || values['image'] == 'none'){
if((values['image'] == '' || values['image'] == 'none') && values['show_statistics'] != 1){
item
.append($input);
}
else{
item
.append($image)
.append($image)
.append($input);
}
@ -2904,19 +2892,16 @@ function createItem(type, values, id_data) {
.append('<table style="float:right;height:'+values['height']+'px"><tr><td></td></tr><tr><td><span id="text_'+id_data+'" class="text">'+values['label']+'</span></td></tr><tr><td></td></tr></table>')
}
if(values['image'] == '' || values['image'] == 'none'){
if((values['image'] == '' || values['image'] == 'none') && values['show_statistics'] != 1){
item
.append($input);
}
else{
item
.append($image)
.append($image)
.append($input);
}
}
if(values['show_statistics'] != 1){
@ -2976,15 +2961,8 @@ function createItem(type, values, id_data) {
break;
case 'static_graph':
switch (type) {
case 'group_item':
class_type = "group_item";
break;
case 'static_graph':
class_type = "static_graph";
break;
}
class_type = "static_graph";
img_src = "images/spinner.gif";
item = $('<div></div>')