$strWarning = 'Ок!';
$DB->StartTransaction();
if(!CIBlockElement::Delete(1))
{
X
X
$strWarning = 'Error!';
}
if(!CIBlockElement::Delete(2))
{
X
X
$strWarning = 'Error!';
}
if(!CIBlockElement::Delete(3))
{
X
X
$strWarning = 'Error!';
}
if($strWarning == 'Error!')
{
$DB->Rollback();
}
else
$DB->Commit();
|