1 (edited by anoopmb 12/26/2019 05:02:22 am)

Topic: Customer Payment Entry - Scrolling behaviour when clicking All or None

Hi,

if the list of Invoices are little long and when you go down and click on 'All' or 'None' the page will scroll to top.

this may be an unwanted behavior and to stop this change the below  code

File : includes/ui/allocation_cart.inc

line: 306-310

label_cell("<a href='#' name=Alloc$id onclick='allocate_all(this.name.substr(5));return true;'>"
                     . _("All") . "</a>");
                label_cell("<a href='#' name=DeAll$id onclick='allocate_none(this.name.substr(5));return true;'>"
                     . _("None") . "</a>".hidden("un_allocated" . $id, 
                     price_format($un_allocated), false));

to

label_cell("<a href='javascript:void(0)' name=Alloc$id onclick='allocate_all(this.name.substr(5));return true;'>"
                     . _("All") . "</a>");
                label_cell("<a href='javascript:void(0)' name=DeAll$id onclick='allocate_none(this.name.substr(5));return true;'>"
                     . _("None") . "</a>".hidden("un_allocated" . $id, 
                     price_format($un_allocated), false));
ANOOP
Experience is the name everyone gives to their mistakes!

Re: Customer Payment Entry - Scrolling behaviour when clicking All or None

This has been fixed and committed to stable 2.4.7. Thanks for seeing this.
The fixed file can be downloaded here.

/joe