Fixed the error that caused the create button dissapeared under certain circunstances
(When no downtimes was retrieved) TICKET #2580
This commit is contained in:
parent
dd9c2029e2
commit
9f57329f65
|
@ -322,9 +322,29 @@ else {
|
||||||
$downtimes = array();
|
$downtimes = array();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// No downtimes
|
||||||
if (!$downtimes) {
|
if (!$downtimes) {
|
||||||
|
// Filter form
|
||||||
|
echo "<form method='post' action='index.php?sec=estado&sec2=godmode/agentes/planned_downtime.list'>";
|
||||||
|
html_print_table($table_form);
|
||||||
|
echo "</form>";
|
||||||
|
|
||||||
|
// Info message
|
||||||
echo '<div class="nf">'.__('No planned downtime').'</div>';
|
echo '<div class="nf">'.__('No planned downtime').'</div>';
|
||||||
|
|
||||||
|
echo '<div class="action-buttons" style="width: 98%">';
|
||||||
|
|
||||||
|
// Create button
|
||||||
|
if ($write_permisson) {
|
||||||
|
echo ' ';
|
||||||
|
echo '<form method="post" action="index.php?sec=estado&sec2=godmode/agentes/planned_downtime.editor" style="display: inline;">';
|
||||||
|
html_print_submit_button (__('Create'), 'create', false, 'class="sub next"');
|
||||||
|
echo '</form>';
|
||||||
|
}
|
||||||
|
|
||||||
|
echo '</div>';
|
||||||
}
|
}
|
||||||
|
// Has downtimes
|
||||||
else {
|
else {
|
||||||
echo "<form method='post' action='index.php?sec=estado&sec2=godmode/agentes/planned_downtime.list'>";
|
echo "<form method='post' action='index.php?sec=estado&sec2=godmode/agentes/planned_downtime.list'>";
|
||||||
html_print_table($table_form);
|
html_print_table($table_form);
|
||||||
|
|
Loading…
Reference in New Issue