Answer the question
In order to leave comments, you need to log in
How to track why the properties of active products are being deleted?
Hello! Such a problem: for about 2 months now, on the 1C Bitrix website, the properties of goods active on the site (various self-created properties such as manufacturer, sizes, etc.) have been deleted from time to time (about once every 6-7 days). ). That is, rows are physically deleted from the b_iblock_element_property table. You have to constantly backup and restore it. I noticed that inactive products retain their properties.
How can you track what happens at the time of deletion? Surely some kind of erroneous request to the database is coming? Or what else it could be - I have no idea. This is the first time I've come across this. The site is many years old and only recently this began to happen.
Answer the question
In order to leave comments, you need to log in
Most likely there is some kind of integration in which CIblockElement::Update
is used to change property values.
If the product has a set of properties: COLOR, COUNT, SIZE, then when using the following code, the value of the SIZE property will be lost
$el = new CIBlockElement;
$PROP = array();
$PROP["COLOR"] = "Белый";
$PROP["COUNT"] = 38;
$arLoadProductArray = Array(
"PROPERTY_VALUES"=> $PROP,
"NAME" => "Элемент",
);
$PRODUCT_ID = 2;
$res = $el->Update($PRODUCT_ID, $arLoadProductArray);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question