Auto refresh sticky
This commit is contained in:
parent
b37d5c2a9b
commit
a76eb3ffa2
5 changed files with 24 additions and 13 deletions
11
CHANGELOG.md
11
CHANGELOG.md
|
|
@ -1,9 +1,16 @@
|
||||||
# Change Log
|
# Change Log
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
|
|
||||||
## [v2.0.2] - 2024-09-
|
## [v2.0.2] - 2024-09-07
|
||||||
|
### Added
|
||||||
|
- Remember Refresh setting by browser
|
||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
- Error when `IFACES`=""
|
- Error when `IFACES` are empty
|
||||||
|
- Sticky sort bug fix
|
||||||
|
- Bug [#124](https://github.com/aceberg/WatchYourLAN/issues/124)
|
||||||
|
- Bug [#128](https://github.com/aceberg/WatchYourLAN/issues/128)
|
||||||
|
|
||||||
|
|
||||||
## [v2.0.1] - 2024-09-02
|
## [v2.0.1] - 2024-09-02
|
||||||
### Added
|
### Added
|
||||||
|
|
|
||||||
|
|
@ -5,12 +5,17 @@ autoRefresh();
|
||||||
|
|
||||||
function toggleRefresh() {
|
function toggleRefresh() {
|
||||||
ref = !ref;
|
ref = !ref;
|
||||||
|
|
||||||
|
localStorage.setItem("refAuto", ref);
|
||||||
|
|
||||||
autoRefresh()
|
autoRefresh();
|
||||||
}
|
}
|
||||||
|
|
||||||
function autoRefresh() {
|
function autoRefresh() {
|
||||||
|
|
||||||
|
ref = JSON.parse(localStorage.getItem("refAuto"));
|
||||||
|
document.getElementById("ref").checked = ref;
|
||||||
|
|
||||||
if (ref) {
|
if (ref) {
|
||||||
const timeout = document.getElementById("ref-timeout").value;
|
const timeout = document.getElementById("ref-timeout").value;
|
||||||
console.log("Refresh timeout", timeout);
|
console.log("Refresh timeout", timeout);
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,5 @@
|
||||||
{{ define "history.html" }}
|
{{ define "history.html" }}
|
||||||
</head>
|
</head>
|
||||||
<script src="/fs/public/js/history.js"></script>
|
|
||||||
<script src="/fs/public/js/hist-html.js"></script>
|
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
<div class="container-lg">
|
<div class="container-lg">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
|
@ -36,6 +33,8 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<script src="/fs/public/js/history.js"></script>
|
||||||
|
<script src="/fs/public/js/hist-html.js"></script>
|
||||||
|
|
||||||
{{ template "footer.html" }}
|
{{ template "footer.html" }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
@ -1,8 +1,5 @@
|
||||||
{{ define "host.html" }}
|
{{ define "host.html" }}
|
||||||
|
|
||||||
<script src="/fs/public/js/host-scan.js"></script>
|
|
||||||
<script src="/fs/public/js/host.js"></script>
|
|
||||||
<script src="/fs/public/js/hist-html.js"></script>
|
|
||||||
<body>
|
<body>
|
||||||
<div class="container-lg">
|
<div class="container-lg">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
|
@ -112,6 +109,9 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<script src="/fs/public/js/host-scan.js"></script>
|
||||||
|
<script src="/fs/public/js/host.js"></script>
|
||||||
|
<script src="/fs/public/js/hist-html.js"></script>
|
||||||
<script>
|
<script>
|
||||||
loadHistory('{{ .Host.Mac }}');
|
loadHistory('{{ .Host.Mac }}');
|
||||||
</script>
|
</script>
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,5 @@
|
||||||
{{ define "index.html" }}
|
{{ define "index.html" }}
|
||||||
</head>
|
</head>
|
||||||
<script src="/fs/public/js/index.js"></script>
|
|
||||||
<script src="/fs/public/js/sort.js"></script>
|
|
||||||
<script src="/fs/public/js/filter-search.js"></script>
|
|
||||||
<script src="/fs/public/js/refresh.js"></script>
|
|
||||||
<body>
|
<body>
|
||||||
<div class="container-lg">
|
<div class="container-lg">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
|
@ -68,6 +64,10 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<script src="/fs/public/js/index.js"></script>
|
||||||
|
<script src="/fs/public/js/sort.js"></script>
|
||||||
|
<script src="/fs/public/js/filter-search.js"></script>
|
||||||
|
<script src="/fs/public/js/refresh.js"></script>
|
||||||
|
|
||||||
{{ template "footer.html" }}
|
{{ template "footer.html" }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
Loading…
Reference in a new issue