Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Graduation flag #1218

Merged
merged 12 commits into from
Aug 25, 2024
1 change: 1 addition & 0 deletions app/logic/minor.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ def getMinorProgress():
engagedStudentsList = [{'username': student.username,
'firstName': student.firstName,
'lastName': student.lastName,
'hasGraduated': student.hasGraduated,
'engagementCount': student.engagementCount - student.hasSummer,
'hasCommunityEngagementRequest': student.hasCommunityEngagementRequest,
'hasSummer': "Completed" if student.hasSummer else "Incomplete"} for student in engagedStudentsWithCount]
Expand Down
1 change: 1 addition & 0 deletions app/models/user.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ class User(baseModel):
isCeltsStudentStaff = BooleanField(default = False)
dietRestriction = TextField(null=True)
minorInterest = BooleanField(default=False)
hasGraduated = BooleanField(default=False)

# override BaseModel's __init__ so that we can set up an instance attribute for cache
def __init__(self,*args, **kwargs):
Expand Down
7 changes: 6 additions & 1 deletion app/templates/admin/cceMinor.html
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,12 @@ <h2>CCE Minor Progress</h2>
{% for student in sustainedEngagement %}
<tr>
<td>
<a href="/profile/{{student.username}}/cceMinor" target="_blank">{{ student.firstName }} {{ student.lastName }}</a>
<a class="" href="/profile/{{student.username}}/cceMinor" target="_blank">{{ student.firstName }} {{ student.lastName }}
{% if student.hasGraduated %} <svg width="20px" height="20px" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor" class="size-6">
<path d="M11.7 2.805a.75.75 0 0 1 .6 0A60.65 60.65 0 0 1 22.83 8.72a.75.75 0 0 1-.231 1.337 49.948 49.948 0 0 0-9.902 3.912l-.003.002c-.114.06-.227.119-.34.18a.75.75 0 0 1-.707 0A50.88 50.88 0 0 0 7.5 12.173v-.224c0-.131.067-.248.172-.311a54.615 54.615 0 0 1 4.653-2.52.75.75 0 0 0-.65-1.352 56.123 56.123 0 0 0-4.78 2.589 1.858 1.858 0 0 0-.859 1.228 49.803 49.803 0 0 0-4.634-1.527.75.75 0 0 1-.231-1.337A60.653 60.653 0 0 1 11.7 2.805Z" />
<path d="M13.06 15.473a48.45 48.45 0 0 1 7.666-3.282c.134 1.414.22 2.843.255 4.284a.75.75 0 0 1-.46.711 47.87 47.87 0 0 0-8.105 4.342.75.75 0 0 1-.832 0 47.87 47.87 0 0 0-8.104-4.342.75.75 0 0 1-.461-.71c.035-1.442.121-2.87.255-4.286.921.304 1.83.634 2.726.99v1.27a1.5 1.5 0 0 0-.14 2.508c-.09.38-.222.753-.397 1.11.452.213.901.434 1.346.66a6.727 6.727 0 0 0 .551-1.607 1.5 1.5 0 0 0 .14-2.67v-.645a48.549 48.549 0 0 1 3.44 1.667 2.25 2.25 0 0 0 2.12 0Z" />
<path d="M4.462 19.462c.42-.419.753-.89 1-1.395.453.214.902.435 1.347.662a6.742 6.742 0 0 1-1.286 1.794.75.75 0 0 1-1.06-1.06Z"/>
</svg>{% endif %}</a>
</td>
<td>{{ student.engagementCount }}/4 </td>
<td>{{ student.hasSummer }}</td>
Expand Down
Loading