EasyUI Forum

General Category => EasyUI for jQuery => Topic started by: roberto on February 06, 2019, 07:51:02 AM



Title: datagrid scrollbar [SOLVED]
Post by: roberto on February 06, 2019, 07:51:02 AM
Hi
How to use nicescroll with datagrid?
tks,


Title: Re: datagrid scrollbar
Post by: jarry on February 06, 2019, 05:12:55 PM
Please refer to this topic https://www.jeasyui.com/forum/index.php?topic=7620.msg19952#msg19952


Title: Re: datagrid scrollbar
Post by: roberto on February 06, 2019, 05:31:00 PM
tks, I did it before but did not work on datagrid
Code:
        $('#dg').data('datagrid').dc.body2.niceScroll();




Title: Re: datagrid scrollbar
Post by: jarry on February 06, 2019, 11:38:34 PM
This example works fine.

http://code.reloado.com/odoqaz4/edit#preview


Title: Re: datagrid scrollbar
Post by: roberto on February 07, 2019, 04:54:38 AM
thank you so much for your time

It worked but stopped after the refresh button was clicked
btw: it stop working after any king of redraw operation
on your example: changing the column width
the vertical scroolbar disapear but the horizontal keeps working


Title: Re: datagrid scrollbar
Post by: jarry on February 07, 2019, 07:16:10 AM
This is the updated example http://code.reloado.com/odoqaz4/2/edit#preview
When the resizing is done, please reset the width of the vertical scrollbar.
Code:
var view2 = $(this).data('datagrid').dc.view2;
view2.children('.nicescroll-rails-vr').width(8);


Title: Re: datagrid scrollbar
Post by: roberto on February 07, 2019, 01:38:11 PM
 ;D Just perfect!

Thank you very much!