quagga plugin refactor
This commit is contained in:
parent
bd4c7b25c4
commit
5ed9abb12f
|
|
@ -29,7 +29,7 @@ class Config implements ArrayAccess
|
|||
|
||||
public function save(): void
|
||||
{
|
||||
file_put_contents($this->path, json_encode($this->data));
|
||||
file_put_contents($this->path, json_encode($this->data,JSON_PRETTY_PRINT));
|
||||
}
|
||||
|
||||
private mixed $data = [];
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
import {App} from "/assets/App.js";
|
||||
(async function () {
|
||||
$("#buttons").append(`<button id="restart-quagga">Restart quagga</button>`);
|
||||
$("#restart-quagga").click(function () {
|
||||
|
|
@ -6,7 +7,7 @@
|
|||
self.prop("disabled", true);
|
||||
(async function () {
|
||||
try {
|
||||
alert(await JSONRPC.__invoke("restart_quagga"));
|
||||
alert(await App.RPC.__invoke("quagga::restart"));
|
||||
} finally {
|
||||
setTimeout(() => {
|
||||
self.prop("disabled", false);
|
||||
|
|
|
|||
Loading…
Reference in New Issue