allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From brond...@apache.org
Subject allura git commit: Fix unicode errors in templates.
Date Mon, 02 Nov 2015 21:14:48 GMT
Repository: allura
Updated Branches:
  refs/heads/master f5102013b -> 6ec9d3395


Fix unicode errors in templates.

Can't do `u'...'.format(...)` in jinja :(
See last paragraph of http://jinja.pocoo.org/docs/dev/api/#unicode


Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/6ec9d339
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/6ec9d339
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/6ec9d339

Branch: refs/heads/master
Commit: 6ec9d339546f500e954d5046f8af00259669c37c
Parents: f510201
Author: Dave Brondsema <dave@brondsema.net>
Authored: Mon Nov 2 17:47:45 2015 +0000
Committer: Dave Brondsema <dave@brondsema.net>
Committed: Mon Nov 2 17:47:45 2015 +0000

----------------------------------------------------------------------
 Allura/allura/ext/admin/templates/admin_widgets/card_field.html | 2 +-
 Allura/allura/ext/admin/templates/project_groups.html           | 2 +-
 Allura/allura/templates/repo/file.html                          | 2 +-
 Allura/allura/templates/repo/tree.html                          | 2 +-
 ForgeActivity/forgeactivity/templates/widgets/follow.html       | 2 +-
 5 files changed, 5 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/6ec9d339/Allura/allura/ext/admin/templates/admin_widgets/card_field.html
----------------------------------------------------------------------
diff --git a/Allura/allura/ext/admin/templates/admin_widgets/card_field.html b/Allura/allura/ext/admin/templates/admin_widgets/card_field.html
index 2e7ba6e..03b4fc6 100644
--- a/Allura/allura/ext/admin/templates/admin_widgets/card_field.html
+++ b/Allura/allura/ext/admin/templates/admin_widgets/card_field.html
@@ -25,7 +25,7 @@
       {{ g.icons['perm_tool'].render(
           href=settings_href,
           extra_css='admin_modal',
-          title='{} Settings'.format(name)) }}
+          title='%s Settings' % (name)) }}
       {% endif %}
       <p style="padding-bottom: 0">{{ g.icons[icon_name].render(tag='span', extra_css='x24')
}}</p>
       {% if desc %}

http://git-wip-us.apache.org/repos/asf/allura/blob/6ec9d339/Allura/allura/ext/admin/templates/project_groups.html
----------------------------------------------------------------------
diff --git a/Allura/allura/ext/admin/templates/project_groups.html b/Allura/allura/ext/admin/templates/project_groups.html
index 8a5c56d..765a593 100644
--- a/Allura/allura/ext/admin/templates/project_groups.html
+++ b/Allura/allura/ext/admin/templates/project_groups.html
@@ -71,7 +71,7 @@
           {% for r in role.users_with_role() %}
           <li class="deleter" data-user="{{r.user.username}}">
             {{ g.icons['perm_delete'].render(
-                title='{} ({})'.format(r.user.display_name, r.user.username),
+                title='%s (%s)' % (r.user.display_name, r.user.username),
                 show_title=True,
                 extra_css='deleter',
                 **{'data-user': r.user.username}) }}

http://git-wip-us.apache.org/repos/asf/allura/blob/6ec9d339/Allura/allura/templates/repo/file.html
----------------------------------------------------------------------
diff --git a/Allura/allura/templates/repo/file.html b/Allura/allura/templates/repo/file.html
index ecfbd1b..90413ec 100644
--- a/Allura/allura/templates/repo/file.html
+++ b/Allura/allura/templates/repo/file.html
@@ -33,7 +33,7 @@
 
 {% block actions %}
 {{ lib.maximize_content_button() }}
-{{ g.icons['history'].render(href='{}log/?path={}'.format(blob.commit.url(), blob.path()),
show_title=True) }}
+{{ g.icons['history'].render(href='%slog/?path=%s' % (blob.commit.url(), blob.path()), show_title=True)
}}
 {% endblock %}
 
 {% block extra_js %}

http://git-wip-us.apache.org/repos/asf/allura/blob/6ec9d339/Allura/allura/templates/repo/tree.html
----------------------------------------------------------------------
diff --git a/Allura/allura/templates/repo/tree.html b/Allura/allura/templates/repo/tree.html
index def5aa6..3721225 100644
--- a/Allura/allura/templates/repo/tree.html
+++ b/Allura/allura/templates/repo/tree.html
@@ -63,7 +63,7 @@ form.tarball button:hover {
 </form>
 {% endif %}
 
-{{ g.icons['history'].render(href='{}log/?path={}'.format(commit.url(), path), show_title=True)
}}
+{{ g.icons['history'].render(href='%slog/?path=%s' % (commit.url(), path), show_title=True)
}}
 {% if c.user and c.user != c.user.anonymous() %}
   {{c.subscribe_form.display(value=tool_subscribed, tool_subscribed=tool_subscribed, action='subscribe',
style='icon')}}
 {% endif %}

http://git-wip-us.apache.org/repos/asf/allura/blob/6ec9d339/ForgeActivity/forgeactivity/templates/widgets/follow.html
----------------------------------------------------------------------
diff --git a/ForgeActivity/forgeactivity/templates/widgets/follow.html b/ForgeActivity/forgeactivity/templates/widgets/follow.html
index 8fd8ea8..3199e50 100644
--- a/ForgeActivity/forgeactivity/templates/widgets/follow.html
+++ b/ForgeActivity/forgeactivity/templates/widgets/follow.html
@@ -20,7 +20,7 @@
 {{ g.icons[icon].render(
     href=action,
     extra_css='artifact_follow{}'.format(' active' if following else ''),
-    title='{} {}'.format(
+    title='%s %s' % (
       'Stop {}ing'.format(action_label) if following else action_label.capitalize(),
       thing),
     **{'data-following': h.really_unicode(following).lower(),


Mime
View raw message