Documentation

catalog.productPropertySection.set

Scope: catalog Permissions to execute: for all

catalog.productPropertySection.set(propertyId, fields)

Method sets (creates or updates) product or SKU property sections.

Parameters

ParameterType Description
propertyIdinteger Identifier for product property or SKU.
fieldsobject Array, containing the following fields:
  • smartFilter – show in smart filter (Y/N);
  • displayType – smart filter view; possible values:
    • "F" – flags;
    • "K" – radio butons;
    • "P" – drop=down list.
  • displayExpanded – show expanded (Y/N);
  • filterHint – hint in smart filter for visitors.

Example

BX24.callMethod(
    'catalog.productPropertySection.set', 
    {
	  propertyId: 128,
	  fields: {	      
		displayType: "F",
		displayExpanded: "Y",
		filterHint: "Product dimensions"
	  }
	}, 
    function(result)
    {
        if(result.error())
            console.error(result.error().ex);
        else
            console.log(result.data());
});

© «Bitrix24», 2001-2024