Legislators in New Jersey and Maine ordered their state governments be shut down after parties failed to agree on budget deals.