diff options
author | Parker Berberian <pberberian@iol.unh.edu> | 2020-01-30 13:33:35 -0500 |
---|---|---|
committer | Parker Berberian <pberberian@iol.unh.edu> | 2020-01-30 16:12:18 -0500 |
commit | 078273eb7db5a481a4131d44a943f3c9e34b6b88 (patch) | |
tree | 9e6e569e18712d77b8a65c6ebf4dda50ade1b55a /src/templates/base/dashboard/landing.html | |
parent | 899e1a4baa95d0bc6f0eef34de66f0e257174878 (diff) |
Adds Template Overrides
Changes the structure of the template directories to allow
a new project to define their own set of override templates
that inherit from a common base.
I have slightly modified landing.html here as an example.
In comming changes we will try to move all the "laas" specific
content into the laas directory
Change-Id: I46151be182de901f870debb247b305ea34ae77ba
Signed-off-by: Parker Berberian <pberberian@iol.unh.edu>
Diffstat (limited to 'src/templates/base/dashboard/landing.html')
-rw-r--r-- | src/templates/base/dashboard/landing.html | 77 |
1 files changed, 77 insertions, 0 deletions
diff --git a/src/templates/base/dashboard/landing.html b/src/templates/base/dashboard/landing.html new file mode 100644 index 0000000..9e45b09 --- /dev/null +++ b/src/templates/base/dashboard/landing.html @@ -0,0 +1,77 @@ +{% extends "base.html" %} +{% load staticfiles %} + +{% block content %} +<div class="text-center"> + {% if not request.user.is_anonymous %} + {% if not request.user.userprofile.ssh_public_key %} + <div class="alert alert-danger" role="alert"> + Warning: you need to upload an ssh key under <a href="/accounts/settings">account settings</a> if you wish to + log into the servers you book + </div> + {% endif %} + {% else %} + {% endif %} +</div> +{% csrf_token %} + +<div class="row"> + <!-- About us --> + <div class="col-12 col-lg-6 mb-4"> + <h2 class="border-bottom">About Us</h2> + {% block about_us %} + <p>Here is some information about us!</p> + {% endblock about_us %} + </div> + + <!-- Get started --> + <div class="col-12 col-lg-6 mb-4"> + <h2 class="border-bottom">Get Started</h2> + {% if request.user.is_anonymous %} + <h4 class="text-center"> + To get started, please log in with your <a href="/accounts/login">Linux Foundation Jira account</a> + </h4> + {% else %} + <p>To get started, book a server below:</p> + <a class="btn btn-primary btn-lg d-flex flex-column justify-content-center align-content-center border text-white p-4" + href="/booking/quick/"> + Book a Server + </a> + <p class="mt-4">PTLs can use our advanced options to book multi-node pods. If you are a PTL, you may use the options + below: + </p> + <div class="btn-group-vertical w-100"> + <button class="btn btn-primary" onclick="create_workflow(0)">Book a Pod</button> + <button class="btn btn-primary" onclick="create_workflow(1)">Design a Pod</button> + <button class="btn btn-primary" onclick="create_workflow(2)">Configure a Pod</button> + </div> + {% endif %} + </div> + + <!-- Returning users --> + {% if not request.user.is_anonymous %} + <div class="col-12 col-lg-6 offset-lg-6 mb-4 mt-lg-4"> + <h2 class="ht-4 border-bottom">Returning Users</h2> + <p>If you're a returning user, some of the following options may be of interest:</p> + <div class="btn-group-vertical w-100"> + <button class="btn btn-primary" onclick="create_workflow(3)">Snapshot a Host</button> + <a class="btn btn-primary" href="{% url 'account:my-bookings' %}"> + My Bookings + </a> + {% if manager == True %} + <button class="btn btn-primary" onclick="continue_workflow()"> + Resume Workflow + </button> + {% endif %} + </div> + </div> + {% endif %} +</div> + +<div class="hidden_form d-none" id="form_div"> + <form method="post" action="" class="form" id="wf_selection_form"> + {% csrf_token %} + </form> +</div> + +{% endblock content %} |