Juris-M / legal-resource-registry

Jurisdiction ID and abbreviation data files for using with Jurism and other projects.
MIT License
31 stars 37 forks source link

implement court overrides for sub-jurisdictions #49

Open KampfCaspar opened 2 years ago

KampfCaspar commented 2 years ago

Countries may define courts on different jurisdiction levels, e.g. courts of first and second instance must exist by federal mandate, but naming is delegated to direct sub-jurisdictions and the actual courts exist on a sub-sub-jurisdiction. The current implementation allows court information only to be defined globally or by jurisdiction - but knows no inheritance.

I propose to implement an inheritance of court information down the sub-jurisdiction path. This allows to easily implement the following scenario

That's how it's implemented (more or less) in Switzerland. The federal government mandates to instances but leaves everything else to the cantons/states. The cantons define the naming of the courts, also for the district level. The districts have the courts of first instance. Now, while all districts have a court of first instance, in one canton they are called 'Kreisgericht', in another 'Bezirksgericht'. I can not define this name globally and I don't want to override it for every district.

To keep everything compatible, I suggest adapting a new keyword overrides in jurisdictions that contains the 'overridden' court definitions for that jurisdictions and all sub-jurisdictions.

georgd commented 2 years ago

@KampfCaspar this sounds interesting. Would you mind sharing a code snippet that shows how this would be used?

KampfCaspar commented 2 years ago

Let's say Atlantis has a three instances court system, a first instance on district level, a second instance on state level and a third instance on federal level. The states are free to organize their districts and to name both the first and second instance courts.

Now State 1 has named their second instance court 'State Court' and all district courts are called 'District Court'. 'State 2' on the other hand, has decided to name them 'Higher Court' and 'Lower Courts'.

The result (with only one district per state) would be: https://gist.github.com/KampfCaspar/9c454173b31ac8bb5a5dbdce2c181393

KampfCaspar commented 2 years ago

Any other remarks? Any set up work I need to follow?