Skip to content

Commit

Permalink
Stanford template override stuff (#2607)
Browse files Browse the repository at this point in the history
* First pass of Stanford template overrides

* teacherbio changes

* userview_class_entry changes

* student_schedule changes

* https fix

* event_signup changes

* profiles changes

* some things don't transfer to other themes

* manageclass tweaks

* Revert teacher event signup

* Changes for review
  • Loading branch information
willgearty authored Apr 17, 2019
1 parent 6fe04eb commit 09ff26d
Show file tree
Hide file tree
Showing 28 changed files with 124 additions and 65 deletions.
2 changes: 1 addition & 1 deletion esp/public/media/default_styles/availability.css
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ td.group, table.group {
.wrap th {
text-align: center !important;
font-weight: bold !important;
background: #EFEFEF !important;
background: #CCCCCC !important;
padding: 3px !important;
height: 80px !important;
width: 75px !important;
Expand Down
6 changes: 3 additions & 3 deletions esp/templates/program/modules/adminclass/manageclass.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{% extends "main.html" %}

{% block title %}Manage Class: {{ class.title }}{% endblock %}
{% block title %}Manage Class: {{ class.emailcode }}{% endblock %}

{% block stylesheets %}
{{ block.super }}
Expand All @@ -16,7 +16,7 @@

<div id="divmaintext">

<h1>Manage Class {{ class.id }}: {{ class.title }}</h1>
<h1>Manage Class {{ class.emailcode }}: {{ class.title }}</h1>

<div id="program_form">

Expand Down Expand Up @@ -172,7 +172,7 @@ <h1>Manage Class {{ class.id }}: {{ class.title }}</h1>
None requested
{% else %}
{% for rr in form.sec.getResourceRequests %}
{{ rr.res_type.name }} <br />
{{ rr.res_type.name }}: {{ rr.desired_value }}<br />
{% endfor %}
{% endif %}
</td>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<tr>
<th class="smaller">Teachers:</th>
<td>{% for teacher in class.get_teachers %}<a href="/manage/userview?username={{ teacher.username|urlencode }}">{{ teacher.nonblank_name }}</a>{% if not forloop.last %}, {% endif %}{% endfor %}
<td>{% for teacher in class.get_teachers %}<a href="/manage/userview?username={{ teacher.username|urlencode }}">{{ teacher.nonblank_name }}</a> (<a href="mailto:{{teacher.email}}" target="_blank">{{teacher.email}}</a>)<br/>{% endfor %}
<br />
<a href="/manage/{{ program.getUrlBase }}/coteachers?clsid={{ class.id }}">
Edit Teacher List </a>
Expand Down Expand Up @@ -32,6 +32,14 @@
{{ class.prereqs }}
</td>
</tr>
{% if class.class_style %}
<tr>
<th class="smaller">Class Format:</th>
<td>
{{ class.class_style }}
</td>
</tr>
{% endif %}
<tr>
<th class="smaller">Room Request:</th>
<td>
Expand All @@ -50,3 +58,11 @@
{{ class.message_for_directors }}
</td>
</tr>
<tr>
<th class="smaller">Resource Requests:</th>
<td>
{% for r in class.sections.all.0.resourcerequest_set.all %}
{{ r.res_type.name }}: {{ r.desired_value }}<br/>
{% endfor %}
</td>
</tr>
4 changes: 2 additions & 2 deletions esp/templates/program/modules/admincore/returnlink.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
<br />
<p>
{% if prog %}
<a class="btn" href="/manage/{{ prog.getUrlBase }}/main">Return to the main program management page</a>
<a class="btn btn-primary" href="/manage/{{ prog.getUrlBase }}/main">Return to the main program management page</a>
{% else %}
{% if program %}
<a class="btn" href="/manage/{{ program.getUrlBase }}/main">Return to the main program management page</a>
<a class="btn btn-primary" href="/manage/{{ program.getUrlBase }}/main">Return to the main program management page</a>
{% endif %}
{% endif %}
</p>
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
<th class="smaller">Sections:</th>
<td>
{{class.sections.count}}
({% for section in class.get_sections %}{{section.duration}} hrs{% if not forloop.last %}, {% endif%}{% endfor %})
</td>
</tr>
<tr>
Expand All @@ -25,14 +24,10 @@
{% endif %}
</td>
</tr>
<tr>
<th class="smaller">Duration:</th>
<td>{{class.prettyDuration}}</td>
</tr>
{% include "program/modules/adminclass/manageclass_class_info.html" %}
<tr>
<th class="smaller">Resource requests:</th>
<td>
{% for r in class.sections.all.0.resourcerequest_set.all %}
{{ r }} <br/>
{% endfor %}
</td>
</tr>
</tbody>
</table>
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ <h2>Introduction</h2>
{% else %}
<input type="submit" class="button" name="submitform" value="Complete" />
{% endif %}
&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<input type="submit" class="button" name="submitform" value="Save Progress" />
</th>
</tr>
Expand Down
2 changes: 1 addition & 1 deletion esp/templates/program/modules/nametagmodule/ids.html
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@
{% endfor %}

<script>
textFit(document.getElementsByClassName('name'));
textFit(document.getElementsByClassName('name'), {minFontSize:10, maxFontSize: 40});
</script>
</body>
</html>
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ <h2>
<form action="#" method="POST">
<!--<b>Specify Role Name for Winners: </b>--><input type="hidden" name="rolename" value="{{role}}"></br></br>
<input type="checkbox" name="confirm"> I confirm that I would like to run the student lottery.</br></br>
<input type="submit" value="Run Student Lottery" />
<input type="submit" style="float:none" value="Run Student Lottery" />
</form>
</center>

Expand Down
4 changes: 4 additions & 0 deletions esp/templates/program/modules/studentregphasezero/submit.html
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@
.option:hover {
background-color: #edf3ff;
}

.button {
float: none !important;
}
</style>
{% endblock %}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,16 @@

<h1>Setting Coteachers for &quot;<u>{{ class|escape }}</u>&quot;</h1>

<p>Please list all others that will be helping you teach this class. They will need to create accounts and mark their available times through the teacher registration page (for scheduling purposes).</p>
<h2>To add a co-teacher, please follow these steps:</h2>
<ol>
<li>Have your co-teacher register a teacher account on our website (if they do not have one already).</li>

<li>Have your co-teacher update their teacher profile at <a href="/teach/{{ program.getUrlBase }}/profile">this page</a>.</li>

<li>Have your co-teacher update their availability for {{ program.name }} at <a href="/teach/{{ program.getUrlBase }}/availability">this page</a>. Please make sure that your co-teacher and you share an overlapping schedule that is able to cover the entire duration of your class(es) that you are co-teaching.</li>

<li>Finally, return to this co-teachers page and add your co-teacher using the tool below.</li>
</ol>

{% if conflict %}
<p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

<div id="battlescreen">

<table cellpadding="4" cellspacing="0" align="center">
<table cellpadding="4" cellspacing="0" align="center" style="border-collapse: separate !important">
<tr>
<th colspan="7">
Choose a class to import
Expand Down
11 changes: 6 additions & 5 deletions esp/templates/program/modules/teachereventsmodule/event_row.html
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
{% for timeslot in timeslots %}
<tr>
<td>{{ timeslot.start|date:"D, M j f A" }}</td>
<td>{{ timeslot.end|date:"f A" }}</td>
<td>
<tr class="trs">
<td class="desc" style="width:25%">{{ timeslot.description }}</td>
<td style="width:18%">{{ timeslot.start|date:"D, M j f A" }}</td>
<td style="width:7%">{{ timeslot.end|date:"f A" }}</td>
<td style="width:45%">
{% if timeslot.teachers %}
{{ timeslot.teachers|join:",<br />" }}
{% else %}
<em>(None)</em>
{% endif %}
</td>
<td>
<td style="width:5%">
<form method="post" action="teacher_events">
<input type="hidden" name="id" value="{{ timeslot.id }}" />
<input type="hidden" name="command" value="delete" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@
{% block stylesheets %}
{{ block.super }}
<link rel="stylesheet" href="/media/styles/forms.css" type="text/css" />
<style>
.trs:not(:last-child) {
border-bottom: 1px dashed grey !important;
}
</style>
{% endblock %}

{% block content %}
Expand All @@ -21,18 +26,24 @@ <h1>Manage Teacher Events for {{ prog.niceName }}</h1>
<table align="center" cellpadding="0" cellspacing="0" width="450">
<tr><th colspan="2" class="small">Add a Training or Interview</th></tr>
{{ timeslot_form }}
<tr><td colspan="2" align="center"><input class="fancybutton" type="submit" name = "submit" value="Add Training" /> <input class="fancybutton" type="submit" name="submit" value="Add Interview" /></td></tr>
<tr><td colspan="2" align="center"><input class="btn btn-primary" type="submit" name = "submit" value="Add Training" /> <input class="btn btn-primary" type="submit" name="submit" value="Add Interview" /></td></tr>
</table>
</form>

<center>Training Session Descriptions can be edited <a href="/admin/cal/event/">here</a>.</center>
</br></br>

<table align="center" cellpadding="4" cellspacing="0">
<tr><th colspan="4"><a name="interviews"></a>Interviews</th></tr>
<tr><th>Start</th><th>End</th><th>Teachers</th><th>Delete</th></tr>
<tr><th colspan="5"><a name="interview"></a>Teacher Interviews</th></tr>
<tr><th style="width:25%">Description</th><th style="width:18%">Start</th><th style="width:7%">End</th><th style="width:45%">Teachers</th><th style="width:5%">Delete</th></tr>
{% with interview_times as timeslots %}
{% include "program/modules/teachereventsmodule/event_row.html" %}
{% endwith %}
<tr><th colspan="4"><a name="training"></a>Teacher Training</th></tr>
<tr><th>Start</th><th>End</th><th>Teachers</th><th>Delete</th></tr>
</table>
<br><br>
<table align="center" cellpadding="4" cellspacing="0">
<tr><th colspan="5"><a name="training"></a>Teacher Training</th></tr>
<tr><th style="width:25%">Description</th><th style="width:18%">Start</th><th style="width:7%">End</th><th style="width:45%">Teachers</th><th style="width:5%">Delete</th></tr>
{% with training_times as timeslots %}
{% include "program/modules/teachereventsmodule/event_row.html" %}
{% endwith %}
Expand Down
8 changes: 4 additions & 4 deletions esp/templates/program/modules/teacherregcore/returnlink.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<p>
</br></br><p>
{% if prog %}
<a href="/teach/{{ prog.getUrlBase }}/teacherreg">Click here</a> to return to the main teacher registration page.
<a class="btn btn-primary" href="/teach/{{ prog.getUrlBase }}/teacherreg">Return to the main teacher registration page</a>
{% else %}
{% if program %}
<a href="/teach/{{ program.getUrlBase }}/teacherreg">Click here</a> to return to the main teacher registration page.
<a class="btn btn-primary" href="/teach/{{ program.getUrlBase }}/teacherreg">Return to the main teacher registration page</a>
{% endif %}
{% endif %}
</p>
</p>
4 changes: 2 additions & 2 deletions esp/templates/program/receipts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
{% block title %}Registration Receipt for {{ program.niceName }}{% endblock %}
{% block body %}

Your class selections and any other information you entered have been saved. Be on the lookout for emails from the organizers for more details about {{ program.niceName }}. We will also post any updates on our Web site!
Your class selections and any other information you entered have been saved. Be on the lookout for emails from the organizers for more details about {{ program.niceName }}. We will also post any updates on our website!

<br />
<hr size="1" color="#000000" />
Expand Down Expand Up @@ -50,7 +50,7 @@
{% if not forloop.last %}<br />{% endif %}
{% endfor %}
{% if timeslot.1|length_is:0 %}
No classes
No classes selected
{% endif %}
</td>
</tr>
Expand Down
2 changes: 1 addition & 1 deletion esp/templates/qsd/qsd.html
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@
{% autoescape off %}{% render_qsd qsdrec %}{% endautoescape %}

<div class="qsd_bits hidden">
<a href="{{ edit_url }}">Edit this page</a>
<a class="btn btn-primary" href="{{ edit_url }}">Edit this page</a>
</div>
{% endblock %}
2 changes: 1 addition & 1 deletion esp/templates/survey/questions/checkboxes.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<div style="padding-left:2em; text-indent:-2em;">
<input type="checkbox" name="question_{{ id }}{% if for_class %}_{% templatetag openvariable %} id {% templatetag closevariable %}{% endif %}"
id="question_{{ id }}{% if for_class %}_{% templatetag openvariable %} id {% templatetag closevariable %}{% endif %}_{{ choice|slugify }}" value="{{ choice }}" />
<label for="question_{{ id }}{% if for_class %}_{% templatetag openvariable %} id {% templatetag closevariable %}{% endif %}_{{ choice|slugify }}">{{ choice }}</label>
<label for="question_{{ id }}{% if for_class %}_{% templatetag openvariable %} id {% templatetag closevariable %}{% endif %}_{{ choice|slugify }}" class="no_float">{{ choice }}</label>
</div>
{% endfor %}
</td>
Expand Down
2 changes: 1 addition & 1 deletion esp/templates/survey/questions/multiple_choice.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<div style="padding-left:2em; text-indent:-2em;">
<input type="radio" name="question_{{ id }}{% if for_class %}_{% templatetag openvariable %} id {% templatetag closevariable %}{% endif %}"
id="question_{{ id }}{% if for_class %}_{% templatetag openvariable %} id {% templatetag closevariable %}{% endif %}_{{ choice|slugify }}" value="{{ choice }}" />
<label for="question_{{ id }}{% if for_class %}_{% templatetag openvariable %} id {% templatetag closevariable %}{% endif %}_{{ choice|slugify }}">{{ choice }}</label>
<label for="question_{{ id }}{% if for_class %}_{% templatetag openvariable %} id {% templatetag closevariable %}{% endif %}_{{ choice|slugify }}" class="no_float">{{ choice }}</label>
</div>
{% endfor %}
</td>
Expand Down
2 changes: 1 addition & 1 deletion esp/templates/survey/survey.html
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ <h1>Survey for {{ program.niceName }} </h1>
{% for sec in sections %}
<table class="fullwidth">
<tr>
<th>Questions for {{ sec.emailcode }}: {{ sec.title }}</th>
<th>Questions for {{ sec.emailcode }}: {{ sec.title }} ({% for tm in sec.friendly_times %}{% if forloop.counter > 1 %},{% endif %}{{ tm }}{% endfor %})</th>
</tr>
</table>
{% for question in perclass_questions %}
Expand Down
8 changes: 6 additions & 2 deletions esp/templates/users/profile.html
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ <h1>Your Profile Information</h1>
<div class="span12 offset1">
{% load render_qsd %}
{% inline_qsd_block "account_creation_basic_info" %}
<p>First, please tell us a bit about yourself! The fields in red boxes are required. After you have filled out everything, click the "update" button at the bottom of the page to continue.</p>
<p>First, please tell us a bit about yourself! The fields with red asterisks are required. After you have filled out everything, click the "update" button at the bottom of the page to continue.</p>

<p>E-mail addresses have a tendency to change regularly, so we are asking that you re-enter your e-mail address each time you visit this form. Please take the time to also correct any other information that may be old or incorrect. Thanks!</p>
{% end_inline_qsd_block %}
Expand All @@ -45,7 +45,6 @@ <h4 style="color:red">Please fix the following error{{ form.errors|pluralize }}
<input type="hidden" name="profile_page" value="true" />
<input type="hidden" name="current_role" value="{{ profiletype }}" />


{% ifequal profiletype "student" %}
{% include "users/profiles/usercontact.html" %}
{% include "users/profiles/studentinfo.html" %}
Expand All @@ -68,13 +67,18 @@ <h4 style="color:red">Please fix the following error{{ form.errors|pluralize }}
{% include "users/profiles/usercontact.html" %}
{% include "users/profiles/guardianinfo.html" %}
{% else %}

{% ifequal profiletype "Volunteer" %}
{% include "users/profiles/usercontact.html" %}
{% else %}

{% include "../templates/themes/bs_form.html" %}

{% endifequal %}
{% endifequal %}
{% endifequal %}
{% endifequal %}
{% endifequal %}

<div class="form-actions"><input type="submit" class="btn btn-primary" value="Update your Information!" /></div>

Expand Down
2 changes: 1 addition & 1 deletion esp/templates/users/profiles/educatorinfo.html
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ <h3>Educator Information</h3>
</div>

<div class="control-group">
<label for="id_college" class="control-label">School Name:</label>
<label for="id_school" class="control-label">School Name:</label>
<div class="controls">
{{ form.school }} {% if form.school.errors %}
<br /><span class="form_error">{{ form.school.errors|join:", " }}</span>
Expand Down
2 changes: 1 addition & 1 deletion esp/templates/users/profiles/emergencycontact.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ <h3>Emergency Contact</h3>
this might be a family friend or nearby relative.<br /><br />
Please either click below to copy your home address and your
parents' contact information into this form, or give contact information for someone else that you know and trust.
<p><center><input type="button" class="btn span8" onclick="javascript:copy_parent_info();" value="Use my parents as my emergency contact" /></center></p>
<p><center><input type="button" class="btn" onclick="javascript:copy_parent_info();" value="Use my parents as my emergency contact" /></center></p>
</div>

<script type="text/javascript">
Expand Down
2 changes: 1 addition & 1 deletion esp/templates/users/profiles/guardianinfo.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<h3>Guardian Information</h3>

<div class="control-group">
<label for="id_year_finished" class="control-label">Est. year finished with ESP<br /> (if applicable):</label>
<label for="id_year_finished" class="control-label">Est. year finished with ESP (if applicable):</label>
<div class="controls">
{{ form.year_finished }} {% if form.year_finished.errors %}
<br /><span class="form_error">{{ form.year_finished.errors|join:", " }}</span>
Expand Down
Loading

0 comments on commit 09ff26d

Please sign in to comment.