new gui messages

parent 50c49d00
......@@ -80,7 +80,7 @@ import time
import json
import uuid
API_VERSION = '0.1.72'
API_VERSION = '0.1.73'
# TODO use metaclasses instead?
......@@ -525,7 +525,7 @@ class MsgUiRequestTextInput(Message):
_msg_data_template = {
"_type": "ui.message.type.to.be.deprecated",
"tags": [],
"tags": {},
"fields": [
{
"name": "input_name",
......@@ -549,7 +549,7 @@ class MsgUiRequestConfirmationButton(Message):
_msg_data_template = {
"_type": "ui.message.type.to.be.deprecated",
"tags": [],
"tags": {},
"fields": [
{
"name": "test_button",
......@@ -559,6 +559,117 @@ class MsgUiRequestConfirmationButton(Message):
]
}
class MsgUiRequestQuestionRadio(Message):
"""
Requirements: ...
Type: Event
Pub/Sub: TT -> UI
Description: Message for requesting confirmation button
"""
routing_key = "ui.user.all.request"
_msg_data_template = {
"_type": "ui.message.type.to.be.deprecated",
"tags": {},
"fields": [
{
"name": "True",
"type": "radio",
"value": True
},
{
"name": "False",
"type": "radio",
"value": False
},
]
}
class MsgUiRequestQuestionCheckbox(Message):
"""
Requirements: ...
Type: Event
Pub/Sub: TT -> UI
Description: Message for requesting confirmation button
"""
routing_key = "ui.user.all.request"
_msg_data_template = {
"_type": "ui.message.type.to.be.deprecated",
"tags": {},
"fields": [
{
"name": "Choice1",
"label": "Choice1",
"type": "checkbox",
"value": 0
},
{
"name": "Choice2",
"label": "Choice2",
"type": "checkbox",
"value": 1
},
]
}
class MsgUiRequestQuestionSelect(Message):
"""
Requirements: ...
Type: Event
Pub/Sub: TT -> UI
Description: Message for requesting confirmation button
"""
routing_key = "ui.user.all.request"
_msg_data_template = {
"_type": "ui.message.type.to.be.deprecated",
"tags": {},
"fields": [
{
"name": "ideal_select",
"type": "select",
"options": [
{"label": "choice 1", "value": 1 },
{"label": "choice 2", "value": 2 },
{"label": "choice 3", "value": 3 },
],
"value": 1
}
]
}
class MsgUiRequestUploadFile(Message):
"""
Requirements: ...
Type: Event
Pub/Sub: TT -> UI
Description: Message for requesting confirmation button
"""
routing_key = "ui.user.all.request"
_msg_data_template = {
"_type": "ui.message.type.to.be.deprecated",
"tags": {},
"fields": [
{
"name": "upload a file",
"type": "file"
}
]
}
class MsgUiRequestSessionConfiguration(Message):
"""
......@@ -592,7 +703,7 @@ class MsgUiDisplay(Message):
_msg_data_template = {
"_type": "ui.message.type.to.be.deprecated",
"level": None,
"tags": [],
"tags": {},
"fields": [
{
"type": "p",
......@@ -617,7 +728,7 @@ class MsgUiDisplayMarkdownText(Message):
_msg_data_template = {
"_type": "ui.message.type.to.be.deprecated",
"level": None,
"tags": [],
"tags": {},
"fields": [
{
"type": "p",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment