Documentation

Update

Description and parameters

int CCatalogStoreProduct::Update(
   int Id,
   array arFields
);

Method updates record parameters for ID according to data from array arFields. Static method.

Call parameters

Parameter Description ID Record ID for updating. arFieldsAssociative array with parameters, with keys as parameter names and corresponding values. Permitted keys:
  • PRODUCT_ID - product ID;
  • STORE_ID - warehouse ID;
  • AMOUNT - product quantity;

Returned value

Returns ID of updated record on success and false otherwise.

Examples

$arFields = Array(
		"PRODUCT_ID" => 25,
		"STORE_ID" => 3,
		"AMOUNT" => 4,
	);
	
	$ID = CCatalogStoreProduct::Update(1, $arFields);

© «Bitrix24», 2001-2024
Up