Esempio n. 1
0
	public function executeComponent()
	{
		$this->IBLOCK_ID = $this->arParams["IBLOCK_ID"];
		$this->SECTION_ID = $this->arParams["SECTION_ID"];
		$this->FILTER_NAME = $this->arParams["FILTER_NAME"];
		$this->SAFE_FILTER_NAME = htmlspecialcharsbx($this->FILTER_NAME);

		if (self::$catalogIncluded === null)
			self::$catalogIncluded = Loader::includeModule('catalog');
		if (self::$catalogIncluded)
		{
			$arCatalog = CCatalogSKU::GetInfoByProductIBlock($this->IBLOCK_ID);
			if (!empty($arCatalog))
			{
				$this->SKU_IBLOCK_ID = $arCatalog["IBLOCK_ID"];
				$this->SKU_PROPERTY_ID = $arCatalog["SKU_PROPERTY_ID"];
			}
		}

		/*DEMO CODE for "pure" class.php component
		$this->arResult["FFF"] = "ggg";
		$this->includeComponentTemplate();
		return $this->ELEMENT_ID;
		*/

		return parent::executeComponent();
	}
Esempio n. 2
0
 public function executeComponent()
 {
     parent::setFramemode(false);
     $this->userId = $this->arParams["USER_ID"];
     $this->fUserId = $this->arParams["FUSER_ID"];
     $this->weightKoef = $this->arParams["WEIGHT_KOEF"];
     $this->weightUnit = $this->arParams["WEIGHT_UNIT"];
     $this->columns = $this->arParams["COLUMNS_LIST"];
     $this->offersProps = $this->arParams["OFFERS_PROPS"];
     $this->quantityFloat = $this->arParams["QUANTITY_FLOAT"];
     $this->countDiscount4AllQuantity = $this->arParams["COUNT_DISCOUNT_4_ALL_QUANTITY"];
     $this->priceVatShowValue = $this->arParams["PRICE_VAT_SHOW_VALUE"];
     $this->hideCoupon = $this->arParams["HIDE_COUPON"];
     $this->usePrepayment = $this->arParams["USE_PREPAYMENT"];
     $this->pathToOrder = $this->arParams["PATH_TO_ORDER"];
     return parent::executeComponent();
 }
Esempio n. 3
0
 public function executeComponent()
 {
     $this->IBLOCK_ID = $this->arParams["IBLOCK_ID"];
     $this->SECTION_ID = $this->arParams["SECTION_ID"];
     $this->FILTER_NAME = $this->arParams["FILTER_NAME"];
     if (CModule::IncludeModule("catalog")) {
         $arCatalog = CCatalog::GetSkuInfoByProductID($this->IBLOCK_ID);
         if (is_array($arCatalog)) {
             $this->SKU_IBLOCK_ID = $arCatalog["IBLOCK_ID"];
             $this->SKU_PROPERTY_ID = $arCatalog["SKU_PROPERTY_ID"];
         }
     }
     /*DEMO CODE for "pure" class.php component
     		$this->arResult["FFF"] = "ggg";
     		$this->includeComponentTemplate();
     		return $this->ELEMENT_ID;
     		*/
     return parent::executeComponent();
 }
Esempio n. 4
0
	public function executeComponent()
	{
		$this->IBLOCK_ID = $this->arParams["IBLOCK_ID"];
		$this->SECTION_ID = $this->arParams["SECTION_ID"];
		$this->FILTER_NAME = $this->arParams["FILTER_NAME"];
		$this->SAFE_FILTER_NAME = htmlspecialcharsbx($this->FILTER_NAME);

		if (self::$catalogIncluded === null)
			self::$catalogIncluded = Loader::includeModule('catalog');
		if (self::$catalogIncluded)
		{
			$arCatalog = CCatalogSKU::GetInfoByProductIBlock($this->IBLOCK_ID);
			if (!empty($arCatalog))
			{
				$this->SKU_IBLOCK_ID = $arCatalog["IBLOCK_ID"];
				$this->SKU_PROPERTY_ID = $arCatalog["SKU_PROPERTY_ID"];
			}
		}

		$this->facet = new \Bitrix\Iblock\PropertyIndex\Facet($this->IBLOCK_ID);

		return parent::executeComponent();
	}
Esempio n. 5
0
 public function executeComponent()
 {
     $this->IBLOCK_ID = $this->arParams["IBLOCK_ID"];
     $this->SECTION_ID = $this->arParams["SECTION_ID"];
     $this->FILTER_NAME = $this->arParams["FILTER_NAME"];
     $this->SAFE_FILTER_NAME = htmlspecialcharsbx($this->FILTER_NAME);
     if ($this->arParams["CONVERT_CURRENCY"] && $this->arParams["CURRENCY_ID"] != "" && Loader::includeModule('currency')) {
         $currencyList = \Bitrix\Currency\CurrencyTable::getList(array('select' => array('CURRENCY'), 'filter' => array('=CURRENCY' => $this->arParams['CURRENCY_ID'])));
         if ($currency = $currencyList->fetch()) {
             $this->convertCurrencyId = $currency['CURRENCY'];
         }
     }
     if (self::$iblockIncluded === null) {
         self::$iblockIncluded = Loader::includeModule('iblock');
     }
     if (!self::$iblockIncluded) {
         return '';
     }
     if (self::$catalogIncluded === null) {
         self::$catalogIncluded = Loader::includeModule('catalog');
     }
     if (self::$catalogIncluded) {
         $arCatalog = CCatalogSKU::GetInfoByProductIBlock($this->IBLOCK_ID);
         if (!empty($arCatalog)) {
             $this->SKU_IBLOCK_ID = $arCatalog["IBLOCK_ID"];
             $this->SKU_PROPERTY_ID = $arCatalog["SKU_PROPERTY_ID"];
         }
     }
     $this->facet = new \Bitrix\Iblock\PropertyIndex\Facet($this->IBLOCK_ID);
     return parent::executeComponent();
 }