Skip to content

Commit 410b2c0

Browse files
authored
- [Fixes #8454] Rating average available only in English (#8717)
1 parent 72740ed commit 410b2c0

3 files changed

Lines changed: 6 additions & 3 deletions

File tree

geonode/geoapps/templates/apps/app_detail.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{% extends "apps/app_base.html" %}
22
{% load i18n %}
3+
{% load l10n %}
34
{% load staticfiles %}
45
{% load dialogos_tags %}
56
{% load pinax_ratings_tags %}
@@ -75,7 +76,7 @@ <h3>{% trans "Rate this" %} {{ resource.type }}</h3>
7576
<h3>{% trans 'Average Rating' %}</h3>
7677
{% overall_rating resource "geoapp" as geoapp_rating %}
7778
{% num_ratings resource as num_votes %}
78-
<div class="overall_rating" style="float:left" data-score="{{ geoapp_rating }}"></div> ({{num_votes}})
79+
<div class="overall_rating" style="float:left" data-score="{{ geoapp_rating|unlocalize }}"></div> ({{num_votes}})
7980
</article>
8081
{% endif %}
8182

geonode/layers/templates/layers/layer_detail.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{% extends "layers/layer_base.html" %}
22
{% load i18n %}
3+
{% load l10n %}
34
{% load staticfiles %}
45
{% load dialogos_tags %}
56
{% load pinax_ratings_tags %}
@@ -249,7 +250,7 @@ <h4>{% trans "Rate this layer" %}</h4>
249250
<h4>{% trans 'Average Rating' %}</h4>
250251
{% overall_rating resource "layer" as layer_rating %}
251252
{% num_ratings resource as num_votes %}
252-
<div class="overall_rating" data-score="{{ layer_rating }}"></div> ({{num_votes}})
253+
<div class="overall_rating" data-score="{{ layer_rating|unlocalize }}"></div> ({{num_votes}})
253254
</article>
254255
{% endif %}
255256

geonode/maps/templates/maps/map_detail.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{% extends "maps/map_base.html" %}
22
{% load i18n %}
3+
{% load l10n %}
34
{% load staticfiles %}
45
{% load dialogos_tags %}
56
{% load pinax_ratings_tags %}
@@ -80,7 +81,7 @@ <h3>{% trans "Rate this Map" %}</h3>
8081
<h3>{% trans 'Average Rating' %}</h3>
8182
{% overall_rating resource "map" as map_rating %}
8283
{% num_ratings resource as num_votes %}
83-
<div class="overall_rating" style="float:left" data-score="{{ map_rating }}"></div> ({{num_votes}})
84+
<div class="overall_rating" style="float:left" data-score="{{ map_rating|unlocalize }}"></div> ({{num_votes}})
8485
</article>
8586
{% endif %}
8687

0 commit comments

Comments
 (0)