test
All checks were successful
Deploy powerbar.ti Frontend Portal / Deploy-Tinance2-Frontend-Portal-Production (push) Successful in 36s
All checks were successful
Deploy powerbar.ti Frontend Portal / Deploy-Tinance2-Frontend-Portal-Production (push) Successful in 36s
This commit is contained in:
parent
9446e98087
commit
0fea3871c5
1 changed files with 1 additions and 0 deletions
|
@ -211,6 +211,7 @@ def powebar_group_action(group, action):
|
|||
for outlet in device['outlets']:
|
||||
if outlet in powerbars[powerbar]['outlets']:
|
||||
powerbars[powerbar]['outlets'][outlet]['state'] = action
|
||||
app.socketio.emit('power-event',{'powerbar': powerbar, 'outlet' : outlet, 'action' : action}, namespace='/powerupdates')
|
||||
print(f"Turned {action} powerbar {powerbar} outlet {outlet}")
|
||||
|
||||
return jsonify({'status': "200"})
|
||||
|
|
Loading…
Reference in a new issue