Closed
Description
Preconditions (*)
- vanilla Magento CE 2.3.*
- chrome browser
- vanilla with sample data
Steps to reproduce (*)
- got to product list, search or advance search page
- open developer tools -> network(tab)(Chrome browser)
- Select/click any of the toolbar option like Grid/List, Sort By, or show X per page
- Network(Chrome Browser) selected/clicked link triggering two time and because of two time trigger backed doing twice process after canceled one also.
(for verify put any log in to catalog->product->list controller).
Expected result (*)
- Link should trigger once only or binding of event make once with
vendor/magento/module-catalog/view/frontend/web/js/product/list/toolbar.js
Actual result (*)
- On click/change link trigger two times
Solution
File: vendor/magento/module-catalog/view/frontend/web/js/product/list/toolbar.js::_create(
_create: function () {
if(window.isToolbarLoaded)
return;
this._bind($(this.options.modeControl), this.options.mode, this.options.modeDefault);
this._bind($(this.options.directionControl), this.options.direction, this.options.directionDefault);
this._bind($(this.options.orderControl), this.options.order, this.options.orderDefault);
this._bind($(this.options.limitControl), this.options.limit, this.options.limitDefault);
window.isToolbarLoaded = true;
},
Metadata
Metadata
Assignees
Labels
The issue has been fixed in 2.4-develop branchGate 2 Passed. Manual verification of the issue description passedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedGate 1 Passed. Automatic verification of issue format passedGate 4. Acknowledged. Issue is added to backlog and ready for developmentMay be fixed according to the position in the backlog.The issue has been reproduced on latest 2.4-develop branchAffects non-critical data or functionality and does not force users to employ a workaround.