Spaces:
Running
Running
File size: 477 Bytes
dbc8392 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
function getConfig() {
apiGet('/config/get')
.then(data => {
document.getElementById('config-json').value = JSON.stringify(data, null, 2);
})
.catch(err => console.error(err));
}
function updateConfig() {
const config = JSON.parse(document.getElementById('config-json').value);
apiPost('/config/update', config)
.then(data => showResult('config-result', data))
.catch(err => console.error(err));
}
|