diff options
author | Javier Sánchez Parra <jsanchez@soleta.eu> | 2021-12-17 13:14:46 +0100 |
---|---|---|
committer | Javier Sánchez Parra <jsanchez@soleta.eu> | 2021-12-17 13:24:00 +0100 |
commit | d12b401d304f0fbc57289ecf601e1a39aab6e624 (patch) | |
tree | a6759374e0e30e97830022f1e2defb6fb5713c95 /ogcp/views.py | |
parent | e07c8afcce3f16739bbf9e8c52405f327f367977 (diff) |
Add available ogLives to client details
Otherwise, ogLive field always shows the default value.
Diffstat (limited to 'ogcp/views.py')
-rw-r--r-- | ogcp/views.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/ogcp/views.py b/ogcp/views.py index 4f29f2f..c05511b 100644 --- a/ogcp/views.py +++ b/ogcp/views.py @@ -559,6 +559,12 @@ def action_client_info(): form.room.data = db_client['room'] form.boot.data = db_client['boot'] + r = g.server.get('/oglive/list') + available_oglives = r.json()['oglive'] + for oglive in available_oglives: + choice = (oglive.get('directory'), oglive.get('directory')) + form.livedir.choices.append(choice) + r = g.server.get('/mode') available_modes = [(mode, mode) for mode in r.json()['modes']] form.boot.choices = list(available_modes) |