fixup for category-links in achievements-listview if its a statistic

This commit is contained in:
Sarjuuk
2013-03-13 21:20:27 +01:00
parent 881e5143d1
commit 06ed69c6a1
3 changed files with 8 additions and 2 deletions

View File

@@ -23,6 +23,7 @@
points:{$curr.points},
category:{$curr.category},
parentcat:{$curr.parentCat}
{if isset($curr.type)}, type:{$curr.type}{/if}
{if isset($curr.rewards)}, rewards:{$curr.rewards}{/if}
{if isset($curr.reward)}, reward:'{$curr.reward|escape:"javascript"}'{/if}
{rdelim}

View File

@@ -11722,12 +11722,13 @@ Listview.templates = {
type: 'text',
width: '15%',
compute: function(achievement, td) {
statistic = achievement.type ? achievement.type + '.' : '';
td.className = 'small';
path = '?achievements=';
path = '?achievements=' + statistic;
if (achievement.category != -1 && achievement.parentcat != -1) {
var a2 = ce('a');
a2.className = 'q0';
a2.href = '?achievements=' + achievement.parentcat;
a2.href = '?achievements=' + statistic + achievement.parentcat;
ae(a2, ct(g_achievement_categories[achievement.parentcat]));
ae(td, a2);
ae(td, ce('br'));