blob: 2f10e66e786a4a1ba5607780ba38d47a9f43db57 (
plain)
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
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
|
<main id="solutions-main">
<div class="container user-info-content">
<div class="row">
<!-- User Profile details -->
<div class="col-xs-12 col-sm-12 col-md-6 col-lg-6 col-xs-offset-0
col-sm-offset-0 col-md-offset-3 col-lg-offset-3 toppad prf-details">
<!-- User Profile Menu -->
<nav class="navbar navbar-custom">
<div class="container-fluid">
<div class="navbar-header">
<button type="button" class="navbar-toggle"
data-toggle="collapse" data-target="#profile-nav">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
</div>
<div class="collapse navbar-collapse" id="profile-nav">
<ul class="nav navbar-nav " >
<li><a href="#" class="prf-page">General</a></li>
<li><a href="#" class="prf-page">Following</a></li>
<li><a href="#" class="prf-page">Friends</a></li>
<li><a href="#" class="prf-page">Send Message</a></li>
<li><a href="#" class="prf-page">Inbox</a></li>
<li><a href="#" class="prf-page">Comments</a></li>
</ul>
</div>
</div>
</nav>
<div class="rounded">
<div class="panel panel-info rounded">
<div class="panel-heading">
<h3 class="panel-title">{{ user.f_name }} {{ user.l_name }}</h3>
</div>
<div class="panel-body">
<!--- User-Profile Pages -->
<div class="row" id="profile-general">
<!-- User Image -->
<div class="col-md-3 col-lg-3 " align="center">
<img alt="User Pic" src="../assets/images/avatar.png"
class="img-circle img-responsive">
</div>
<!-- User Details -->
<div class=" col-md-9 col-lg-9 ">
<table class="table table-user-information">
<tbody>
<tr>
<td>Email:</td>
<td><a href="{{ user.email }}">{{ user.email }}</a></td>
</tr>
{{# if user.university }}
<tr>
<td>University:</td>
<td>{{ user.university }}</td>
</tr>
{{/if}}
{{# if user.department }}
<tr>
<td>Department:</td>
<td>{{ user.department }}</td>
</tr>
{{/if}}
<tr>
<td>Answered:</td>
<td>{{ user.answered }}</td>
</tr>
<tr>
<tr>
<td>Messages:</td>
<td>{{ user.messages }}</td>
</tr>
<tr>
<td>Comments:</td>
<td>{{ user.comments }}</td>
</tr>
{{# if user.phone_num}}
<tr>
<td>Phone Number:</td>
<td>{{ user.phone_num }}</td>
</tr>
{{/if}}
</tbody>
</table>
</div>
</div>
<div class="row" id="profile-follows">
{{# if user.followers }}
<h3>You are being followed by:</h3>
<div class="col-xs-offset-1 col-sm-offset-3 col-xs-10 col-sm-6">
<table class="table-condensed">
<tbody>
{{# each user.followers}}
<tr>
<th>
<img class="img-circle img-responsive"
src="../assets/images/misc/user1.jpeg" alt="avatar">
</th>
<th>
<h4>The Dude</h4>
<p>3 comments</p>
</th>
</tr>
{{/each}}
</tbody>
</table>
</div>
{{ else }}
<h3>You are not following any exams.</h3>
{{/if}}
</div>
<div class="row" id="profile-friends">
<h3>Friends</h3>
<div class="col-xs-offset-1 col-sm-offset-3 col-xs-10 col-sm-6">
<table class="table-condensed">
<tbody>
<tr>
<th>
<img class="img-circle img-responsive"
src="../assets/images/misc/user2.jpeg" alt="avatar">
</th>
<th>
<h4>He-Man</h4>
<p>20 comments</p>
</th>
</tr>
<tr>
<th>
<img class="img-circle img-responsive"
src="../assets/images/misc/user5.jpeg" alt="avatar">
</th>
<th>
<h4>Jay Leno</h4>
<p>5 comments</p>
</th>
</tr>
<tr>
<th>
<img class="img-circle img-responsive"
src="../assets/images/misc/user6.jpeg" alt="avatar">
</th>
<th>
<h4>Lisa Simpson</h4>
<p>658 comments</p>
</th>
</tr>
</tbody>
</table>
</div>
</div>
{{# if messages.success }}
<section class="alert alert-success">
<!-- Change those to banners later -->
<h3>{{ messages.success }}</h3>
</section>
{{ else }}
{{# if messages.error }}
<section class="alert alert-danger">
<h3>{{ messages.error }}</h3>
</section>
{{/if}}
{{/if}}
<div class="row" id="profile-send-message">
<h3>Send Message</h3>
<div class="col-xs-offset-1 col-sm-offset-3 col-xs-10 col-sm-6">
<form action="/user/user_profile/send_message" method="post">
<div class="form-group">
<label for="receiver">Send To:</label>
<input type="text" class="form-control" placeholder="Username" name="receiver_username">
</div>
<div class="form-group">
<label for="sending-message">Message:</label>
<textarea class="form-control" rows="3" name="message"></textarea>
</div>
<button class="btn btn-primary">Send Message</button>
<input type="hidden" name="_csrf" value="{{ csrfToken }}">
</form>
</div>
</div>
<div class="row" id="profile-inbox">
{{# if inbox }}
<h3>Inbox</h3>
<div class="col-sm-10 col-sm-offset-1 prf-tables">
<table class="table">
<thead>
<tr>
<th>Date</th>
<th>Subject</th>
<th>Sender</th>
</tr>
</thead>
<tbody>
{{# each inbox }}
<tr>
<td>{{ this.date }}</td>
<td>{{ this.message }}</td>
<td>{{ this.sender }}</td>
</tr>
{{/each}}
</tbody>
</table>
</div>
{{ else }}
<h3>No Messages.</h3>
{{/if}}
</div>
<div class="row" id="profile-comments">
{{# if comments }}
<h3>Comment History</h3>
<div class="col-sm-10 col-sm-offset-1 prf-tables">
<table class="table">
<thead>
<tr>
<th>Date</th>
<th>Comment</th>
<th>Exam</th>
</tr>
</thead>
<tbody>
{{# each comments }}
<tr>
<td>{{ this.date }}</td>
<td>{{ this.comment }}</td>
<td>{{ this.exam_info.course_code }} > {{ this.exam_info.term }}
{{ this.exam_info.year }}</td>
</tr>
{{/each}}
</table>
</div>
{{else}}
<h3>No Comments.</h3>
{{/if}}
</div>
<!-- Date, Edit, Logout (new row) -->
<div class="col-md-12 prf-sign-off">
<p class=" text-info"> July 4 2016 </p>
<a href="#">Edit Profile</a>
<a href="#">Logout</a>
<br>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</main>
|