integreat-cms
integreat-cms copied to clipboard
Automatically validate location data of `POI` model
Motivation
At the moment, it is possible to insert incorrect data for the exact position of POI
s. Since there are many possible pitfalls when creating POI
s, we should validate the input and auto-fill as much as possible.
Proposed Solution
Possible ideas (check effort vs. usability on each step):
- [x] Validate whether an address format is correct
- [x] Validate whether a street exists in the given city
- [ ] Suggest available streets on the selected city
- [x] Auto-fill city after zip code has been inserted
- [x] Auto-fill coordinates after address is complete
- [ ] If coordinates are manually changed after auto-fill, check for consistency with the address data and raise a warning if the positions are completely off
Alternatives
Additional Context
Honestly, I do not think that this is that important. As with all content that is created in the app, the content creators need to take care that everything is "correct". I think it would be most important to show a preview of the location on a small embedded map to simply show where the location actually is on a map. I would also argue that this is not necessary for a release, only nice to have.
I agree with Sven, a validation is surely a nice thing to have, but the wordpress doesn't have it. Therefore I suggest to postpone it to Version 2.0 and add the prio:high label.
Alright, seems reasonable! :+1:
We could use our geocoding service for this: http://nominatim.maps.tuerantuer.org/nominatim/search.php?street=Am%20B%C3%BChl&postalcode=86199
API documentation: https://nominatim.org/release-docs/develop/api/Overview/
Isn't that also related to #1035 ?
Isn't that also related to #1035 ?
Yes, it's related, but can be implemented independently of each other.
Since this is now mostly done, I decreased the prio of the remaining tasks and moved it back into the backlog