eonum / geopitalsuisse

Visualize the Swiss hospital landscape
MIT License
4 stars 0 forks source link

refactor JSON API #74

Closed tschimbr closed 6 years ago

tschimbr commented 6 years ago

Ein Hospital-Model: Name, Adresse, Ort, Latitude, Longitude, Typ, Attribute{} Später evtl. die Möglichkeit, einige Attribute nur lazy hineinzuladen. Sobald die Datenmenge zu gross wird, um immer zu laden.

{ 
name: string, 
address: string,
location: string,
latitude: string, 
longitude: string, 
typ: Typ, 
attributes: Attribute{ code: { value: value, years: { 2012: value, 2013: value }}}
}

Ein Attribut-Model: Code, Kategorie, Name_de, Name_fr, Name_it, Wert, Jahr

See: https://github.com/eonum/casematch/blob/master/app/models/variable.rb


{ 
code: string, 
type: # categorical, numerical, string
values: # possible values if categorical
values_de,
values_fr,
values_it,
categories: array of strings, # semantics
name_de: string,
name_fr: string, 
name_it: string, 
}
tschimbr commented 6 years ago

Implement this in https://github.com/eonum/qualimed-hospitals

doutzi commented 6 years ago

Solved by #79