Ali is a very good mid-order batsman who can bowl very well - he seems to be turning into a true allrounder! So he should not be opening at International level.
Hales can open - but is he simply going through a patch of poor form or is he not good enough at International Test level? So the selectors have got to stop ponsing around swapping and changing, and either play Hales for a few Tests t see if it is form or quality that I letting him down! If it's quality then look at a proper alternative, rather than trying Ali and others!!