-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MVP v1. Admin, Student, Tutor dashboards created and tested
- Loading branch information
1 parent
e55296c
commit 10386b9
Showing
13 changed files
with
317 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<!-- Header --> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<link | ||
|
@@ -11,8 +12,11 @@ | |
<title>Iridium Tutoring</title> | ||
<meta name="viewport" content="width=device-width, initial-scale=1" /> | ||
</head> | ||
|
||
<!-- Body --> | ||
<body> | ||
{% load static %} | ||
|
||
<!-- Nav Bar--> | ||
<nav class="navbar navbar-expand-lg navbar-dark bg-dark"> | ||
<div class="container-fluid"> | ||
|
@@ -39,18 +43,18 @@ | |
<a class="nav-link active" aria-current="page" href="{% url 'tutoring_student:index' %}">Home</a> | ||
<a class="nav-link" href="{% url 'tutoring_student:studentView' %}">Student Portal</a> | ||
<a class="nav-link" href="{% url 'tutoring_student:tutorView' %}">Tutor Portal</a> | ||
<a class="nav-link" href="https://www.iridiumtutoring.org" | ||
>Back To Main Site</a | ||
> | ||
s | ||
</div> | ||
</div> | ||
<div class="nav navbar-nav ml-auto mr-0"> | ||
<a class="nav-link" href="https://www.iridiumtutoring.org">Back To Main Site</a> | ||
</div> | ||
</div> | ||
</nav> | ||
|
||
<!-- Form to create a new tutoring session --> | ||
<div class="container mt-3"> | ||
<h1 class="text-center">Register for a Tutoring Session</h1> | ||
<h1 class="text-center mt-5">Register for a Tutoring Session</h1> | ||
|
||
<div class="row justify-content-md-center"> | ||
<div class="col d-none d-md-block"></div> | ||
|
@@ -122,14 +126,26 @@ <h1 class="text-center">Register for a Tutoring Session</h1> | |
|
||
<div class="mb-3"> | ||
<label for="duration" class="form-label">Duration (hours)</label> | ||
<input | ||
{% comment %} <input | ||
type="number" | ||
name="duration" | ||
id="duration" | ||
class="form-control" | ||
value="{{duration}}" | ||
required | ||
/> | ||
/> {% endcomment %} | ||
<select | ||
name="duration" | ||
id="duration" | ||
class="form-select" | ||
type="number" | ||
value={{duration}} | ||
required | ||
> | ||
<option value="0.5">0.5</option> | ||
<option value="1">1</option> | ||
<option value="1.5">1.5</option> | ||
</select> | ||
<div id="durationHelp" class="form-text"> | ||
Most commonly, sessions are 0.5, 1, or 1.5 hours. | ||
</div> | ||
|
@@ -205,10 +221,22 @@ <h1 class="text-center">Register for a Tutoring Session</h1> | |
<div class="col d-none d-md-block"></div> | ||
</div> | ||
</div> | ||
|
||
<!-- Footer--> | ||
<footer class="bg-body-tertiary text-center"> | ||
<div class="container p-4"></div> | ||
<div class="text-center p-3" style="background-color: rgba(0, 0, 0, 0.05);"> | ||
© 2024 Copyright. | ||
<a class="text-body" href="https://www.iridiumtutoring.org/">iridiumtutoring.org</a> | ||
</div> | ||
</footer> | ||
</body> | ||
|
||
<!-- BootstrapJS --> | ||
<script | ||
src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" | ||
integrity="sha384-MrcW6ZMFYlzcLA8Nl+NtUVF0sA7MsXsP1UyJoMp4YLEuNSfAP+JcXn/tWtIaxVXM" | ||
crossorigin="anonymous" | ||
></script> | ||
|
||
</html> |
78 changes: 78 additions & 0 deletions
78
tutoring_student/templates/tutoring_student/session-student.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<link | ||
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" | ||
rel="stylesheet" | ||
integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" | ||
crossorigin="anonymous" | ||
/> | ||
<title>Iridium Tutoring</title> | ||
<meta name="viewport" content="width=device-width, initial-scale=1"> | ||
</head> | ||
<body> | ||
<!-- Nav Bar--> | ||
{% load static %} | ||
<nav class="navbar navbar-expand-lg navbar-dark bg-dark navbar-inverse"> | ||
<div class="container-fluid"> | ||
<a class="navbar-brand" href="https://www.iridiumtutoring.org"><img src="{% static 'tutoring_student/images/iridiumbannerheader.png' %}" class="img-fluid" style="height: 3rem" alt="Iridium Tutoring Logo" /></a> | ||
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNavAltMarkup" aria-controls="navbarNavAltMarkup" aria-expanded="false" aria-label="Toggle navigation"> | ||
<span class="navbar-toggler-icon"></span> | ||
</button> | ||
<div class="collapse navbar-collapse" id="navbarNavAltMarkup"> | ||
<div class="navbar-nav"> | ||
<a class="nav-link" href="{% url 'tutoring_student:index' %}">Home</a> | ||
<a class="nav-link active" aria-current="page" href="">Student Portal</a> | ||
</div> | ||
</div> | ||
|
||
<!-- Align with right side of navbar --> | ||
<div class="nav navbar-nav ml-auto mr-0"> | ||
{% if not user %} | ||
<a class="nav-link" href="https://www.iridiumtutoring.org">Back To Main Site</a> | ||
{% endif %} | ||
{% if user %} | ||
<a href="{% url 'tutoring_student:student_logout' %}"> | ||
<button class="btn btn-outline-light">Logout</button> | ||
</a> | ||
{% endif %} | ||
</div> | ||
</div> | ||
</nav> | ||
<!-- End Nav Bar--> | ||
<div class="container mt-lg-5"> | ||
{% if error_message %} | ||
<div class="alert alert-danger"> | ||
<h3>{{ error_message }}</h3> | ||
</div> | ||
{% if button %} | ||
<a class="btn btn-primary btn-lg" href="{% url 'tutoring_student:index' %}" role="button">Back to Home</a> | ||
{% endif %} | ||
{% else %} | ||
{% if tutoringSession %} | ||
<div class="jumbotron"> | ||
<h2 class="display-4">Thank you for registering, {{ tutoringSession.student.studentName }}!</h2> | ||
<p class="lead">Here are the details of your tutoring session:</p> | ||
<ul> | ||
<li><strong>Student:</strong> {{ tutoringSession.student.studentName }}</li> | ||
<li><strong>Subject:</strong> {{ tutoringSession.subject }} - {{ tutoringSession.description }}</li> | ||
<li><strong>Date:</strong> {{ tutoringSession.date }} - {{ tutoringSession.time }} ({{ tutoringSession.duration }} hours)</li> | ||
{% if tutoringSession.tutor %} | ||
<li><strong>Tutor:</strong> {{ tutoringSession.tutor.tutorName }} - <a href="mailto:{{tutoringSession.tutor.email}}">{{tutoringSession.tutor.email}}</a></li> | ||
{% endif %} | ||
</ul> | ||
{% if not tutoringSession.tutor %} | ||
<p class="lead">A tutor will reach out soon about the details of your session. If you have any questions, please contact us at <a href="mailto:[email protected]">[email protected]</a>.</p> | ||
{% else %} | ||
<p class="lead">{{tutoringSession.tutor.tutorName}} has signed up for your session and will reach out soon about the details of your session. If you have any questions, feel free to contact us at <a href="mailto:[email protected]">[email protected]</a>.</p> | ||
{% endif %} | ||
<a class="btn btn-primary btn-lg" href="{% url 'tutoring_student:studentView' %}" role="button">Go Back</a> | ||
</div> | ||
{% endif %} | ||
{% endif %} | ||
</div> | ||
</body> | ||
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-MrcW6ZMFYlzcLA8Nl+NtUVF0sA7MsXsP1UyJoMp4YLEuNSfAP+JcXn/tWtIaxVXM" crossorigin="anonymous"></script> | ||
|
||
</html> |
93 changes: 93 additions & 0 deletions
93
tutoring_student/templates/tutoring_student/session-tutor.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<link | ||
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" | ||
rel="stylesheet" | ||
integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" | ||
crossorigin="anonymous" | ||
/> | ||
<title>Iridium Tutoring</title> | ||
<meta name="viewport" content="width=device-width, initial-scale=1"> | ||
</head> | ||
<body> | ||
<!-- Nav Bar--> | ||
{% load static %} | ||
<nav class="navbar navbar-expand-lg navbar-dark bg-dark navbar-inverse"> | ||
<div class="container-fluid"> | ||
<a class="navbar-brand" href="https://www.iridiumtutoring.org"><img src="{% static 'tutoring_student/images/iridiumbannerheader.png' %}" class="img-fluid" style="height: 3rem" alt="Iridium Tutoring Logo" /></a> | ||
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNavAltMarkup" aria-controls="navbarNavAltMarkup" aria-expanded="false" aria-label="Toggle navigation"> | ||
<span class="navbar-toggler-icon"></span> | ||
</button> | ||
<div class="collapse navbar-collapse" id="navbarNavAltMarkup"> | ||
<div class="navbar-nav"> | ||
<a class="nav-link" href="{% url 'tutoring_student:index' %}">Home</a> | ||
<a class="nav-link active" aria-current="page" href="">Tutor Portal</a> | ||
</div> | ||
</div> | ||
|
||
<!-- Align with right side of navbar --> | ||
<div class="nav navbar-nav ml-auto mr-0"> | ||
{% if not user %} | ||
<a class="nav-link" href="https://www.iridiumtutoring.org">Back To Main Site</a> | ||
{% endif %} | ||
{% if user %} | ||
<a href="{% url 'tutoring_student:tutor_logout' %}"> | ||
<button class="btn btn-outline-light">Logout</button> | ||
</a> | ||
{% endif %} | ||
</div> | ||
</div> | ||
</nav> | ||
<!-- End Nav Bar--> | ||
<div class="container mt-lg-5"> | ||
{% if error_message %} | ||
<div class="alert alert-danger"> | ||
<h3>{{ error_message }}</h3> | ||
</div> | ||
{% if button %} | ||
<a class="btn btn-primary btn-lg" href="{% url 'tutoring_student:index' %}" role="button">Back to Home</a> | ||
{% endif %} | ||
{% else %} | ||
{% if tutoringSession %} | ||
<div class="jumbotron"> | ||
<h2 class="display-4">{{ tutoringSession.student.studentName }}'s registration</h2> | ||
<p class="lead">Here are the details of your {{ tutoringSession.student.studentName }}'s session:</p> | ||
<ul> | ||
<li><strong>Student:</strong> {{ tutoringSession.student.studentName }}</li> | ||
<li><strong>Email:</strong> <a href="mailto:{{tutoringSession.student.email}}">{{tutoringSession.student.email}}</a></li> | ||
{% if tutoringSession.student.phone %} | ||
<li><strong>Phone:</strong> {{ tutoringSession.student.phone }}</li> | ||
{% endif %} | ||
<li><strong>Subject:</strong> {{ tutoringSession.subject }} - {{ tutoringSession.description }}</li> | ||
<li><strong>Date:</strong> {{ tutoringSession.date }} - {{ tutoringSession.time }} ({{ tutoringSession.duration }} hours)</li> | ||
{% if tutoringSession.tutor %} | ||
<li><strong>Tutor:</strong> {{ tutoringSession.tutor.tutorName }} - <a href="mailto:{{tutoringSession.tutor.email}}">{{tutoringSession.tutor.email}}</a></li> | ||
{% endif %} | ||
</ul> | ||
{% if not tutoringSession.tutor %} | ||
<p class="lead">You may contact the student via their email of phone number to ask any additional questions about their request. If the student asks to change the time/topic, please contact an administrator to update the session accordingly. To claim this session, press the claim session button below and follow up with an email to the student.</p> | ||
<form method="post" action="{% url 'tutoring_student:session_details_tutor' tutoringSession.id%}"> | ||
{% csrf_token %} | ||
<input type="hidden" name="claim" value="True"> | ||
<button type="submit" class="btn btn-primary btn-lg" role="button">Claim Session</button> | ||
</form> | ||
{% elif tutoringSession.tutor.tutorName == tutor.tutorName and tutoringSession.tutor.email == tutor.email %} | ||
<form method="post" action="{% url 'tutoring_student:session_details_tutor' tutoringSession.id%}"> | ||
{% csrf_token %} | ||
<input type="hidden" name="claim" value="False"> | ||
<button type="submit" class="btn btn-primary btn-lg" role="button">Unclaim Session</button> | ||
</form> | ||
{% else %} | ||
<p class="lead">{{tutoringSession.tutor.tutorName}} has signed up for this session.</p> | ||
{% endif %} | ||
<a class="btn btn-secondary btn-lg mt-3" href="{% url 'tutoring_student:tutorView' %}" role="button">Go Back</a> | ||
</div> | ||
{% endif %} | ||
{% endif %} | ||
</div> | ||
</body> | ||
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-MrcW6ZMFYlzcLA8Nl+NtUVF0sA7MsXsP1UyJoMp4YLEuNSfAP+JcXn/tWtIaxVXM" crossorigin="anonymous"></script> | ||
|
||
</html> |
Oops, something went wrong.