aboutsummaryrefslogtreecommitdiff
path: root/qc_app
diff options
context:
space:
mode:
Diffstat (limited to 'qc_app')
-rw-r--r--qc_app/templates/insert_error.html28
-rw-r--r--qc_app/templates/insert_success.html15
-rw-r--r--qc_app/templates/stdout_output.html10
3 files changed, 53 insertions, 0 deletions
diff --git a/qc_app/templates/insert_error.html b/qc_app/templates/insert_error.html
new file mode 100644
index 0000000..56dd195
--- /dev/null
+++ b/qc_app/templates/insert_error.html
@@ -0,0 +1,28 @@
+{%extends "base.html"%}
+
+{%block title%}Data Insertion Failure{%endblock%}
+
+{%block contents%}
+<h1 class="heading">Insertion Failure</h1>
+
+<p>
+ There was an error inserting data into the database
+</p>
+
+<p>
+ Please notify the developers of this issue when you encounter it,
+ providing the information below.
+</p>
+
+<h4>Debugging Information</h4>
+
+<ul>
+ <li><strong>job id</strong>: {{job["job_id"]}}</li>
+</ul>
+
+<h4>STDERR Output</h4>
+<div class="cli-output">
+ {{job["stderr"]}}
+</div>
+
+{%endblock%}
diff --git a/qc_app/templates/insert_success.html b/qc_app/templates/insert_success.html
new file mode 100644
index 0000000..4406c66
--- /dev/null
+++ b/qc_app/templates/insert_success.html
@@ -0,0 +1,15 @@
+{%extends "base.html"%}
+{%from "stdout_output.html" import stdout_output%}
+
+{%block title%}Insertion Success{%endblock%}
+
+{%block contents%}
+<h1 class="heading">Insertion Success</h1>
+
+<p>Data inserted successfully!</p>
+
+<p>The following queries were run:</p>
+
+{{stdout_output(job)}}
+
+{%endblock%}
diff --git a/qc_app/templates/stdout_output.html b/qc_app/templates/stdout_output.html
new file mode 100644
index 0000000..f3fcde5
--- /dev/null
+++ b/qc_app/templates/stdout_output.html
@@ -0,0 +1,10 @@
+{%macro stdout_output(job)%}
+
+<h4>STDOUT Output</h4>
+<div class="cli-output">
+ {%for line in job.get("stdout", "").split("\n\n"):%}
+ <p>{{line}}</p>
+ {%endfor%}
+</div>
+
+{%endmacro%}