A federal judge Thursday halted all construction on a $2.1 billion flood diversion project that has pitted Minnesota against the Army Corps of Engineers and several communities along the Red River, saying the project cannot go forward without approval by the Dayton administration.

Attorneys described the ruling as a significant turning point in long-running litigation over the project, and one that could force all parties to negotiate a flood-control project acceptable to Minnesota and the Fargo-Moorhead Flood Diversion Board of Authority.

In granting the Minnesota Department of Natural Resources’ request for a preliminary injunction, U.S. District Judge John Tunheim wrote, “In the Court’s view, the law is clear. Congress has required that all necessary state and local permits be obtained before construction. Congress clearly has the power to exempt a project from state permitting requirements, but it has not done so.”

Tunheim went on to write that Minnesota “has not approved permits that are absolutely necessary for a project of this magnitude along a major border waterway, a project which clearly impacts the waters and lands of both North Dakota and Minnesota.

“It is time for all parties to work together to find common ground,” Tunheim said.

But Fargo Mayor Tim Mahoney, who chairs the Flood Diversion Board of Authority, said he expects the ruling will be appealed. The cost of construction increases by $60 million annually, he said.

“We simply cannot live with that level of financial risk, or the risk to public safety of not having protection,” Mahoney said in a statement posted on the agency’s website. “We will keep working hard toward establishing flood protection for the Fargo and Moorhead communities, hopefully we can do that in partnership with Minnesota.”

Minnesota Natural Resources Commissioner Tom Landwehr said the ruling “unequivocally” confirmed the DNR’s position that the federal legislation authorizing the project also requires state permits. Still, he said, Minnesota is committed to finding an approach for flood protection that “meets federal, state and local standards.”

Minnesota Gov. Mark Dayton called the ruling “excellent news for the safety and protection of Minnesotans.” In a statement late Thursday, he said it “upholds Minnesota’s rightful permitting authority” but said he agrees on the need for a collaborative solution.

An attorney for several small North Dakota communities upstream from Fargo, which filed suit against the project in 2013, said he hopes the decision will compel all parties into a new round of planning.

“That would be our goal, to bring people together and say let’s take another look at this,” said Jerry Von Korff, who represents counties and cities that would face flooding if the project were built.

Officials from the Army Corps did not immediately respond to requests for comment.

Construction on the project began this spring but will now be stopped as a result of Tunheim’s 60-page order. So far, the Army Corps has approved $25 million in construction funding, and the North Dakota legislature has approved about $370 million. Tunheim said he will consider requests to continue construction on individual parts of the project.

The plan includes a ring dike around three small North Dakota towns, a 36-mile diversion channel and a high-hazard dam. It was designed to protect Fargo and Moorhead from the floods that have inundated towns up and down the Red River Valley for 51 of the past 113 years.

Late last year, Dayton said Minnesota would not grant a permit for construction on the Minnesota side of the dam because it’s a significant safety risk, would violate Minnesota environmental laws and is not in the best interest of the state. Minnesota would lose thousands of acres of farmland, while North Dakota would gain land for development around Fargo. Minnesota’s DNR wants to explore other flood-control options.

North Dakota officials and the Army Corps of Engineers argued that the project did not need a permit from Minnesota because the corps has federal authority to proceed on the North Dakota side of the river.