Documentation

catalog.product.offer.update

Scope: catalog Permissions: all

catalog.product.offer.update(id, fields)

Method updates SKU fields.

Parameters

ParameterType Description
idinteger SKU ID.
fieldsobject Fields, matching to the available list of getFieldsByFilter.:
  • iblockId - type of information block;
  • productType - product type;
  • iblockSectionId - section identifier;
  • name - name.
All fields are required.


Examples

BX24.callMethod(
    'catalog.product.offer.update', 
    {
	  id: 8,
	  fields: {	      
		iblockId: 27	      
		active: "N",
		code: "t-shirt2",
		detailText: "Awesome t-shirt",
		sort: 350
	  }
    }, 
    function(result)
    {
        if(result.error())
            console.error(result.error().ex);
        else
            console.log(result.data());
});

© «Bitrix24», 2001-2024