Skip to content

Commit

Permalink
Merge pull request EliasKotlyar#1421 from Dopeyr/services-page-issue
Browse files Browse the repository at this point in the history
Resolve issue with start/stop buttons being disabled.
  • Loading branch information
jmtatsch authored May 13, 2020
2 parents c0625a9 + d09f2ed commit c65614a
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions firmware_mod/www/cgi-bin/scripts.cgi
Original file line number Diff line number Diff line change
Expand Up @@ -75,17 +75,18 @@ else
if [ -x "$SCRIPT_HOME/$i" ]; then
if grep -q "^status()" "$SCRIPT_HOME/$i"; then
status=$("$SCRIPT_HOME/$i" status)
badgestatus=$status
if [ $? -eq 0 ]; then
if [ -n "$status" ]; then
badge="";
else
else
badge="is-badge-warning";
fi
else
badge="is-badge-danger"
status="NOK"
badgestatus="NOK"
fi
echo "<span class='badge $badge' data-badge='$status'>$i</span>"
echo "<span class='badge $badge' data-badge='$badgestatus'>$i</span>"
else
echo "$i"
fi
Expand Down

0 comments on commit c65614a

Please sign in to comment.