Esempio n. 1
0
				</small></td>
			</tr>
			<tr class="section">
				<td colspan="2"><?php 
echo GetMessage('SL_FORM_LIST_FIELDS');
?>
</td>
			</tr>
			<tr>
				<td colspan="2"><table class="bx-width100" id="sp_fields"><tbody>
<?php 
$arFields = array();
foreach ($arResult['LIST']['FIELDS'] as $field) {
    $arFields[$field['Name']] = array($field['DisplayName'], $field['Name'] . ':' . $field['Type']);
}
$arTypes = CIntranetSharepoint::GetTypes($arParams['IBLOCK_ID']);
foreach ($arValue as $key => $value) {
    ?>
					<tr onclick="SLeditField(this)" name="<?php 
    echo htmlspecialcharsbx($arFields[$key][1] . '|' . $value);
    ?>
">
						<td><?php 
    echo htmlspecialcharsex($arFields[$key][0]);
    ?>
 (<?php 
    echo htmlspecialcharsex($key);
    ?>
)</td>
						<td><?php 
    echo htmlspecialcharsex($arTypes[$value]);
Esempio n. 2
0
     if ($STEP < 1) {
         $this->IncludeComponentTemplate('form_server');
     } elseif ($STEP < 2) {
         $this->IncludeComponentTemplate('form_error');
     } elseif ($STEP < 3) {
         $this->IncludeComponentTemplate('form_lists');
     } elseif ($STEP < 4) {
         $this->IncludeComponentTemplate('form_list');
     } elseif ($STEP >= 4) {
         $this->IncludeComponentTemplate('form_finish');
     }
     break;
 case 'info':
     $dbRes = CIntranetSharepoint::GetByID($arParams['IBLOCK_ID'], true);
     if ($arResult['SERVICE'] = $dbRes->Fetch()) {
         $arResult['TYPES'] = CIntranetSharepoint::GetTypes($arResult['SERVICE']['IBLOCK_ID']);
         $this->IncludeComponentTemplate('settings');
     }
     break;
 case 'sync':
     if (!check_bitrix_sessid()) {
         return;
     }
     set_time_limit(300);
     if ($_REQUEST['full']) {
         CIntranetSharepoint::ClearSyncData($arParams['IBLOCK_ID']);
     }
     if (!$_REQUEST['sync_action']) {
         if (!($arResult['RESULT'] = CIntranetSharepoint::RequestItemsNext($arParams['IBLOCK_ID'], array('SYNC_NUM_ROWS' => BX_INTRANET_SP_NUM_ROWS_MANUAL)))) {
             if ($ex = $APPLICATION->GetException()) {
                 $arResult['ERROR'] = $ex->GetString();