mirror of
https://github.com/bunkerity/bunkerweb
synced 2026-05-24 09:28:37 +00:00
Refactor antibot ui function and update template.html
This commit is contained in:
parent
db084c6f11
commit
7377909976
2 changed files with 2 additions and 5 deletions
|
|
@ -1,5 +1,2 @@
|
|||
import json
|
||||
|
||||
|
||||
def antibot():
|
||||
return json.dumps({"message": "ok", "data": {"info": "test", "count": 24}})
|
||||
return {"message": "ok", "data": {"info": "test", "count": 24}}
|
||||
|
|
|
|||
|
|
@ -126,13 +126,13 @@
|
|||
fetch(location.href, {
|
||||
method: "POST",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
"X-CSRFToken": "{{ csrf_token() }}",
|
||||
},
|
||||
})
|
||||
.then((res) => res.json())
|
||||
.then((res) => {
|
||||
console.log(res);
|
||||
console.log(JSON.stringify(res));
|
||||
console.log(res.data);
|
||||
console.log(res.data.data);
|
||||
// Update data and DOM
|
||||
|
|
|
|||
Loading…
Reference in a new issue