Cascade dropdown order by alphabetically not working in PT

Home Forums Classic DFFS Cascade dropdown order by alphabetically not working in PT

Viewing 1 reply thread
  • Author
    Posts
    • #31051
      DevAmb
      Participant

        Good afternoon,

        I have a cascade dropdown with district, county and parish that is not sorting alphabetically.
        I think it’s because we have districts whose first letter has an accent.

        Can you help?
        Thanks

        Attachments:
      • #31054
        Alexander Bautz
        Keymaster

          I didn’t take this into account when I created the built in sort function, but you can fix it by adding this to your custom js:

          spjs.casc.customSort.YOUR_FIELD_NAME = function(a, b) {
              // Fix accented characters
              return a.text.localeCompare(b.text);
          };

          Replace YOUR_FIELD_NAME with the internal name of your field.

          I’ll get this fixed in the next release of DFFS.

          Alexander

      Viewing 1 reply thread
      • You must be logged in to reply to this topic.