hhaccessibility / hhaccessibility.github.io

http://hhaccessibility.github.io/main/
7 stars 41 forks source link

Rating Feature: Allow a user to add a location #386

Closed Blandine-AA closed 6 years ago

Blandine-AA commented 7 years ago

After the update meeting today with JMCC, it was mentioned to allow a user to enter a location that is not yet in AL.

To avoid duplicates and wrong/phony entries, I suggest to use the user GPS location to identify the location he wants to add. IF the location name can be retrieved based on GPS coordinates, then have the user validate it before adding it.

Also, having the GPS coordinates of the location will prevent duplicates, some thinking will have to be done here to define the proper algorithm/process.

joshi1983 commented 7 years ago

The previous plan was to import all locations from other data sources and not let any user add a new location but letting people add their own locations sounds useful to me. For ratings information, we planned how to drown out inaccurate information and we'll need a plan for how to minimize bad information on user-created locations.

The longitude and latitude is definitely needed for every new location but we'd need a UI for selecting it since the user might not be exactly where the new location is and they might be adding it using a device that has no GPS sensor such as a laptop. Even devices with a working GPS can get bad sensor data if they're inside a building. The UI for specifying latitude and longitude could show a map of where a typed address is or let the user click on the map to point out where the location is.

Preventing duplicates could involve a few things. Here are a few ideas:

Blandine-AA commented 7 years ago

@josh, during the meeting @stephanosm mentioned a google tracking tool that can be useful to use. If he can add more details about it here that can be helpful to workout the design plan.

joshi1983 commented 7 years ago

I added a field to the location table to store which user created the location because that seems useful regardless of anything we learn from further discussion on this. I didn't mark this "working on it" because I did this little step quickly and I'm not actively working on it now.

The following work still needs to be done:

Blandine-AA commented 7 years ago

@joshi1983, what user name do you have for AL loaded locations? I remember that for other apps imported data we thought about using something like "AccessNow_User". We should probably define/finalize the naming convention/format for that.

joshi1983 commented 7 years ago

We have NULL as in no associated user for the current locations. Every location has an associated data source but it is only the initial imported ratings that are made by dummy user accounts.

joshi1983 commented 6 years ago

Here is a checklist of work that I see needed for this. Some work may be broken into separate issues:

joshi1983 commented 6 years ago

I'm doing checklist items from the above checklist.

For the location add feature, I'll create the page initially based on the following notes:

The following information will be collected on the location add page:

A location add API willl be included in the same pull request.

joshi1983 commented 6 years ago

The new location creation screen looks like this on a laptop and should adjust appropriately on mobile phones: image

Nearby locations are marked to help people see duplicates before they add them. Location categories and a location group is automatically suggested based on the location name. The marker moves when clicking on the map or updating the address field.

This can be tested by:

  1. Sign in at http://app.accesslocator.com.
  2. Scroll to "My Reviews" and click "Locations".
  3. Click the "+" in the upper-right corner of the locations list page.
  4. Type "Tim Hortons" in the name field and notice the group/franchise getting automatically selected. Also, notice "Restaurant" is selected" from the categories list.
  5. Type an address in the address field and notice that the marker moves in the map.
  6. Fill out information for a new location and click "Create" to create it.
  7. Go to the location list from "My Reviews" in the profile again.
  8. Click to delete the location. Notice the location is removed from the list.
joshi1983 commented 6 years ago

Here are a few improvements mentioned from a Friday meeting with Blandine:

The above list is from my memory a couple days after the meeting so I may have missed something.

joshi1983 commented 6 years ago

@Rubynguyen2910 see if you can do the last subtask item from a previous comment.

To be clear it is: "When a point is clicked on the map, auto-populate the "Address" with the location's address. This is the same behavior as on the "Home" page."

Rubynguyen2910 commented 6 years ago

This is ready for testing. The address should be filled in automatically when clicking on the Add Location map.