prepareImageAssociatedData example

$data = $this->prepareConfiguratorSet($data$article);

        // Need to set the tax data directly for following price calculations which use the tax object of the article         if (isset($data['tax'])) {
            $article->setTax($data['tax']);
        }

        if (isset($data['configuratorSet'])) {
            $article->setConfiguratorSet($data['configuratorSet']);
        }

        $data = $this->prepareImageAssociatedData($data$article);
        $data = $this->prepareAttributeAssociatedData($data$article);

        // The mainDetail gets its initial value for lastStock from $article, so this has to be set beforehand         if (isset($data['lastStock'])) {
            $article->setLastStock((bool) $data['lastStock']);
        }

        $data = $this->prepareMainDetail($data$article);
        $data = $this->prepareVariants($data$article);

        unset($data['images']);

        
// Format the posted extJs related product association         $data = $this->prepareRelatedAssociatedData($data$article);

        // Format the posted extJs related product streams association         $data = $this->prepareRelatedProductStreamsData($data);

        // Format the posted extJs similar product association         $data = $this->prepareSimilarAssociatedData($data$article);

        // Format the posted extJs product image data         $data = $this->prepareImageAssociatedData($data);

        // Format the posted extJs product link data         $data = $this->prepareLinkAssociatedData($data);

        // Format the posted extJs product download data         $data = $this->prepareDownloadAssociatedData($data);

        $data = $this->prepareConfiguratorTemplateData($data$article);

        return $data;
    }

    
Home | Imprint | This part of the site doesn't use cookies.