Skip to content

Commit

Permalink
Wrap strings for i18n.
Browse files Browse the repository at this point in the history
  • Loading branch information
aronasorman committed Mar 8, 2016
1 parent dba86fc commit 3420b82
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<h1 class="status_name">{{ status.facility_name }}{{#if status.group_name }}: {{ status.group_name }}{{/if}}</h1>
<div class="topic-row">
<div class="col-sm-6">
<label for="topic-list">Topic: </label>
<label for="topic-list">{{_ "Topic:" }}</label>
<div id="topic-list-div">
<select id="topic-list" multiple="multiple">
</select>
Expand Down Expand Up @@ -47,7 +47,7 @@
</h5>
<div class="progressbar">
<div class="innerbar col-md-3">
<label id="legendMargin" for="legend">Key</label>
<label id="legendMargin" for="legend">{{_ "Key" }}</label>
<ul id="legend">
<li class="barlegend"><div class="struggling"></div><span>{{_ "Struggling" }}</span></li>
<li class="barlegend"><div class="complete"></div><span>{{_ "Completed" }}</span></li>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ var CoachSummaryView = BaseView.extend({


$('#topic-list').multiselect({
nonSelectedText: 'Default: Overview',
nonSelectedText: gettext('Default: Overview'),
buttonWidth: '75%',
numberDisplayed: 2,
maxHeight: 350,
Expand Down
2 changes: 1 addition & 1 deletion kalite/control_panel/templates/control_panel/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
{% if is_central %}
{% trans "New Sharing Network" %}
{% else %}
Unregistered Device {{ device.name }} - <a class="not-registered-only" href="{% url 'register_public_key' %}">Register Now!</a>
{% trans "Unregistered Device" %} {{ device.name }} - <a class="not-registered-only" href="{% url 'register_public_key' %}">{% trans "Register Now!" %}</a>
{% endif %}
{% endif %}
{% if facility or device %}</a>
Expand Down
6 changes: 3 additions & 3 deletions kalite/distributed/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,10 @@ def check_setup_status_wrapper_fn(request, *args, **kwargs):
# TODO(bcipolli): move this to the client side?
if not request.session.get("registered", True) and BaseClient().test_connection() == "success":
# Being able to register is more rare, so prioritize.
messages.warning(request, mark_safe("Please <a href='%s'>follow the directions to register your device</a>, so that it can synchronize with the central server." % reverse("register_public_key")))
messages.warning(request, mark_safe(_("Please <a href='%s'>follow the directions to register your device</a>, so that it can synchronize with the central server.") % reverse("register_public_key")))
elif not request.session["facility_exists"]:
zone_id = (Zone.objects.all() and Zone.objects.all()[0].id) or "None"
messages.warning(request, mark_safe("Please <a href='%s'>create a facility</a> now. Users will not be able to sign up for accounts until you have made a facility." % reverse("add_facility", kwargs={"zone_id": zone_id})))
messages.warning(request, mark_safe(_("Please <a href='%s'>create a facility</a> now. Users will not be able to sign up for accounts until you have made a facility.") % reverse("add_facility", kwargs={"zone_id": zone_id})))

elif not request.is_logged_in:
if not request.session.get("registered", True) and BaseClient().test_connection() == "success":
Expand All @@ -64,7 +64,7 @@ def check_setup_status_wrapper_fn(request, *args, **kwargs):
redirect_url = None
if redirect_url:
messages.warning(request, mark_safe(
"Please login with the admin account you created, then create your facility and register this device to complete the setup."))
_("Please login with the admin account you created, then create your facility and register this device to complete the setup.")))

return handler(request, *args, **kwargs)
return check_setup_status_wrapper_fn
Expand Down

0 comments on commit 3420b82

Please sign in to comment.