Exemplo n.º 1
0
 public function getProduct(ConnectionInterface $con = null, $locale = null)
 {
     $product = parent::getProduct($con);
     $translation = $product->getTranslation($locale);
     if ($translation->isNew()) {
         if (ConfigQuery::getDefaultLangWhenNoTranslationAvailable()) {
             $locale = Lang::getDefaultLanguage()->getLocale();
         }
     }
     $product->setLocale($locale);
     return $product;
 }
Exemplo n.º 2
0
 /**
  * @param CartItem $cartItem The cartItem object to add.
  */
 protected function doAddCartItem($cartItem)
 {
     $this->collCartItems[] = $cartItem;
     $cartItem->setProductSaleElements($this);
 }
Exemplo n.º 3
0
 /**
  * @param CartItem $cartItem The cartItem object to add.
  */
 protected function doAddCartItem($cartItem)
 {
     $this->collCartItems[] = $cartItem;
     $cartItem->setCart($this);
 }