-
-
Notifications
You must be signed in to change notification settings - Fork 436
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixed row click issue in product's upsell/crosssell/related grids #3865
Conversation
Row click issue in Category Products tab
@fballiano - I created this PR directly in Github. There are two commits coming from a previous PR. Please fix this issue for me. Thank you. |
For this one /js/mage/adminhtml/grid.js |
this should be ok |
Many thanks. This one is ready for testing. |
Thank you for this one! |
question, since this PR modifies js/mage/adminhtml/grid.js, isn't it affecting all grids in all backend? |
I have checked all the grids in the Backend and the change in this PR affects only the grids that do not have an associated action on a row. Let's take a few examples. For the products grid in Catalog > Manage Products, when you bring the mouse pointer on a row, it becomes a hand. There is an link for the editing action. All grids that have an action column have the same behavior. For the subscribers grid in Newsletter > Newsletter Subscriber, the selection is made only on the first column where the checkbox is and not on the whole row as it was until now. TODO 1: Checking the grids that have actions associated on a row, I noticed a problem that will have to be fixed in another PR. Check/Uncheck on the first column is done only in the checkbox square, if you click a little outside, the page specific to the action is loaded. Selecting a row must be done in the entire cell, not just in the checkbox square only. TODO 2: For grids that do not have action on a row such as Related Products / Up-sells / Cross-sells / Newsletter Subscribers, the mouse pointer must remain the arrow and not the hand that symbolizes that there is a link. This problem must be fixed in another PR too. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tested, works. couldn't find any other grid affected by this change
When you add/remove/set position in the Related Products / Up-sells / Cross-sells grids, you may face an important issue without realizing it. As the grid functionality was thought by the Magento team, when you click on a row, regardless of the position where the mouse pointer is, the row will be checked or unchecked. As soon as you press any of the [Save] buttons, products may appear or disappear in the grid by mistake. I faced this issue many times when I was editing the position and I didn't click exactly in the box but a little next to it.
This PR solves the issue and limits the row click strictly to the grid cell where the checkbox is (the first column). Unlike the Products grid, where the box must be checked strictly in the square, otherwise the product editing page is loaded, this modification is more permissive and the click can be in the entire cell where the box is located (td element).