Friday 10 November 2006 7:22:02 am
ok, Quick and dirty, but it can be a basic for next steps foward : checkout.php
include_once( "kernel/classes/ezuserdiscountrule.php" );
.............
$customer = $order->attribute( 'user_id' );
eZUserDiscountRule::removeUser( $customer );
include_once( 'kernel/classes/ezcontentcachemanager.php' );
eZContentCacheManager::clearAllContentCache();
back from paypal the user is removed from the discount group and the content cache is cleared to avoid confusion for the customer (strike prices, etc...) if he wants to goone buying while is still login. Kernel's hack is not the best solution :( but it seems to works well like that :))) Hope this help. Regards. Laurent Ps : if someone has a hint to include that a cleaner way, that's will be welcome.
|