diff options
author | Justin Choquette <jchoquette@iol.unh.edu> | 2023-08-07 14:10:19 -0400 |
---|---|---|
committer | Justin Choquette <jchoquette@iol.unh.edu> | 2023-08-07 14:16:04 -0400 |
commit | a6168306c08e8d5b207b9acc48869180d194ff01 (patch) | |
tree | 51ffcafac4ae0b5fd4da363d9bf839e8ad3fc286 /src/templates/base/workflow | |
parent | a09db9f287a02873c0226759f8ea444bb304cd59 (diff) |
User subsystem
Change-Id: Ibef4ede9b2d6a3ea465f79a9b5cbcc821afbccae
Signed-off-by: Justin Choquette <jchoquette@iol.unh.edu>
Diffstat (limited to 'src/templates/base/workflow')
-rw-r--r-- | src/templates/base/workflow/book_a_pod.html | 57 | ||||
-rw-r--r-- | src/templates/base/workflow/design_a_pod.html | 23 |
2 files changed, 73 insertions, 7 deletions
diff --git a/src/templates/base/workflow/book_a_pod.html b/src/templates/base/workflow/book_a_pod.html index 7053bfd..7448dc5 100644 --- a/src/templates/base/workflow/book_a_pod.html +++ b/src/templates/base/workflow/book_a_pod.html @@ -98,7 +98,7 @@ </div> </div> <div class="row align-items-center mt-5"> - <button class="btn btn-danger cancel-book-button p-0 mr-2 col-xl-2 col-md-3 col-5" onclick="workflow.onclickCancel()">Cancel</button> + <!-- <button class="btn btn-danger cancel-book-button p-0 mr-2 col-xl-2 col-md-3 col-5" onclick="workflow.onclickCancel()">Cancel</button> --> <button class="btn btn-success cancel-book-button p-0 ml-2 col-xl-2 col-md-3 col-5" onclick="workflow.onclickConfirm()">Book</button> </div> </div> @@ -111,11 +111,60 @@ {% csrf_token %} </form> </div> + +<div class="modal fade" id="ipa-modal" tabindex="-1"> + <div class="modal-dialog modal-xl"> + <div class="modal-content"> + <div class="modal-header"> + <h5 class="modal-title">Welcome to LaaS 3.0</h5> + <button class="close" onclick="window.location.href = '../../'"><span aria-hidden="true">×</span></button> + </div> + <div class="modal-body" id="add_resource_modal_body"> + <p>Please update your information before creating a booking.</p> + <form action="{{prereq_validator.action}}" method="post"> + {% csrf_token %} + {{ prereq_validator.form }} + <div class="form-group"> + <input class="btn btn-success" name="submitButton" type="submit" value="Save"> + </div> + </form> + </div> + </div> + </div> +</div> + +<!-- Alert Modal --> +<div class="modal fade" id="alert_modal" tabindex="-1"> + <div class="modal-dialog modal-sm"> + <div class="modal-content"> + <div class="modal-header"> + <button class="close" data-dismiss="modal"><span aria-hidden="true">×</span></button> + </div> + <div class="modal-body text-center"> + <h5 id="alert_modal_message"></h5> + </div> + <div class="modal-footer d-flex justify-content-center"> + <button class="btn btn-success" data-dismiss="modal" id="alert-modal-submit" onclick="">Confirm</button> + </div> + </div> + </div> +</div> </body> <script> - const user = "{{user}}" - const workflow = new BookingWorkflow(); - workflow.startWorkflow(); + let user; + let workflow; + $(window).on('load', function() { + if ({{prereq_validator.exists}}) { + $('#ipa-modal').modal({backdrop: 'static', keyboard: false}); + $('#ipa-modal').modal('show'); + } else { + user = "{{user}}" + workflow = new BookingWorkflow(); + workflow.startWorkflow(); + } + }); + + </script> {% endblock %} diff --git a/src/templates/base/workflow/design_a_pod.html b/src/templates/base/workflow/design_a_pod.html index 5d48273..ab3f11b 100644 --- a/src/templates/base/workflow/design_a_pod.html +++ b/src/templates/base/workflow/design_a_pod.html @@ -83,14 +83,14 @@ <textarea id="pod-desc-input" class="form-control form-control-lg border border-dark pt-3 pl-3" rows="5" placeholder="Pod Description"></textarea> </div> </div> - <div class="row align-items-center my-4"> + <!-- <div class="row align-items-center my-4"> <div class="col-xl-6 col-md-8 col-11"> <div class="custom-control custom-switch"> <input type="checkbox" class="custom-control-input" id="pod-public-input"> <label class="custom-control-label" for="pod-public-input">Make pod template public?</label> </div> </div> - </div> + </div> --> <div class="row align-items-center my-4"> <div class="col-xl-6 col-md-8 col-11"> <span id="pod_details_error" class="text-danger"></span> @@ -120,7 +120,7 @@ </div> </div> <div class="row align-items-center mt-5"> - <div class="col-xl-2 col-md-3 col-5"><button class="btn btn-danger cancel-book-button p-0 w-100" onclick="workflow.onclickDiscardTemplate()">Discard</button></div> + <!-- <div class="col-xl-2 col-md-3 col-5"><button class="btn btn-danger cancel-book-button p-0 w-100" onclick="workflow.onclickDiscardTemplate()">Discard</button></div> --> <div class="col-xl-2 col-md-3 col-5"><button class="btn btn-success cancel-book-button p-0 w-100" onclick = "workflow.onclickSubmitTemplate()">Create</button></div> </div> </div> @@ -197,6 +197,23 @@ </div> </div> +<!-- Alert Modal --> +<div class="modal fade" id="alert_modal" tabindex="-1"> + <div class="modal-dialog modal-sm"> + <div class="modal-content"> + <div class="modal-header"> + <button class="close" data-dismiss="modal"><span aria-hidden="true">×</span></button> + </div> + <div class="modal-body text-center"> + <h5 id="alert_modal_message"></h5> + </div> + <div class="modal-footer d-flex justify-content-center"> + <button class="btn btn-success" data-dismiss="modal" id="alert-modal-submit" onclick="">Confirm</button> + </div> + </div> + </div> +</div> + <div class="hidden_form d-none"> <form id="token"> {% csrf_token %} |