mirror of
https://github.com/lrnselfreliance/wrolpi.git
synced 2026-10-26 19:01:39 -04:00
controller: Desktop start/stop toggle; rename hotspot/bluetooth actions to what they do
Add a Desktop toggle to the Controller (both UIs) that starts/stops display-manager.service. Fail open: the unit is never enabled/disabled, so the desktop always returns on reboot; users who want it disabled across reboots can set the default target themselves. Rename the hotspot and bluetooth actions to reflect their real behavior: - enable/disable_hotspot -> start/stop_hotspot (/api/hotspot/start|stop) - enable/disable_bluetooth -> unblock/block_bluetooth (rfkill semantics, /api/bluetooth/unblock|block) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
parent
a4eeba14ee
commit
3e559e1bf8
14 changed files with 712 additions and 132 deletions
|
|
@ -92,12 +92,12 @@ export async function updateHotspotSettings(settings) {
|
|||
return controllerFetch('/hotspot/settings', {method: 'POST', body: JSON.stringify(settings)});
|
||||
}
|
||||
|
||||
export async function enableHotspot() {
|
||||
return controllerFetch('/hotspot/enable', {method: 'POST'});
|
||||
export async function startHotspot() {
|
||||
return controllerFetch('/hotspot/start', {method: 'POST'});
|
||||
}
|
||||
|
||||
export async function disableHotspot() {
|
||||
return controllerFetch('/hotspot/disable', {method: 'POST'});
|
||||
export async function stopHotspot() {
|
||||
return controllerFetch('/hotspot/stop', {method: 'POST'});
|
||||
}
|
||||
|
||||
export async function getThrottleStatus() {
|
||||
|
|
@ -116,12 +116,24 @@ export async function getBluetoothStatus() {
|
|||
return controllerFetch('/bluetooth/status');
|
||||
}
|
||||
|
||||
export async function enableBluetooth() {
|
||||
return controllerFetch('/bluetooth/enable', {method: 'POST'});
|
||||
export async function unblockBluetooth() {
|
||||
return controllerFetch('/bluetooth/unblock', {method: 'POST'});
|
||||
}
|
||||
|
||||
export async function disableBluetooth() {
|
||||
return controllerFetch('/bluetooth/disable', {method: 'POST'});
|
||||
export async function blockBluetooth() {
|
||||
return controllerFetch('/bluetooth/block', {method: 'POST'});
|
||||
}
|
||||
|
||||
export async function getDesktopStatus() {
|
||||
return controllerFetch('/desktop/status');
|
||||
}
|
||||
|
||||
export async function startDesktop() {
|
||||
return controllerFetch('/desktop/start', {method: 'POST'});
|
||||
}
|
||||
|
||||
export async function stopDesktop() {
|
||||
return controllerFetch('/desktop/stop', {method: 'POST'});
|
||||
}
|
||||
|
||||
// --- Samba Endpoints ---
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue