Documentation

CheckFields

Description and parameters

bool
CCatalogGroup::CheckFields(
 string ACTION,
 array &arFields,
 int ID = 0
);

Method serves for checking parameters, passed to methods CCatalogGroup::Add and CCatalogGroup::Update. Non-static method.

Call parameters

Parameter Description
ACTION Indicates the method to be checked. Possible values:
arFields Associative array with price type parameters. Permissible keys:
  • BASE - Flag (Y/N) for base type.
  • NAME - price type internal name. Key is required, if $ACTION = 'ADD'.
  • SORT - Sort index.
  • XML_ID - External code.
  • CREATED_BY - ID for user who created price type.
  • MODIFIED_BY - ID for recent user who updated price type.
  • USER_GROUP - Array with user group codes, with members having permission to view prices of this type. Key is required, if $ACTION = 'ADD'.
  • USER_GROUP_BUY - Array with user group codes, with members having permission to purchase products with prices of this type. Key is required, if $ACTION = 'ADD'.
  • USER_LANG - Associative array with language-dependent parameters for price type, with keys as language codes and values as price type names on a corresponding language.
ID Price type code. Parameter is optional and applicable only for $ACTION = 'UPDATE'.

Returned value

Returns true in case passed parameters are correct, otherwise - false. In case methods returned false, you can get error text via $APPLICATION->GetException().

See Also


© «Bitrix24», 2001-2024
Up