more user profile fixes
parent
62a4a9cd1e
commit
f455f3072f
|
@ -60,7 +60,7 @@ object User extends LilaController {
|
|||
}
|
||||
private def renderShow(u: UserModel, status: Results.Status = Results.Ok)(implicit ctx: Context) =
|
||||
if (HTTPRequest.isSynchronousHttp(ctx.req)) for {
|
||||
as <- Env.activity.read.recent(u.id, 30)
|
||||
as <- Env.activity.read.recent(u.id, 7)
|
||||
info ← Env.current.userInfo(u, ctx)
|
||||
social ← Env.current.socialInfo(u, ctx)
|
||||
} yield status(html.user.show.activity(u, as, info, social))
|
||||
|
|
|
@ -6,7 +6,6 @@
|
|||
@if(!u.lame || ctx.is(u) || isGranted(_.UserSpy)) {
|
||||
@if(filters.current.name == "search") {
|
||||
@jsTag("search.js")
|
||||
@jsTag("userShow.js")
|
||||
}
|
||||
@info.ratingChart.map { ratingChart =>
|
||||
@jsTag("chart/ratingHistory.js")
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
<div class="content_box_inter tabs" id="games">
|
||||
@filters.list.map { f =>
|
||||
<a class="intertab@{ (filters.current == f).??(" active") }" href="@routes.User.games(u.username, f.name)">
|
||||
<a class="intertab to_@f.name@if(filters.current == f){ active}" href="@routes.User.games(u.username, f.name)">
|
||||
@userGameFilterTitle(info, f)
|
||||
</a>
|
||||
}
|
||||
|
@ -15,7 +15,6 @@
|
|||
<div class="search_result">
|
||||
|
||||
@if(filterName == "search") {
|
||||
<div class="search_result">
|
||||
@if(pager.nbResults > 0) {
|
||||
<div class="search_status">
|
||||
<strong>@pager.nbResults.localize games found</strong> •
|
||||
|
@ -35,7 +34,6 @@
|
|||
<a class="permalink" href="@routes.User.games(u.username, filterName)">Permalink</a>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
} else {
|
||||
<div class="games infinitescroll @if(filterName == "playing" && pager.nbResults > 2) {game_list playing center}">
|
||||
@pager.nextPage.map { np =>
|
||||
|
|
|
@ -122,6 +122,7 @@ $(function() {
|
|||
return false;
|
||||
});
|
||||
$('.user_show').on('click', '#games a', function() {
|
||||
if ($('#games .to_search').hasClass('active') || $(this).hasClass('to_search')) return true;
|
||||
$filters = $(this).parent();
|
||||
$(this).addClass('active');
|
||||
browseTo($(this).attr('href'));
|
||||
|
|
Loading…
Reference in New Issue