Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Filters on Treemap change button not defaulting to current settings properly #460
When you click Change under the Treemap, the settings that appear don't default to the current settings properly. I think this is mostly a problem to do with components of a dimension (e.g.
For example, on the IATI dataset http://openspending.org/iati
This becomes more problematic when you have labels with spaces in them, e.g.
referenced this issue
Jul 9, 2012
This looks related to https://github.com/openspending/openspendingjs/blob/master/app/bob/bob.js#L400-401
In those lines, we get the element ("transaction_type.name"), split by "." and ignore the second part ("name"). Then, we're calling self.addFilter(null, "transaction_type", undefined, undefined).
We change an undefined attribute to "label" in https://github.com/openspending/openspendingjs/blob/master/app/bob/bob.js#L335.
Couldn't find where we're changing the undefined value to "D" though.
@markbrough Yes, you're right.
If we check the result, with curl "http://openspending.org/iati/transaction_type.distinct?attribute=name&limit=20", we get
So it looks that the user was able to add a label with line breaks in it. Is it valid?