Add City needs to show states in US

Bug #1197436 reported by Steve Magoun on 2013-07-03
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu Clock App
Medium
Riccardo Padovani

Bug Description

The "add city" feature in the clock does not differentiate between cities in different states. It is common for a US state to have city/town that shares the name of a city/town in another state. For example, there are at least a dozen states that have a city/town called 'Springfield'. In this situation the list of cities shows multiple identical entries; the user has to guess which one is appropriate

To reproduce:
1) Launch clock app
2) Swipe up from bottom to reveal to "Add City" button
3) Tap "Add City"
4) In the search box, search for "Springfield"

Expected results:
Search results differentiate between different towns with the same name, e.g. "Springfield, Massachusetts, USA" and "Springfield, Missouri, USA"

Actual results:
Search results contain multiple "Springfield, USA" entries.

I'm using the saucy-31 build on a Nexus 7

----------------------------------------------------------------------------------- Solution to fix bug (HACKATHON)

This bug is quite trivial to fix. The online API from which the data is gathered does actually provide the state info if the "style=full" parameter is added to the url.

1. In the WorldClock.qml, append "style=full" in the searchCityUrl() function.
2. Append the searchCityModel XmlListModel to get the info from the adminName1 xml element in the online API.
3. In the ListView which shows the results, add the state from the XmlListModel.

The final search URL will be something like http://api.geonames.org/search?q=Springfield&style=full&maxRows=5&username=krnekhelesh

Dificulty: Easy

Test your fix and propose merge!

Related branches

Changed in ubuntu-clock-app:
status: New → Triaged
importance: Undecided → Medium
milestone: none → coreapps-13.10-month-3
assignee: nobody → Nekhelesh Ramananthan (nik90)
Nekhelesh Ramananthan (nik90) wrote :

This seems to be due to a limitation of the online API service. I have already reported it. Waiting for their response.

Changed in ubuntu-clock-app:
status: Triaged → In Progress
tags: added: hackday
Changed in ubuntu-clock-app:
assignee: Nekhelesh Ramananthan (nik90) → nobody
status: In Progress → Triaged
description: updated
description: updated
description: updated
description: updated
Changed in ubuntu-clock-app:
assignee: nobody → Riccardo Padovani (rpadovani)
Changed in ubuntu-clock-app:
status: Triaged → In Progress

Fix committed into lp:ubuntu-clock-app at revision 137, scheduled for release in ubuntu-clock-app, milestone coreapps-13.10-month-3

Changed in ubuntu-clock-app:
status: In Progress → Fix Committed
Changed in ubuntu-clock-app:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers