From 116751e4bab183b3cca93ab13f7f4f21c752be4e Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Tue, 24 Apr 2012 23:22:23 -0500 Subject: Rename mirror country fields to country_old in prep for normalization We're going to move to using ISO 2 character codes via django countries, so start by moving the old data out of the way first. Signed-off-by: Dan McGee --- templates/mirrors/mirrors.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'templates/mirrors/mirrors.html') diff --git a/templates/mirrors/mirrors.html b/templates/mirrors/mirrors.html index 3aff8ea6..4b59058a 100644 --- a/templates/mirrors/mirrors.html +++ b/templates/mirrors/mirrors.html @@ -27,7 +27,7 @@ {{ mirror.name }} {{mirror.get_tier_display}} - {{mirror.country}} + {{mirror.country_old}} {{mirror.isos|yesno|capfirst}} {{mirror.supported_protocols|join:", "}} {% if user.is_authenticated %} -- cgit v1.2.3-2-g168b From 640e0f58645a7fd07f3c6185d9583b4d218e2468 Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Wed, 25 Apr 2012 01:32:57 -0500 Subject: Finish django countries implementation * Add a migration to drop the old countries field. * Update all templates/views/utility methods to point at the new country field and dereference it as necessary. * Add the flags images to a few views where it makes sense. * Cleanup the download page layout quite a bit. * Bump the mirror status JSON version to 3; add country_code attribute. Signed-off-by: Dan McGee --- templates/mirrors/mirrors.html | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'templates/mirrors/mirrors.html') diff --git a/templates/mirrors/mirrors.html b/templates/mirrors/mirrors.html index 4b59058a..19c6ea27 100644 --- a/templates/mirrors/mirrors.html +++ b/templates/mirrors/mirrors.html @@ -26,15 +26,15 @@ {{ mirror.name }} - {{mirror.get_tier_display}} - {{mirror.country_old}} - {{mirror.isos|yesno|capfirst}} - {{mirror.supported_protocols|join:", "}} + {{ mirror.get_tier_display }} + {% if mirror.country %} {% endif %}{{ mirror.country.name }} + {{ mirror.isos|yesno|capfirst }} + {{ mirror.supported_protocols|join:", " }} {% if user.is_authenticated %} - {{mirror.public|yesno|capfirst}} - {{mirror.active|yesno|capfirst}} - {{mirror.admin_email}} - {{mirror.notes|linebreaks}} + {{ mirror.public|yesno|capfirst }} + {{ mirror.active|yesno|capfirst }} + {{ mirror.admin_email }} + {{ mirror.notes|linebreaks }} {% endif %} {% endfor %} -- cgit v1.2.3-2-g168b From 9616aec563baff19898c5a3185bc2011734544cb Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Thu, 26 Apr 2012 12:05:57 -0500 Subject: Add empty 'alt' attribute for all country flag images These are all used purely for decoration, and the country name itself is right next to the flag image, so we can safely mark these as "invisible" to screen readers, text browsers, etc. Signed-off-by: Dan McGee --- templates/mirrors/mirrors.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'templates/mirrors/mirrors.html') diff --git a/templates/mirrors/mirrors.html b/templates/mirrors/mirrors.html index 19c6ea27..77c9ec33 100644 --- a/templates/mirrors/mirrors.html +++ b/templates/mirrors/mirrors.html @@ -27,7 +27,7 @@ {{ mirror.name }} {{ mirror.get_tier_display }} - {% if mirror.country %} {% endif %}{{ mirror.country.name }} + {% if mirror.country %} {% endif %}{{ mirror.country.name }} {{ mirror.isos|yesno|capfirst }} {{ mirror.supported_protocols|join:", " }} {% if user.is_authenticated %} -- cgit v1.2.3-2-g168b