Add new reboot option and restart lamassu-browser
This commit is contained in:
parent
371454b6d4
commit
9f8693a33e
6 changed files with 89 additions and 5 deletions
|
|
@ -71,11 +71,16 @@ function reboot (rec) {
|
|||
return axios.post(`http://localhost:3030/reboot?device_id=${rec.deviceId}`)
|
||||
}
|
||||
|
||||
function restartServices (rec) {
|
||||
return axios.post(`http://localhost:3030/restartServices?device_id=${rec.deviceId}`)
|
||||
}
|
||||
|
||||
function setMachine (rec) {
|
||||
switch (rec.action) {
|
||||
case 'resetCashOutBills': return resetCashOutBills(rec)
|
||||
case 'unpair': return unpair(rec)
|
||||
case 'reboot': return reboot(rec)
|
||||
case 'restartServices': return restartServices(rec)
|
||||
default: throw new Error('No such action: ' + rec.action)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue