src/ShopBundle/objects/db/TShopOrderItem.class.php
protected function PostInsertHook()
    {
        parent::PostInsertHook();
        $oArticle = &$this->GetFieldShopArticle();
        if (!is_null($oArticle)) {
            $bNewAmountIsDelta = true;
            $bUpdateSaleCounter = true;
            $oArticle->UpdateStock(-1 * $this->fieldOrderAmount, $bNewAmountIsDelta, $bUpdateSaleCounter);
        }
    }
protected function PostInsertHook()
    {
        parent::PostInsertHook();
        $oArticle = &$this->GetFieldShopArticle();
        if (!is_null($oArticle)) {
            $bNewAmountIsDelta = true;
            $bUpdateSaleCounter = true;
            $oArticle->UpdateStock(-1 * $this->fieldOrderAmount, $bNewAmountIsDelta, $bUpdateSaleCounter);
        }
    }
protected function PostInsertHook ( ) { parent :: PostInsertHook ( ) ; $ oArticle = & $ this -> GetFieldShopArticle ( ) ; if ( ! is_null ( $ oArticle ) ) { $ bNewAmountIsDelta = true ; $ bUpdateSaleCounter = true ; $ oArticle -> UpdateStock ( - 1 * $ this -> fieldOrderAmount , $ bNewAmountIsDelta , $ bUpdateSaleCounter ) ; } }
use the method to up the sales count for the article.
use the method to up the sales count for the article .