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

Urgent Problem - Scrumbled Grid

Open dontforgettocompile opened this issue 11 years ago • 8 comments

scrumbled grid

Hi :-) i'm having some trouble with the ui-grid. its not always but pretty often. i come from a state an the grid looks scrumbled (sorry i dont know how to call that ;) ) i thought it would be some caching problem, so i added {reload: true} to my state.go. But the problem is still existing. Do you have heard of that before? is there an easy way to solve this?

Best Regards

dontforgettocompile avatar Sep 17 '15 13:09 dontforgettocompile

Are you using custom cell templates?

JLLeitschuh avatar Sep 18 '15 15:09 JLLeitschuh

no, rowTemplate to create a mouse hover effect like that: if (initOptions.rowTemplate === 'ui-grid/ui-grid-row') { initOptions.rowTemplate = '<div ng-click="grid.appScope.fnOne(row)" ' + ' ng-mouseleave="$parent.hover=false"' + ' ng-mouseenter="$parent.hover=true"' + ' ng-class="{ 'rowhover': $parent.hover}" ' + ' ng-repeat="col in colContainer.renderedColumns track by col.colDef.name" class="ui-grid-cell" ui-grid-cell>

'; }

dontforgettocompile avatar Sep 21 '15 13:09 dontforgettocompile

Try using directive stacking instead, You will get better performance and you are less likely to have issues with future versions.

JLLeitschuh avatar Sep 22 '15 15:09 JLLeitschuh

what do you mean by directive stacking?

dontforgettocompile avatar Sep 23 '15 07:09 dontforgettocompile

I have a similar problem. I have only one ui-grid on the screen. When I scroll right and then left again it redraws correctly

image

cjp666 avatar Sep 25 '15 14:09 cjp666

Have a look at how all of the features are written. You can define a directive that extends the functionality of another directive.

On 10:38, Fri, Sep 25, 2015 cjp666 [email protected] wrote:

I have a similar problem. I have only one ui-grid on the screen. When I scroll right and then left again it redraws correctly

[image: image] https://cloud.githubusercontent.com/assets/4498931/10103359/5956ef16-639b-11e5-9cc7-9d5ba2e64548.png

— Reply to this email directly or view it on GitHub https://github.com/angular-ui/ui-grid/issues/4387#issuecomment-143240534 .

JLLeitschuh avatar Sep 25 '15 17:09 JLLeitschuh

I'm sorry but I do not understand what you mean or are telling us what to do

cjp666 avatar Sep 28 '15 08:09 cjp666

Figured out the problem I was having

My ui-grid was being loaded as part of an ng-include but the grid options where set-up beforehand and the data loaded later. I have changed the code so that when the template url is set and the data loaded, I also set up the column definitions at this point which sorted the problem I was having

Hope this makes sense

cjp666 avatar Sep 30 '15 11:09 cjp666