Метод repairApplyRules
Сигнатура метода
private static function repairApplyRules(int $templateId, array $triggers): void
Возвращает:
void
Описание
Writes the rebuilt columns of the rows that still carry no rules, and only those. The repair runs in the background and races the regular sync of a template save: both write the same row by the same primary key, and neither path locks it. A merge would win that race with a snapshot read before the save, rolling the row back to the reaction mode and the target document the user has just replaced - and a row with rules of its own never comes back to the selection, so the next save is what fixes it. Hence the condition of the selection is repeated in the write itself. An UPDATE also keeps the repair a repair: a row deleted by a parallel template save is not resurrected, and a node the table knows nothing about gets no row - storing rows belongs to the sync path.
Параметры
2| Имя | Тип | По умолчанию | Флаги |
|---|---|---|---|
$templateId
|
int
|
—
|
—
|
$triggers
|
array
|
—
|
—
|
Расположение
Исходный файл метода в Bitrix Framework
~/bitrix/modulesbizproc/lib/workflow/template/entity/workflowtemplatetrigger.php