Unless this action violates the terms of an employment contract or union agreement it is legal. The fact is that most work relationships are "at will" which means that a company can set the conditions of employment much as it sees fit (absent some form of legally actionable discrimination). At this point, you can either accept the situation, complain but risk terminatiom, or quit.