We have moved to GitHub Issues
Created by Paul Seal 03 May 2017, 09:05:04 Updated by Shannon Deminick 24 May 2017, 05:41:10
Subtask of: U4-9609
I was trying to use the new query builder in the home template 7.6.0 and it was returning the same query every time. Model.Content.Site().Children()
What did you expect to happen? I expected it to be different for each option I picked.
What actually happened? I got this every time. Model.Content.Site().Children()
See attached gif for the steps I took.
localizationService now returns a promise instead of a string so the way this was used in the QueryBuilderController, caused the yet unresolved promise to be set as a property on the base query model object.
This resulted in the base query object (until overridden by setting "content type" and "from node" via the UI dialog) to have a promise objects instead of strings in these properties. When this was sent to the endpoint, the model binder would fail to parse the property as a string since it looked like an object - causing the entire model binding to fail and therefore just returning the base result of
Have changed this so the init function will not run until the promises for localization has been resolved, therefore allowing the base query object to be instantiated correctly.
Have also added some missing nullchecks in the endpoint action as these were missing.
Backwards Compatible: True
Affected versions: 7.6.0
Due in version: 7.6.1
Sprint: Sprint 58