They can dictate what you wear. It doesn’t mean they should, at least with cases like this. Set all the rules you want on hemlines and midriffs - but making a rule like this, that was clearly targeted at this particular girl, just days before the prom is unforgivable.