-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathview_team.html
More file actions
111 lines (100 loc) · 3.93 KB
/
Copy pathview_team.html
File metadata and controls
111 lines (100 loc) · 3.93 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
{% extends 'base/base.html' %}
{% load socialaccount %}
{% load static %}
{% block stylesheets %}
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto">
<link rel="stylesheet" href="{% static 'css/timathonTeam.css' %}"/>
{% endblock %}
{% block content %}
{% include 'base/navbar.html' %}
<div class="team-container">
<center><h1 class="team-name">{{ team.name }}</h1></center>
<div class="members-container">
<!-- <h5>Members:</h5>-->
{% for member in team.discord_members %}
<div class="members-card">
<div class="team-member">
<div><img class="member-pfp" src="{{ member.avatar_url }}" alt="pfp"></div>
<div class="member-username>"><span>{{ member.username }}</span></div>
</div>
</div>
{% endfor %}
</div>
<center>
{% if user in team.members.all %}
<div class="invite"><div>
<h6>Invite members in your team: <input class="invite-text" type="text" id="invite" readonly="readonly" value="{{ invite }}"></h6></div>
<div><h6><a class="btn default-btn" onclick="Copy()">Copy Invite</a></h6></div>
</div>
<br>
</center>
<center>
{% if challenge.submissions_status and not team.submitted%}
<a class="btn btn-info" style="margin-right: 10px;" href="{% url 'timathon:Submission' %}">Submit</a>
{% endif %}
<a class="btn btn-danger" href="{% url 'timathon:LeaveTeam' %}">Leave Team</a>
</center>
<br><br>
<span style="font-weight: bold; margin-top: 15px; color: #d0d0d0; padding:10px;">(Attention: If you leave the team and the team creation period is over then you will not be able to join the ongoing timathon)</span>
{% else %}
{# <h1>vote for the team</h1> IMPLEMENT THIS WITH THE VOTING SYSTEM#}
{% endif %}
</div>
{% if team.submitted and user in team.members.all %}
<div class="team-container" style="margin-top: 25px">
<br>
<h3>Submission:</h3>
<a class="btn default-btn" style="background-color: #FF7746; margin-left: 10px" href="{{ submission.github_link }}">Github Repository</a>
<br><br>
<h3>Description:</h3>
<h6 style="margin-left: 2px">{{ submission.description }}</h6>
</div>
{% endif %}
{% if not challenge.voting_status and votes and user in team.members.all %}
<h2 align="center" style="color:white">Marks Breakdown</h2>
<table>
<tr>
<th>C1</th>
<th>C2</th>
<th>C3</th>
<th>C4</th>
<th>Notes</th>
</tr>
{% for vote in votes %}
<tr>
<td>{{ vote.c1 }}</td>
<td>{{ vote.c2 }}</td>
<td>{{ vote.c3 }}</td>
<td>{{ vote.c4 }}</td>
<td>{{ vote.notes }}</td>
</tr>
{% endfor %}
</table>
<table>
<tr>
<th>Avg C1</th>
<th>Avg C2</th>
<th>Avg C3</th>
<th>Avg C4</th>
<th>Total Score</th>
</tr>
<br>
<tr>
<td>{{ avg_1 }}</td>
<td>{{ avg_2 }}</td>
<td>{{ avg_3 }}</td>
<td>{{ avg_4 }}</td>
<th>{{ total_score }}</th>
</tr>
</table>
{% endif %}
<script type="text/javascript">
function Copy()
{
var invite = document.getElementById("invite");
invite.select();
invite.setSelectionRange(0, 99999);
document.execCommand("copy");
}
</script>
{% endblock %}