The decree, which was immediately contested in court, makes it the first major member of the European Union to adopt such a measure.