Problem/Motivation

Country names are not sorted by the language specific rules.

Steps to reproduce

Configure the language to German. Open a country list. "Österreich" is listed at the very end of the list, but it should be after "Oman" (at the end of countries starting with "O") following the language specific rules. Other languages are affected as well, eg. Turkish.

Proposed resolution

Sort country names using PHP Collator

Remaining tasks

User interface changes

none

API changes

language_manager is added to the CountryFieldManager
country manager is removed from CountryAutocompleteController

Data model changes

none

Issue fork country-3403443

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

sleitner created an issue. See original summary.

sleitner’s picture

Status: Active » Needs review
sleitner’s picture

StatusFileSize
new5.86 KB

Patch against v1.1

schillerm’s picture

Hi, I tested #4 patch against v1.1 (using same steps to reproduce error) and it works as described. Country names are now sorting correctly.
+1 for RTBC.

batigolix’s picture

Status: Needs review » Reviewed & tested by the community
StatusFileSize
new212.22 KB
new164.38 KB

I tested this and it works.

It can also be tested in an English set up with the Åland Islands entry:

Before:

country select before

After:

country select after

  • batigolix committed 87e92878 on 8.x-1.x authored by sleitner
    Issue #3403443 by sleitner, batigolix, schillerm: Sort country names...
batigolix’s picture

Status: Reviewed & tested by the community » Fixed

Thanks!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.