contest;
sortby { $a->{name} cmp $b->{name} };
group { $_->{level} };
+ mangle { $_->{owner_name} = do { local $Gruntmaster::Data::contest; user_name $_->{owner} } }
};
thing {
params qw/ct contest Contests/;
sortby { $a->{start} <=> $b->{start} };
group { time < $_->{start} ? 'pending' : time > $_->{end} ? 'finished' : 'running' };
- mangle { $_->{started} = time >= $_->{start} };
+ mangle { $_->{started} = time >= $_->{start}; $_->{owner_name} = do { local $Gruntmaster::Data::contest; user_name $_->{owner} } };
};
thing {
params qw/log job/, 'Job log';
contest;
- mangle { $_->{results} &&= decode_json $_->{results}; }
+ mangle { $_->{results} &&= decode_json $_->{results}; $_->{user_name} = do { local $Gruntmaster::Data::contest; user_name $_->{user} } }
};
1
date => (job_date() ? strftime ('%c' => localtime job_date) : '?'),
extension => job_extension,
name => problem_name job_problem,
+ user_name => do { local $Gruntmaster::Data::contest; user_name job_user },
problem => job_problem,
result => job_result,
result_text => job_result_text,
<tmpl_loop running><tr><td><a href="<tmpl_var id>/"><tmpl_var name></a>
<td><%perl __OUT__ POSIX::strftime '%c', localtime __CURRENT__->{start}; %>
<td><%perl __OUT__ POSIX::strftime '%c', localtime __CURRENT__->{end}; %>
-<td><tmpl_var owner>
+<td><a href="/us/<tmpl_var owner>"><tmpl_var owner></a><tmpl_if owner_name> (<tmpl_var owner_name>)</tmpl_if>
</tmpl_loop>
</table>
</tmpl_if>
<tmpl_loop pending><tr><td><a href="<tmpl_var id>/"><tmpl_var name></a>
<td><%perl __OUT__ POSIX::strftime '%c', localtime __CURRENT__->{start}; %>
<td><%perl __OUT__ POSIX::strftime '%c', localtime __CURRENT__->{end}; %>
-<td><tmpl_var owner>
+<td><a href="/us/<tmpl_var owner>"><tmpl_var owner></a><tmpl_if owner_name> (<tmpl_var owner_name>)</tmpl_if>
</tmpl_loop>
</table>
</tmpl_if>
<tmpl_loop finished><tr><td><a href="<tmpl_var id>/"><tmpl_var name></a>
<td><%perl __OUT__ POSIX::strftime '%c', localtime __CURRENT__->{start}; %>
<td><%perl __OUT__ POSIX::strftime '%c', localtime __CURRENT__->{end}; %>
-<td><tmpl_var owner>
+<td><a href="/us/<tmpl_var owner>"><tmpl_var owner></a><tmpl_if owner_name> (<tmpl_var owner_name>)</tmpl_if>
</tmpl_loop>
</table>
</tmpl_if>
<td><a href="../pb/<tmpl_var problem>"><tmpl_var name></a>
<td><tmpl_var date>
<td><a href="src/<tmpl_var id>.<tmpl_var extension>"<tmpl_if private> data-private</tmpl_if>><tmpl_var size></a>
-<td><tmpl_var user><td class="r<tmpl_var result>"><tmpl_var result_text>
+<td><a href="/us/<tmpl_var user>"><tmpl_var user></a><tmpl_if user_name> (<tmpl_var user_name>)</tmpl_if><td class="r<tmpl_var result>"><tmpl_var result_text>
</tmpl_loop>
</table>
<table border class="table table-bordered table-striped table-fixed">
<thead><tr><th>Name<th>Author<th>Owner
<tbody>
-<tmpl_loop beginner><tr><td><a href="<tmpl_var id>"><tmpl_var name></a><td><tmpl_var author><td><tmpl_var owner>
+<tmpl_loop beginner><tr><td><a href="<tmpl_var id>"><tmpl_var name></a><td><tmpl_var author><td><a href="/us/<tmpl_var owner>"><tmpl_var owner></a><tmpl_if owner_name> (<tmpl_var owner_name>)</tmpl_if>
</tmpl_loop>
</table>
</tmpl_if>
<table border class="table table-bordered table-striped table-fixed">
<thead><tr><th>Name<th>Author<th>Owner
<tbody>
-<tmpl_loop easy><tr><td><a href="<tmpl_var id>"><tmpl_var name></a><td><tmpl_var author><td><tmpl_var owner>
+<tmpl_loop easy><tr><td><a href="<tmpl_var id>"><tmpl_var name></a><td><tmpl_var author><td><a href="/us/<tmpl_var owner>"><tmpl_var owner></a><tmpl_if owner_name> (<tmpl_var owner_name>)</tmpl_if>
</tmpl_loop>
</table>
</tmpl_if>
<table border class="table table-bordered table-striped table-fixed">
<thead><tr><th>Name<th>Author<th>Owner
<tbody>
-<tmpl_loop medium><tr><td><a href="<tmpl_var id>"><tmpl_var name></a><td><tmpl_var author><td><tmpl_var owner>
+<tmpl_loop medium><tr><td><a href="<tmpl_var id>"><tmpl_var name></a><td><tmpl_var author><td><a href="/us/<tmpl_var owner>"><tmpl_var owner></a><tmpl_if owner_name> (<tmpl_var owner_name>)</tmpl_if>
</tmpl_loop>
</table>
</tmpl_if>
<table border class="table table-bordered table-striped table-fixed">
<thead><tr><th>Name<th>Author<th>Owner
<tbody>
-<tmpl_loop hard><tr><td><a href="<tmpl_var id>"><tmpl_var name></a><td><tmpl_var author><td><tmpl_var owner>
+<tmpl_loop hard><tr><td><a href="<tmpl_var id>"><tmpl_var name></a><td><tmpl_var author><td><a href="/us/<tmpl_var owner>"><tmpl_var owner></a><tmpl_if owner_name> (<tmpl_var owner_name>)</tmpl_if>
</tmpl_loop>
</table>
</tmpl_if>