Topic: In db_pager can we freeze first few columns
Hello, is it possible in FA to get first few columns freezed in db_pager_view?
It's much more fun, when you can discuss your problems with others...
You are not logged in. Please login or register.
FrontAccounting forum → FA Modifications → In db_pager can we freeze first few columns
Hello, is it possible in FA to get first few columns freezed in db_pager_view?
I have successfully implemented this jquery solution for column and header freeze.
But I am stuck that once a page is reloaded due to Ajax Call then the following Jquery Function at the bottom of the page is not called.
<script>
$(document).ready(function() {
$(".table-scrollable").freezeTable({
'scrollable': true,
'columnNum' : 5,
});
});
</script>
Hello friends, need support on this
Now I understand what you are looking for - if you are not totally committed to using js then:-
css only answer here on stackoverflow and here using position: sticky;
Can I use lists all major browsers except as usual IE.
You may have to add auto scroll or similar to the table as well
Lots of answers on SO and other sites with googling "freeze table header and columns css site:stackoverflow.com"
For 1st five of anything use something like :nth-child(-n+5)
No js = no js conflicts
There are also a few minimal js solutions too using the same search as above
Thanks @poncho1234 you have suggested a non javascript solution.
But still my question is that how to get the Jquery Function workable after Ajax Call. My problem is discussed here. I have tried them but could not find workable in FA.
My js is yuk!...but my understanding of that SO post is $(document).ready() is already called somewhere else so you need something else to initialize it????????????????????????????????????????
The 'top' answer seems like the one you want, it's in the comments...read 1 - 3 for that solution they had to replace the $(document).ready() to $(document).on... or something else in the third comment.
Hope that hasn't confused you more and you get it working
hi,
You can use like this
$js = "alert('Hi')";
if (in_ajax()) {
$Ajax->addScript(true, $js);
} else
add_js_source($js);
this code will retain after ajax also
if you are using any jquery plugin and your jquery is loaded in footer part of renderer
then you have to load the plugin in renderer after jquery (it will be loaded on all pages)
or you can customize the core and define a function to load javascript files in footer
add_js_ufile() function is there but it will load in header only
Hi @anoopmb your suggestion worked like a charm. I prefer to customize the core aand load JS in the footer.
Thanks Alot you have saved a lot of hassle for me.
I would request @joe to add such features in the upcoming 2.5
FrontAccounting forum → FA Modifications → In db_pager can we freeze first few columns
Powered by PunBB, supported by Informer Technologies, Inc.
Currently installed 4 official extensions. Copyright © 2003–2009 PunBB.