They can, if the state is violating a Constitutional right. Notice how the claim is framed: the unions may be attempting to argue that their right of association (First Amendment) is being violated, which is a fatuous argument: they can associate all they want.
The goal of the goons is to get implementation delayed long enough to defeat the sufficient number of GOP senators. They may very well succeed, but it'll be a pyrrhic victory, as massive layoffs will result.