<?php require $_SERVER['DOCUMENT_ROOT'] . '/bitrix/modules/main/include/prolog_before.php'; include "bm.php"; $bm = new BitrixMigration('restore.php'); $bm->start();
<?php require $_SERVER['DOCUMENT_ROOT'] . '/bitrix/modules/main/include/prolog_before.php'; include "bm.php"; $arResult = array("0" => array("IBLOCK_TYPE_ID" => "requests", "LID" => "ru", "NAME" => "Заявки", "SECTION_NAME" => "", "ELEMENT_NAME" => "", "ID" => "requests", "SECTIONS" => "Y", "EDIT_FILE_BEFORE" => "", "EDIT_FILE_AFTER" => "", "IN_RSS" => "N", "SORT" => "500", "IBLOCKS" => array("0" => array("ID" => "3", "IBLOCK_TYPE_ID" => "requests", "CODE" => "students_requests", "NAME" => "Заявки студентов", "ACTIVE" => "Y", "SORT" => "500", "LIST_PAGE_URL" => "#SITE_DIR#/requests/index.php?ID=#IBLOCK_ID#", "DETAIL_PAGE_URL" => "#SITE_DIR#/request.php?ID=#ELEMENT_ID#", "SECTION_PAGE_URL" => "#SITE_DIR#/requests/list.php?SECTION_ID=#SECTION_ID#", "INDEX_ELEMENT" => "Y", "INDEX_SECTION" => "Y", "WORKFLOW" => "N", "BIZPROC" => "N", "SECTION_CHOOSER" => "L", "LIST_MODE" => "", "RIGHTS_MODE" => "S", "VERSION" => "2", "EDIT_FILE_BEFORE" => "", "EDIT_FILE_AFTER" => "", "SECTIONS_NAME" => "Разделы", "SECTION_NAME" => "Раздел", "ELEMENTS_NAME" => "Элементы", "ELEMENT_NAME" => "Элемент", "SITE_ID" => array("0" => "s1"), "PROPS" => array("TYPE" => array("NAME" => "Укажите вид справки", "ACTIVE" => "Y", "SORT" => "500", "CODE" => "TYPE", "PROPERTY_TYPE" => "L", "MULTIPLE" => "N", "FILE_TYPE" => "", "MULTIPLE_CNT" => "5", "LINK_IBLOCK_ID" => "0", "IS_REQUIRED" => "N", "USER_TYPE" => "", "VALUES" => array("0" => array("VALUE" => "Заявление на допуск к экзамену", "DEF" => "N", "SORT" => "100", "EXTERNAL_ID" => "ADMISSION_TO_EXAMINATION"), "1" => array("VALUE" => "Справка (выписка из приказа)", "DEF" => "N", "SORT" => "200", "EXTERNAL_ID" => "OUT_OF_ORDER"), "2" => array("VALUE" => "Справка (о подтверждении факта обучения))", "DEF" => "N", "SORT" => "300", "EXTERNAL_ID" => "PROOF_OF_LEARNING"))), "STATUS" => array("NAME" => "Статус", "ACTIVE" => "Y", "SORT" => "500", "CODE" => "STATUS", "PROPERTY_TYPE" => "L", "MULTIPLE" => "N", "FILE_TYPE" => "", "MULTIPLE_CNT" => "5", "LINK_IBLOCK_ID" => "0", "IS_REQUIRED" => "N", "USER_TYPE" => "", "VALUES" => array("0" => array("VALUE" => "Новый запрос", "DEF" => "N", "SORT" => "100", "EXTERNAL_ID" => "NEW_REQUEST"), "1" => array("VALUE" => "Зарегистрирован", "DEF" => "N", "SORT" => "200", "EXTERNAL_ID" => "REGISTERED"), "2" => array("VALUE" => "В обработке", "DEF" => "N", "SORT" => "300", "EXTERNAL_ID" => "DEALING"), "3" => array("VALUE" => "Отказано (недостатчно данных)", "DEF" => "N", "SORT" => "400", "EXTERNAL_ID" => "DENIED_NOT_ENOUGH_DATA"), "4" => array("VALUE" => "Обработано", "DEF" => "N", "SORT" => "500", "EXTERNAL_ID" => "PROCESSED"))), "USER_ID" => array("NAME" => "Привязка к пользователю", "ACTIVE" => "Y", "SORT" => "500", "CODE" => "USER_ID", "PROPERTY_TYPE" => "S", "MULTIPLE" => "N", "FILE_TYPE" => "", "MULTIPLE_CNT" => "5", "LINK_IBLOCK_ID" => "0", "IS_REQUIRED" => "N", "USER_TYPE" => "UserID"), "AGREEMENT" => array("NAME" => "Обработка персональных данных", "ACTIVE" => "Y", "SORT" => "500", "CODE" => "AGREEMENT", "PROPERTY_TYPE" => "L", "MULTIPLE" => "Y", "FILE_TYPE" => "", "MULTIPLE_CNT" => "5", "LINK_IBLOCK_ID" => "0", "IS_REQUIRED" => "Y", "USER_TYPE" => "", "VALUES" => array("0" => array("VALUE" => "Даю согласие на передачу и обработку персональных данных", "DEF" => "N", "SORT" => "500", "EXTERNAL_ID" => "YES_I_DO"))), "OTHER_FIELDS_VALUES" => array("NAME" => "Значение дополнительных полей", "ACTIVE" => "Y", "SORT" => "500", "CODE" => "OTHER_FIELDS_VALUES", "PROPERTY_TYPE" => "S", "MULTIPLE" => "N", "FILE_TYPE" => "", "MULTIPLE_CNT" => "5", "LINK_IBLOCK_ID" => "0", "IS_REQUIRED" => "N", "USER_TYPE" => ""), "WS_CODE" => array("NAME" => "Код заявки", "ACTIVE" => "Y", "SORT" => "500", "CODE" => "WS_CODE", "PROPERTY_TYPE" => "S", "MULTIPLE" => "N", "FILE_TYPE" => "", "MULTIPLE_CNT" => "5", "LINK_IBLOCK_ID" => "0", "IS_REQUIRED" => "N", "USER_TYPE" => ""))))), "1" => array("IBLOCK_TYPE_ID" => "services", "LID" => "ru", "NAME" => "Сервисы", "SECTION_NAME" => "", "ELEMENT_NAME" => "", "ID" => "services", "SECTIONS" => "Y", "EDIT_FILE_BEFORE" => "", "EDIT_FILE_AFTER" => "", "IN_RSS" => "N", "SORT" => "500", "IBLOCKS" => array())); $bm = new BitrixMigration(); $bm->uploadArray($arResult);