mirror of
https://github.com/cesanta/mongoose.git
synced 2026-12-05 22:08:23 +00:00
device-dashboard: fixed event table POST request
This commit is contained in:
1 parent
5c87f2f22c
commit
c63135ec7f
1 file changed
+2
-9
@@ -55,15 +55,8 @@ function Events({}) {
|
|||||||
const [page, setPage] = useState(1);
|
const [page, setPage] = useState(1);
|
||||||
|
|
||||||
const refresh = () =>
|
const refresh = () =>
|
||||||
fetch('/api/events/get',
|
fetch('/api/events/get', {
|
||||||
{
|
method: 'POST', body: JSON.stringify({page: page}),
|
||||||
method: 'POST',
|
|
||||||
headers: {
|
|
||||||
'Content-Type': 'application/json',
|
|
||||||
},
|
|
||||||
body: JSON.stringify({
|
|
||||||
page: page
|
|
||||||
}),
|
|
||||||
}).then(r => r.json())
|
}).then(r => r.json())
|
||||||
.then(r => setEvents(r));
|
.then(r => setEvents(r));
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user