What is the ordering of modes (Ionian, Dorian, etc.) from least to most dissonant?
The modes of the diatonic scale (Ionian, Dorian, Phrygian, Lydian, Mixolydian, Aeolian, Locrian) each contain exactly the same interval patterns - those of the diatonic scale. The only difference is the root note - so what must be meant by 'most dissonant' and 'least dissonant' here must in some way refer to the intervals that occur with respect to that root note.
As you can see from Dissonance: why doesn't the roughness curve have a dip for complex intervals like 7/6?, it is possible to come up with a graph of how dissonant certain intervals are perceived to be:
Plomp & Levelt 1965
So one way you could start to work towards some kind of dissonance ranking would be to rank how dissonant each interval created by the root and each other note in the mode is. However, you wouldn't be able to come up with an exact metric for each mode, for various reasons:
- In real music, scales are used across more than one octave, so each degree in the scale produces a set of intervals from the root (not just one)
- The dissonance curve is somewhat subjective, and also it depends on the timbre of the notes played (i.e. the strengths of harmonics in the sounds used, as mentioned in the linked question)
- Perhaps most importantly, in a musical context, we don't only hear intervals between the root and every other note, but every note and every other note. So we would have to somehow consider how to 'weight' the relative dissonances of intervals produced by notes other than the root in terms of importance. (if we were to weight them all the same, then each mode would come out as sounding no more or less dissonant than the other - because, as we said at the start, all modes of the diatonic scale have the same interval pattern).
It's this problem of 'weighting' that means that we can't come up with an exact ordering, as we can see from your example:
The ordering could start with the Ionian which must be the most consonant
Actually, if we just consider intervals from the root, the Ionian mode wouldn't be the most consonant mode of the diatonic scale - because a major seventh is a more dissonant interval than a minor seventh, the Mixolydian mode would be measured as more consonant.
So why might we nevertheless consider the Ionian mode more consonant than the Mixolydian? it comes back to that idea about considering the intervals from notes in the mode other than the root. If we look at the most consonant note in the Ionian mode other than the octave - i.e. the fifth - the intervals based on that are those of the mixolydian mode - i.e. very consonant! However, starting on the fifth of the Mixolydian mode generates the intervals of the Dorian mode, which would be less consonant. So the Mixolydian mode 'wins' in terms of consonance from its root, but 'loses' to the Ionian mode in terms of consonance from its fifth.
Put another way, we can see that the Ionian mode can produce especially consonant-sounding music when using triadic harmony, for example, because you have the (consonant-sounding) intervals of a major chord available from both the (also consonant) IV and V of the mode.
(Personally, I feel that part of the popularity of the major scale/Ionian mode is not just that it provides many opportunities for consonance, but also because the major seventh is an 'aching' dissonance that 'wants to' resolve to the root).
So, TLDR: It's hard to come up with an overall ordering of modes by consonance / dissonance. It's probably more worthwhile to note the different opportunities for consonance and dissonance that each mode allows in a musical piece.