diff --git a/src/templates/base.html b/src/templates/base.html index d441fab..337174a 100644 --- a/src/templates/base.html +++ b/src/templates/base.html @@ -22,6 +22,16 @@ Webcam + + + @@ -45,7 +55,6 @@ {% endif %} {% endwith %} - {% block content %} @@ -57,5 +66,6 @@ + diff --git a/src/templates/queue.html b/src/templates/queue.html new file mode 100644 index 0000000..619c2a9 --- /dev/null +++ b/src/templates/queue.html @@ -0,0 +1,47 @@ +{% extends 'base.html' %} + +{% block content %} + +

Worker state : {{ worker_state.state }}

+ +

Current tasks

+
+{% if not tasks %} + +{% endif %} +
+ {% for task in tasks %} +
+
+ {% if task.type == "TaskType.IMAGE" %} + {% set img_path = task.content.img.split('/')[-1] %} + Image could not be loaded + {% endif %} + {% if task.type == "TaskType.CUT" %} + Image could not be loaded + {% endif %} +
+ {% if task.type == "TaskType.TEXT" %} +

ID : {{ task.content.txt }}

+ {% endif %} + +

ID : {{ task.task_id }}

+
+
+
+ {% endfor %} +
+
+

Completed tasks

+
+ +{% if not completed_tasks %} + +{% endif %} + +{% for task in completed_tasks %} + +{% endfor %} + + +{% endblock %} \ No newline at end of file