-
Notifications
You must be signed in to change notification settings - Fork 58
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GUI: Inventory table reordered by string not float #231
Comments
I don't think this is the case. When sorting by one of the functional units it sorts the entire table by that column, if there are other functional units their ordering is also altered to reflect the changed rows caused by the sort. Can you give an example of the ordering being done incorrectly? |
Thanks! It looks like this is one of the tables from the activity tab, right? |
Yes, but i think it also occurs in other tables. |
I wonder if this has to do with the differences between the implementations of the ABTableWidget (QTableWidget) class and the (renamed since yesterday) ABDataFrameView (QTableView) class. Looking a bit deeper I think the sorting issue is caused by formatting the amounts as a string, at least for |
With all of the tables refactored to use view classes (which will actually show values as floats, booleans, strings, integers) I think this issue is now resolved. Will close it when the new stable version is released. |
Fixed in 2.3.3 Please give me a heads-up if this occurs again. |
The issue now isn't so much that the order is being messed up but that the sorting isn't being re-applied when the table is changed. Altering the cut-off causes AB to completely rebuild the underlying DataFrame (ordering it by index by default as you see in the image). I'm thinking that the relevant model or the view class can be improved by checking if sorting has been performed before it rebuilds the table and then applying the correct sorting afterwards. |
A minor issue: In the MLCA results Inventory Table, reordering the table by the content of a column which contains only numbers, orders them as strings, meaning by alphabetnumerical sequence rather than quantity.
The text was updated successfully, but these errors were encountered: