From 79aec84973032e15ae9d36fcbd7d7d42af3283d1 Mon Sep 17 00:00:00 2001 From: maxbr Date: Fri, 19 Aug 2016 17:10:31 +0200 Subject: Split the dashboard into different apps, add tests JIRA: RELENG-12 Signed-off-by: maxbr --- pharos-dashboard/templates/dashboard/base.html | 93 ---------------------- .../templates/dashboard/booking_calendar.html | 79 ------------------ pharos-dashboard/templates/dashboard/ci_pods.html | 58 ++++++++++++++ pharos-dashboard/templates/dashboard/dev_pods.html | 58 ++++++++++++++ .../templates/dashboard/jenkins_slaves.html | 42 ++++++++++ pharos-dashboard/templates/dashboard/table.html | 2 +- 6 files changed, 159 insertions(+), 173 deletions(-) delete mode 100644 pharos-dashboard/templates/dashboard/base.html delete mode 100644 pharos-dashboard/templates/dashboard/booking_calendar.html create mode 100644 pharos-dashboard/templates/dashboard/ci_pods.html create mode 100644 pharos-dashboard/templates/dashboard/dev_pods.html create mode 100644 pharos-dashboard/templates/dashboard/jenkins_slaves.html (limited to 'pharos-dashboard/templates/dashboard') diff --git a/pharos-dashboard/templates/dashboard/base.html b/pharos-dashboard/templates/dashboard/base.html deleted file mode 100644 index 544bf0b..0000000 --- a/pharos-dashboard/templates/dashboard/base.html +++ /dev/null @@ -1,93 +0,0 @@ -{% extends "layout/base.html" %} -{% load bootstrap3 %} - -{% block basecontent %} -
- - - - -
-
-
-

{{ title }}

-
- -
- - {% bootstrap_messages %} - - {% block content %} - - {% endblock content %} -
- -
- -{% endblock basecontent %} \ No newline at end of file diff --git a/pharos-dashboard/templates/dashboard/booking_calendar.html b/pharos-dashboard/templates/dashboard/booking_calendar.html deleted file mode 100644 index 0f6bece..0000000 --- a/pharos-dashboard/templates/dashboard/booking_calendar.html +++ /dev/null @@ -1,79 +0,0 @@ -{% extends "dashboard/base.html" %} -{% load staticfiles %} -{% load bootstrap3 %} - -{% block extrahead %} - - -{% endblock extrahead %} - -{% block content %} -
-
-
-
-
- Calendar -
-
-
-
-
- -
- -
-
- -
-
-
- Booking -
-
- {% bootstrap_form_errors form type='non_fields' %} - -
- {% csrf_token %} -
- {% bootstrap_field form.start_date_time addon_after='' %} -
-
- {% bootstrap_field form.end_date_time addon_after='' %} -
- {% bootstrap_field form.purpose %} - {{ form.booking_id }} - {% buttons %} - - - {% endbuttons %} -
- -
-
-
-
-{% endblock content %} - -{% block extrajs %} - - - - - - - - - -{% endblock extrajs %} \ No newline at end of file diff --git a/pharos-dashboard/templates/dashboard/ci_pods.html b/pharos-dashboard/templates/dashboard/ci_pods.html new file mode 100644 index 0000000..d3e5ff6 --- /dev/null +++ b/pharos-dashboard/templates/dashboard/ci_pods.html @@ -0,0 +1,58 @@ +{% extends "dashboard/table.html" %} +{% load staticfiles %} + +{% block table %} + + + Name + Slave Name + Status + Installer + Scenario + Branch + Job + + + + {% for pod in ci_pods %} + + + {{ pod.name }} + + + {{ pod.slavename }} + + + {{ pod.status }} + + + {{ pod.last_job.installer }} + + + {{ pod.last_job.scenario }} + + + {{ pod.last_job.branch }} + + {{ pod.last_job.name }} + + + {% endfor %}` + +{% endblock table %} + + +{% block tablejs %} + +{% endblock tablejs %} \ No newline at end of file diff --git a/pharos-dashboard/templates/dashboard/dev_pods.html b/pharos-dashboard/templates/dashboard/dev_pods.html new file mode 100644 index 0000000..f08e1d1 --- /dev/null +++ b/pharos-dashboard/templates/dashboard/dev_pods.html @@ -0,0 +1,58 @@ +{% extends "dashboard/table.html" %} +{% load staticfiles %} + +{% block table %} + + + Name + Slave Name + Booked by + Booked until + Purpose + Status + + + + + {% for resource in dev_pods %} + + + {{ resource.name }} + + + {{ resource.slavename }} + + + {{ resource.current_booking.user.username }} + + + {{ resource.current_booking.end }} + + + {{ resource.current_booking.purpose }} + + + {{ resource.status }} + + + + Book + + + + {% endfor %} + +{% endblock table %} + +{% block tablejs %} + +{% endblock tablejs %} \ No newline at end of file diff --git a/pharos-dashboard/templates/dashboard/jenkins_slaves.html b/pharos-dashboard/templates/dashboard/jenkins_slaves.html new file mode 100644 index 0000000..2d011b4 --- /dev/null +++ b/pharos-dashboard/templates/dashboard/jenkins_slaves.html @@ -0,0 +1,42 @@ +{% extends "dashboard/table.html" %} +{% load staticfiles %} + +{% block table %} + + + Slave name + Status + Job + + + + {% for slave in slaves %} + + {{ slave.displayName }} + + + {{ slave.status }} + + + {{ slave.last_job.name }} + + + {% endfor %} + +{% endblock table %} + + +{% block tablejs %} + +{% endblock tablejs %} \ No newline at end of file diff --git a/pharos-dashboard/templates/dashboard/table.html b/pharos-dashboard/templates/dashboard/table.html index 2d0b82e..addd5c1 100644 --- a/pharos-dashboard/templates/dashboard/table.html +++ b/pharos-dashboard/templates/dashboard/table.html @@ -1,4 +1,4 @@ -{% extends "dashboard/base.html" %} +{% extends "base.html" %} {% load staticfiles %} {% block extrahead %} -- cgit 1.2.3-korg