本文整理汇总了PHP中CAdminNotify::Error方法的典型用法代码示例。如果您正苦于以下问题:PHP CAdminNotify::Error方法的具体用法?PHP CAdminNotify::Error怎么用?PHP CAdminNotify::Error使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CAdminNotify
的用法示例。
在下文中一共展示了CAdminNotify::Error方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: foreach
foreach ($propertyValues as $propertyValue) {
$variantIdId = $list[$propertyValue['value']];
$valuesToElements[$propertyValue['id_element']][] = $variantIdId;
}
foreach ($valuesToElements as $elementId => $elementValues) {
$iblockElement->SetPropertyValuesEx($elementId, $idIBlock, array($idProperty => $elementValues));
}
return true;
};
if ($_POST['apply'] == 'Применить') {
$iblockID = intval($_POST['selectIblocks']);
$propertyID = intval($_POST['selectProperties']);
$newTypeIBlock = $_POST['new-type-property-info-block'];
$conversionResult = $conversionProperty($propertyID, $iblockID, $newTypeIBlock);
$conversionResult && CAdminNotify::Add(array('MESSAGE' => 'Конвертация прошла успешно', 'TAG' => 'save_property_notify', 'MODULE_ID' => 'ws.tools', 'ENABLE_CLOSE' => 'Y'));
!$conversionResult && CAdminNotify::Error(array('MESSAGE' => 'Конвертация не прошла успешно', 'TAG' => 'save_property_notify_error', 'MODULE_ID' => 'ws.tools', 'ENABLE_CLOSE' => 'Y'));
}
require $_SERVER["DOCUMENT_ROOT"] . "/bitrix/modules/main/include/prolog_admin_after.php";
$jsParams = array();
$types = array();
$rsTypes = \Bitrix\Iblock\TypeLanguageTable::getList(array('filter' => array('LANGUAGE_ID' => LANG)));
while ($type = $rsTypes->fetch()) {
$types[$type['IBLOCK_TYPE_ID']] = $type['NAME'];
}
$jsParams['types'] = array('name' => 'selectTypes', 'list' => $types);
$iblocks = array();
$rsIblocks = \Bitrix\Iblock\IblockTable::getList();
while ($iblock = $rsIblocks->fetch()) {
$iblocks[$iblock['ID']] = array('name' => $iblock['NAME'], 'type' => $iblock['IBLOCK_TYPE_ID']);
}
$jsParams['iblocks'] = array('name' => 'selectIblocks', 'list' => $iblocks);