Skip to content

Commit

Permalink
Start/stop service: Hide useless service button
Browse files Browse the repository at this point in the history
  • Loading branch information
QuentinCG committed Aug 18, 2017
1 parent 79f858d commit 0810d3b
Showing 1 changed file with 20 additions and 2 deletions.
22 changes: 20 additions & 2 deletions js/esm.js
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,16 @@ esm.getServices = function() {
var html = '';
html += '<tr>';
html += '<td class="w15p"><span class="label '+label_color+'">'+label_status+'</span></td>';
html += '<td><a class="reload spin disabled" service='+id+' onclick="esm.setServices('+id+');"><span class="'+label_gestion+'"></span></a></td>';

if (data[line].start != null && data[line].stop != null)
{
html += '<td><a class="reload spin disabled" service='+id+' onclick="esm.setServices('+id+');"><span class="'+label_gestion+'"></span></a></td>';
}
else
{
html += '<td></td>';
}

html += '<td>'+data[line].name+'</td>';
html += '<td class="w15p">'+data[line].port+'</td>';
html += '</tr>';
Expand Down Expand Up @@ -334,7 +343,16 @@ esm.setServices = function(id) {

var html = '';
html += '<td class="w15p"><span class="label '+label_color+'">'+label_status+'</span></td>';
html += '<td><a class="reload" service='+id+' onclick="esm.setServices('+id+');"><span class="'+label_gestion+'"></span></a></td>';

if (data[id].start != null && data[id].stop != null)
{
html += '<td><a class="reload" service='+id+' onclick="esm.setServices('+id+');"><span class="'+label_gestion+'"></span></a></td>';
}
else
{
html += '<td></td>';
}

html += '<td>'+data[id].name+'</td>';
html += '<td class="w15p">'+data[id].port+'</td>';

Expand Down

0 comments on commit 0810d3b

Please sign in to comment.