ui-grid icon indicating copy to clipboard operation
ui-grid copied to clipboard

Accessing external scope in column header cell templates

Open wattsbn opened this issue 12 years ago • 6 comments

I am trying to add a column in 3.0 that mimics the functionality that the showSelectionCheckbox option provides in the 2.x version. I can make the column header be a simple checkbox using the headerCellTemplate property on the column def, but the scope that is available to the header doesn't seem to have access the the getExternalScopes function like the cell templates do. I can get around this by attaching the data I need to one of the objects that I do have access to (Grid, GridOptions, GirdColumn, or GridApi). However, I'm guessing that is not what you are intending us to do. I also don't see the headerCellTemplate feature documented in the 3.0 docs.

wattsbn avatar Sep 25 '14 17:09 wattsbn

I am facing the same issue, do we have fix for this in un-stable version?

nmeeda avatar Oct 15 '14 21:10 nmeeda

+1

delijah avatar Oct 20 '14 15:10 delijah

I think this has been completed in an earlier commit by @swalters, on that basis closing.

PaulL1 avatar Nov 04 '14 05:11 PaulL1

Could you tell us how this is working now? I couldn't find anything that helps me to implement this correctly.

delijah avatar Nov 04 '14 08:11 delijah

Yes, it looks like it works now. @delijah It works just the same as in cell templates. See the following documentation. http://ui-grid.info/docs/#/tutorial/305_externalScopes

wattsbn avatar Nov 04 '14 13:11 wattsbn

Oh, ok. I'll try it like that then.. Thanks a lot!!!

delijah avatar Nov 04 '14 14:11 delijah