simplify bot account page

This commit is contained in:
Thibault Duplessis 2018-04-18 01:48:00 +02:00
parent 0fe33c3d32
commit 734fc453b3
3 changed files with 3 additions and 2 deletions

View file

@ -28,7 +28,7 @@
@info.nbBlockers.map { nb =>
<a class="intertab">@splitNumber(nb + " Blockers")</a>
}
<a href="@routes.UserTournament.path(u.username, "recent")" class="intertab tournament_stats" data-toints="@u.toints">@splitNumber(trans.nbTournamentPoints.pluralSame(u.toints))</a>
@if(u.noBot){<a href="@routes.UserTournament.path(u.username, "recent")" class="intertab tournament_stats" data-toints="@u.toints">@splitNumber(trans.nbTournamentPoints.pluralSame(u.toints))</a>}
<a href="@routes.Study.byOwnerDefault(u.username)" class="intertab">@splitNumber(info.nbStudies + " studies")</a>
<a class="intertab" @NotForKids {
href="@routes.ForumPost.search("user:" + u.username, 1)"

View file

@ -50,6 +50,6 @@
@showNonEmptyPerf(u.perfs.horde, PerfType.Horde)
@showNonEmptyPerf(u.perfs.racingKings, PerfType.RacingKings)
<br />
@showPerf(u.perfs.puzzle, PerfType.Puzzle)
@if(u.noBot){@showPerf(u.perfs.puzzle, PerfType.Puzzle)}
}
</div>

View file

@ -110,6 +110,7 @@ case class User(
def is(name: String) = id == User.normalize(name)
def isBot = title has User.botTitle
def noBot = !isBot
def rankable = !isBot && !rankban
}