From 5265c5d5c8fe9bc225e24818f1313e87c1992c4b Mon Sep 17 00:00:00 2001 From: "m.korolev" Date: Mon, 23 Sep 2013 18:16:26 +0400 Subject: [PATCH] Delete update.php --- intaro.intarocrm/update.php | 109 ------------------------------------ 1 file changed, 109 deletions(-) delete mode 100644 intaro.intarocrm/update.php diff --git a/intaro.intarocrm/update.php b/intaro.intarocrm/update.php deleted file mode 100644 index 29166cfb..00000000 --- a/intaro.intarocrm/update.php +++ /dev/null @@ -1,109 +0,0 @@ - "Y", "FILE_NAME" => "intarocrm") -); -while ($arProfile = $dbProfile->Fetch()) -{ - $PROFILE_ID = intval($arProfile["ID"]); - - parse_str($arProfile['SETUP_VARS']); - - $propertiesSKU = Array(); - $propertiesProduct = Array(); - - foreach ($IBLOCK_EXPORT as $iblock) { - - $propertiesSKU[$iblock] = Array( - "article" => null, - "manufacturer" => null, - "color" => null, - "weight" => null, - "size" => null, - ); - - $propertiesProduct[$iblock] = Array( - "article" => $IBLOCK_PROPERTY_ARTICLE[$iblock], - "manufacturer" => null, - "color" => null, - "weight" => null, - "size" => null, - ); - } - - $strVars = GetProfileSetupVars($IBLOCK_EXPORT, $propertiesProduct, $propertiesSKU, $SETUP_FILE_NAME); - - CCatalogExport::Update( - $PROFILE_ID, - array( - "SETUP_VARS" => $strVars - ) - ); - - -} - -function GetProfileSetupVars($iblocks, $propertiesProduct, $propertiesSKU, $filename) { - - $strVars = ""; - foreach ($iblocks as $key => $val) - $strVars .= 'IBLOCK_EXPORT[' . $key . ']=' . $val . '&'; - foreach ($propertiesSKU as $iblock => $arr) - foreach ($arr as $id => $val) - $strVars .= 'IBLOCK_PROPERTY_SKU[' . $iblock . '][' . $id . ']=' . $val . '&'; - foreach ($propertiesProduct as $iblock => $arr) - foreach ($arr as $id => $val) - $strVars .= 'IBLOCK_PROPERTY_PRODUCT[' . $iblock . '][' . $id . ']=' . $val . '&'; - - $strVars .= 'SETUP_FILE_NAME=' . urlencode($filename); - - return $strVars; -}