Skip to content

Conversation

@jasonlikescats
Copy link

Calls to getCellDisplayValue would throw when flatEntityAccess was enabled. Fixes #5326.

I took the liberty of moving the check for the flatEntityAccess option into GridRow's getEntityQualifiedColField, which looks to be a general entry point for getting the row entities "accessor". It makes more sense to me to check in here rather than to branch functionality elsewhere (which also places the burden on the caller and could lead to accidental bugs).

Also, just a note that getCellDisplayValue may still be broken for the case of using $$col.uid accessors...I'm not too familiar with how that all works (and it's outside the scope of the bug I was trying to fix), so I'm not able to verify that at this time. This is just a heads up given that it looks like it suffers from the same root issue (calling $parse with a value rather than a value "accessor"). Maybe someone can confirm and create an issue?

@JLLeitschuh
Copy link
Contributor

Do you have a plunker to show the before and after?
I'm not 100% sure I understand what the issue is but I haven't touched this code before.

@jasonlikescats
Copy link
Author

There's a plunker for the before in the issue I referenced above (#5326). I'm not too sure how to make a plunker for the after...can I hotlink from plunker to the source file from the pull request directly on Github?

@JLLeitschuh
Copy link
Contributor

I'm not sure. I have seen it done but I don't know.

@jasonlikescats
Copy link
Author

Hmm, fair enough. Another angle that might help is running the unit test I added against the original code, and with my pull request changes. Otherwise I can probably find some time this weekend to put together an "after" plunker.

@dlgski
Copy link
Contributor

dlgski commented Nov 7, 2016

@jasonlikescats We are making an effort to update ui-grid with all the contributing PRs. This PR is now out-of-date as gridRow.js has already been updated in 65e49fd Can you update this PR if it still resolves an issue? Thank you!

@mportuga
Copy link
Member

mportuga commented Dec 5, 2016

Closing due to lack of response.

@mportuga mportuga closed this Dec 5, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

5 participants