Skip to content
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

filter_condition_callback in Mage_Adminhtml_Block_Promo_Quote_Edit_Tab_Coupons_Grid not working? #4503

Open
Hanmac opened this issue Jan 21, 2025 · 2 comments
Assignees
Labels
bug review needed Problem should be verified

Comments

@Hanmac
Copy link
Contributor

Hanmac commented Jan 21, 2025

While checking some callbacks, I found this:

'filter_condition_callback' => [
Mage::getResourceModel('salesrule/coupon_collection'), 'addIsUsedFilterCallback',
],

Doesn't this get ignored by this?

if ($column->getFilterConditionCallback() && $column->getFilterConditionCallback()[0] instanceof self) {
call_user_func($column->getFilterConditionCallback(), $this->getCollection(), $column);

Mage::getResourceModel('salesrule/coupon_collection') is not an instance of Mage_Adminhtml_Block_Promo_Quote_Edit_Tab_Coupons_Grid

@sreichel
Copy link
Contributor

That change to Widget/Grid.php was part of 1.9.4.3 and has been discusses here.

@sreichel sreichel added the review needed Problem should be verified label Jan 22, 2025
@Hanmac
Copy link
Contributor Author

Hanmac commented Feb 7, 2025

That change to Widget/Grid.php was part of 1.9.4.3 and has been discusses here.

i know that the change happened long ago. I also understand the instanceof self check for security reasons.

Just that they forgot to change this part, because the callback can't happen anymore

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug review needed Problem should be verified
Projects
None yet
Development

No branches or pull requests

2 participants