Tesla ordered to stop work on $4 billion factory