Public bug reported: There is no ability to change the current department from code. This means that the scope cannot "do the right thing" when a user enters a query string in some cases.
For example, suppose a scope has departments that represent a web api's departments. And suppose the web api does not support searching inside a department but only supports searches over the whole site. What is the scope developer to do when the user is in a department *and* they enter a query string? Because there is no way now to change the department (perhaps to a department named "Search Results"), the dev *must* return results in the current department, which is incorrect. 500px web api and our 500px scope is like this. 500px has "streams" like "Editors", "Fresh today" etc. The scope displays these as departments. However, the 500px web api has no api to provide search results limited to a stream. Therefore when a user is in a department, for example "Fresh Today" and they enter a search string, the results are in fact not limited to Fresh Today but they are displayed in the Fresh Today department, which is not correct. It is possible (and the proposed the 1.0 version of the 500px scope does this) to avoid the problem by applying the search query string to the department's results. So for example if the search was "strawberry" and the user was in "Fresh Today" department, the scope only displays received "Fresh Today" results that contain "strawberry". But this is sub-optimal because the scope needs to keep querying the api to get more and Fresh Today results trying to find matches, which takes time and may not find a match. ** Affects: canonical-scopes-project Importance: Undecided Status: New ** Affects: ubuntu-ux Importance: Undecided Status: New ** Affects: unity-scopes-api (Ubuntu) Importance: Undecided Status: New ** Also affects: unity-scopes-api (Ubuntu) Importance: Undecided Status: New ** Also affects: canonical-scopes-project Importance: Undecided Status: New -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1568035 Title: cannot change department from code To manage notifications about this bug go to: https://bugs.launchpad.net/canonical-scopes-project/+bug/1568035/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs