The restraining order by the judge, Loren AliKhan of US District Court for the District of Columbia, came hours after the Justice Department told a federal judge in Rhode Island who issued a similar order Friday that the government interpreted his order as applying to all spending nationally, not just to funds for the states that brought that case.