vostpt / greve-transportes-perigosos

Base Code for https://janaodaparaabastecer.vost.pt
https://janaodaparaabastecer.vost.pt
MIT License
31 stars 8 forks source link

[Feat] Differentiate the validation criteria by location #200

Open fbsoares opened 5 years ago

fbsoares commented 5 years ago

Context To submit an update about a Fuel Station, we evaluate that there are enough entries submitted from standard users. The amount of entries needed is configured through an admin panel.

Problem Some reports indicate that in some locations, the information would not update due to the lack of submissions. This happens mostly because there are some locations that don't have enough people using the website to report, so we have to evaluate this information manually or reduce the number of entries needed and creating another problem in other locations.

Objective

  1. Create a set of polygons with "My Google Maps" that separates geographically locations that should have a different amount of entries evaluated and describe them with the number of entries needed.

  2. Add an integer column "num_entries" in the fuel station's table to identify how many entries each station needs

  3. Create a script that verifies all the fuel stations without "num_entries", checks which polygon feats the geographical position and fills the "num_entries" column with the given number of that polygon.

  4. Feat the submission method of the map to validate the number of entries with "num_entries" of each station