update timeline header
parent
41c1774e4a
commit
0879ecf9a5
|
@ -214,3 +214,30 @@ window.addEventListener('DOMContentLoaded', function() {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
function initPage() {
|
||||||
|
var backBtn = $j('#backBtn');
|
||||||
|
|
||||||
|
// Don't enable the back button if there is no previous zm page to go back to
|
||||||
|
backBtn.prop('disabled', !document.referrer.length);
|
||||||
|
|
||||||
|
// Manage the BACK button
|
||||||
|
document.getElementById("backBtn").addEventListener("click", function onBackClick(evt) {
|
||||||
|
evt.preventDefault();
|
||||||
|
window.history.back();
|
||||||
|
});
|
||||||
|
|
||||||
|
// Manage the REFRESH Button
|
||||||
|
document.getElementById("refreshBtn").addEventListener("click", function onRefreshClick(evt) {
|
||||||
|
evt.preventDefault();
|
||||||
|
window.location.reload(true);
|
||||||
|
});
|
||||||
|
// Manage the LIST Button
|
||||||
|
document.getElementById("listBtn").addEventListener("click", function onListClick(evt) {
|
||||||
|
evt.preventDefault();
|
||||||
|
window.location.assign('?view=events'+filterQuery);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
$j(document).ready(function() {
|
||||||
|
initPage();
|
||||||
|
});
|
||||||
|
|
|
@ -673,18 +673,17 @@ $focusWindow = true;
|
||||||
xhtmlHeaders(__FILE__, translate('Timeline'));
|
xhtmlHeaders(__FILE__, translate('Timeline'));
|
||||||
?>
|
?>
|
||||||
<body>
|
<body>
|
||||||
<div id="page">
|
|
||||||
<?php echo getNavBarHTML() ?>
|
<?php echo getNavBarHTML() ?>
|
||||||
<div id="header">
|
<div id="page p-0">
|
||||||
<div id="info">
|
<div class="d-flex p-1">
|
||||||
<h2><?php echo translate('Timeline') ?></h2>
|
<div class="mr-auto" id="toolbar" >
|
||||||
<a id="refreshLink" href="#" data-on-click="refreshWindow"><?php echo translate('Refresh') ?></a>
|
<button id="backBtn" class="btn btn-normal" data-toggle="tooltip" data-placement="top" title="<?php echo translate('Back') ?>" disabled><i class="fa fa-arrow-left"></i></button>
|
||||||
</div>
|
<button id="refreshBtn" class="btn btn-normal" data-toggle="tooltip" data-placement="top" title="<?php echo translate('Refresh') ?>" ><i class="fa fa-refresh"></i></button>
|
||||||
<div id="headerButtons">
|
<button id="listBtn" class="btn btn-normal" data-toggle="tooltip" data-placement="top" title="<?php echo translate('List') ?>" ><i class="fa fa-list"></i></button>
|
||||||
<a href="#" data-on-click="backWindow"><?php echo translate('Back') ?></a>
|
|
||||||
<a href="?view=events&page=1<?php echo htmlspecialchars($filterQuery) ?>"><?php echo translate('List') ?></a>
|
|
||||||
</div>
|
</div>
|
||||||
|
<h2 class="align-self-end"><?php echo translate('Timeline') ?></h2>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="content" class="chartSize">
|
<div id="content" class="chartSize">
|
||||||
<div id="topPanel" class="graphWidth">
|
<div id="topPanel" class="graphWidth">
|
||||||
<div id="imagePanel">
|
<div id="imagePanel">
|
||||||
|
|
Loading…
Reference in New Issue