Beispiel #1
0
         $updateArray['status'] = 1;
         $updateArray['page_uid'] = $this->showCatalogFromPage;
         // custom hook that can be controlled by third-party plugin
         if (is_array($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['ext/multishop/scripts/admin_pages/admin_import.php']['insertSpecialsPricePreHook'])) {
             $params = array('updateArray' => &$updateArray, 'item' => &$item, 'prefix_source_name' => $this->post['prefix_source_name']);
             foreach ($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['ext/multishop/scripts/admin_pages/admin_import.php']['insertSpecialsPricePreHook'] as $funcRef) {
                 \TYPO3\CMS\Core\Utility\GeneralUtility::callUserFunction($funcRef, $params, $this);
             }
         }
         // custom hook that can be controlled by third-party plugin eof
         $query = $GLOBALS['TYPO3_DB']->INSERTquery('tx_multishop_specials', $updateArray);
         if (!($res = $GLOBALS['TYPO3_DB']->sql_query($query))) {
             $erno[] = $query . '<br/>' . $GLOBALS['TYPO3_DB']->sql_error();
         }
     }
     mslib_befe::saveImportedProductImages($item['added_products_id'], $this->post['input'], $item);
     // lets add this new product eof
 }
 // new attribute
 // first delete if any
 if (!$this->post['incremental_update'] and $products_id) {
     $query = $GLOBALS['TYPO3_DB']->DELETEquery('tx_multishop_products_attributes', 'products_id=' . $products_id . ' and (page_uid=0 or page_uid=' . $this->showCatalogFromPage . ')');
     $res = $GLOBALS['TYPO3_DB']->sql_query($query);
 }
 if (is_array($item['attribute_option_value_including_vat'])) {
     // these attributes need further processing since the prices are including VAT
     // we will substract the VAT of each option value and then copy it to the traditional $item['attribute_option_value'] array
     foreach ($item['attribute_option_value_including_vat'] as $option_row) {
         if ($option_row[2] > 0) {
             // if attribute option value has price
             if (substr_count($option_row[2], '.') > 1) {