Exemplo n.º 1
0
	function ActionDoGroup($id, $action_id, $add_params='')
	{
		/** @global CMain $APPLICATION */
		global $APPLICATION;
		return $this->table_id.".GetAdminList('".CUtil::AddSlashes($APPLICATION->GetCurPage())."?ID=".CUtil::AddSlashes($id)."&action_button=".CUtil::AddSlashes($action_id)."&lang=".LANGUAGE_ID."&".freetrix_sessid_get().($add_params<>""?"&".CUtil::AddSlashes($add_params):"")."');";
	}
Exemplo n.º 2
0
<?php 
foreach ($arModules as $info) {
    ?>
	<tr>
		<td><b><?php 
    echo htmlspecialcharsex($info["MODULE_NAME"]);
    ?>
</b> <?php 
    echo htmlspecialcharsex(strlen($info["MODULE_PARTNER"]) > 0 ? " <b><i>(" . str_replace(array("#NAME#", "#URI#"), array($info["MODULE_PARTNER"], $info["MODULE_PARTNER_URI"]), GetMessage("MOD_PARTNER_NAME")) . ")</i></b>" : "(" . $info["MODULE_ID"] . ")");
    ?>
<br><?php 
    echo $info["MODULE_DESCRIPTION"];
    ?>
</td>
		<td ondblclick="<?php 
    echo htmlspecialcharsbx("DoAction(event, 'version_down', '" . CUtil::AddSlashes($info["MODULE_ID"]) . "')");
    ?>
" id="version_for_<?php 
    echo htmlspecialcharsbx($info["MODULE_ID"]);
    ?>
"><?php 
    echo $info["MODULE_VERSION"];
    ?>
</td>
		<td nowrap><?php 
    echo CDatabase::FormatDate($info["MODULE_VERSION_DATE"], "YYYY-MM-DD HH:MI:SS", CLang::GetDateFormat("SHORT"));
    ?>
</td>
		<td nowrap><?php 
    if ($info["IsInstalled"]) {
        echo GetMessage("MOD_INSTALLED");
Exemplo n.º 3
0
		$str = GetMessage("MOD_MAIN_DESCRIPTION");
		echo $str;?></td>
		<td ondblclick="<?echo htmlspecialcharsbx("DoAction(event, 'version_down', 'main')")?>" id="version_for_main">0.1</td>
		<td nowrap>xxx</td>
		<td><?php 
echo GetMessage("MOD_INSTALLED");
?>
</td>
		<td>&nbsp;</td>
	</tr>
<?
foreach($arModules as $info) :
?>
	<tr>
		<td><b><?echo htmlspecialcharsex($info["MODULE_NAME"])?></b> <?echo htmlspecialcharsex(strlen($info["MODULE_PARTNER"]) > 0? " <b><i>(".str_replace(array("#NAME#", "#URI#"), array($info["MODULE_PARTNER"], $info["MODULE_PARTNER_URI"]), GetMessage("MOD_PARTNER_NAME")).")</i></b>" : "(".$info["MODULE_ID"].")") ?><br><?echo $info["MODULE_DESCRIPTION"]?></td>
		<td ondblclick="<?echo htmlspecialcharsbx("DoAction(event, 'version_down', '".CUtil::AddSlashes($info["MODULE_ID"])."')")?>" id="version_for_<?echo htmlspecialcharsbx($info["MODULE_ID"])?>"><?echo $info["MODULE_VERSION"]?></td>
		<td nowrap><?echo CDatabase::FormatDate($info["MODULE_VERSION_DATE"], "YYYY-MM-DD HH:MI:SS", CLang::GetDateFormat("SHORT"));?></td>
		<td nowrap><?if($info["IsInstalled"]):?><?echo GetMessage("MOD_INSTALLED")?><?else:?><span class="required"><?echo GetMessage("MOD_NOT_INSTALLED")?></span><?endif?></td>
		<td>
			<form action="<?echo $APPLICATION->GetCurPage()?>" method="GET" id="form_for_<?echo htmlspecialcharsbx($info["MODULE_ID"])?>">
				<input type="hidden" name="action" value="" id="action_for_<?echo htmlspecialcharsbx($info["MODULE_ID"])?>">
				<input type="hidden" name="lang" value="<?echo LANG?>">
				<input type="hidden" name="id" value="<?echo htmlspecialcharsbx($info["MODULE_ID"])?>">
				<?php 
echo freetrix_sessid_post();
?>
				<?if($info["IsInstalled"]):?>
					<input <?if (!$isAdmin || $info["MODULE_ID"] == 'fileman' || $info["MODULE_ID"] == 'intranet') echo "disabled" ?> type="submit" name="uninstall" value="<?echo GetMessage("MOD_DELETE")?>">
				<?else:?>
					<input <?if (!$isAdmin) echo "disabled" ?> type="submit" class="adm-btn-green" name="install" value="<?echo GetMessage("MOD_INSTALL_BUTTON")?>">
				<?endif?>
Exemplo n.º 4
0
 public static function OnAdminListDisplay(&$obList)
 {
     global $USER;
     if ($obList->table_id !== "tbl_fileman_admin") {
         return;
     }
     if (!is_object($USER) || !$USER->CanDoOperation("clouds_upload")) {
         return;
     }
     static $clouds = null;
     if (!isset($clouds)) {
         $clouds = array();
         $rsClouds = CCloudStorageBucket::GetList(array("SORT" => "DESC", "ID" => "ASC"));
         while ($arStorage = $rsClouds->Fetch()) {
             if ($arStorage["READ_ONLY"] == "N" && $arStorage["ACTIVE"] == "Y") {
                 $clouds[$arStorage["ID"]] = $arStorage["BUCKET"];
             }
         }
     }
     if (empty($clouds)) {
         return;
     }
     foreach ($obList->aRows as $obRow) {
         if ($obRow->arRes["TYPE"] === "F") {
             $ID = "F" . $obRow->arRes["NAME"];
             $file = $obRow->arRes["NAME"];
             $path = substr($obRow->arRes["ABS_PATH"], 0, -strlen($file));
             $arSubMenu = array();
             foreach ($clouds as $id => $bucket) {
                 $arSubMenu[] = array("TEXT" => $bucket, "ACTION" => $s = "if(confirm('" . GetMessage("CLO_STORAGE_UPLOAD_CONF") . "')) jsUtils.Redirect([], '" . CUtil::AddSlashes("/bitrix/admin/clouds_file_list.php?lang=" . LANGUAGE_ID . "&bucket=" . urlencode($id) . "&path=" . urlencode($path) . "&ID=" . urlencode($ID) . "&action=upload&" . bitrix_sessid_get()) . "');");
             }
             $obRow->aActions[] = array("TEXT" => GetMessage("CLO_STORAGE_UPLOAD_MENU"), "MENU" => $arSubMenu);
         }
     }
 }
Exemplo n.º 5
0
	public static function GenerateInput($id, $arInfo, $curVal=false, $context='default')
	{
		$res = '<input type="checkbox" id="'.htmlspecialcharsbx('ACT_'.$id).'" '.($curVal===false?'':'checked').' name="'.htmlspecialcharsbx('OPTIONS['.$context.']['.$id.']').'" value="Y" title="'.GetMessage("CTRLR_GRP_REASSIGN").
			'" onclick="'.htmlspecialcharsbx('document.getElementById(\''.CUtil::AddSlashes($id).'\').disabled=!this.checked;if(this.checked)document.getElementById(\''.CUtil::AddSlashes($id).'\').focus();').'">';
		if($curVal===false)
			$strDis = ' disabled ';
		else
			$strDis = '';

		$arInput = $arInfo[2];
		if($arInput[0]=='checkbox')
		{
			$res .= '<select name="'.htmlspecialcharsbx('OPTIONS['.$context.']['.$id.']').'" id="'.htmlspecialcharsbx($id).'"'.$strDis.'>'.
			'<option value="N">'.GetMessage("CTRLR_GRP_OPT_NO").'</option>'.
			'<option value="Y"'.($curVal!==false && $curVal=='Y'?' selected':'').'>'.GetMessage("CTRLR_GRP_OPT_YES").'</option>'.
			'</select>';
		}
		elseif($arInput[0]=='text')
		{
			$res .= '<input type="text" name="'.htmlspecialcharsbx('OPTIONS['.$context.']['.$id.']').'" '.$strDis.'id="'.htmlspecialcharsbx($id).
				'" size="'.htmlspecialcharsbx($arInput[1]).'" value="'.htmlspecialcharsbx($curVal===false?$arInput[2]:$curVal).'">';
		}
		elseif($arInput[0]=='selectbox')
		{
			$res .= '<select name="'.htmlspecialcharsbx('OPTIONS['.$context.']['.$id.']').'" '.$strDis.'id="'.htmlspecialcharsbx($id).'">';
			foreach($arInput[1] as $enum_id => $enum_value)
			{
				$res .= '<option value="'.htmlspecialcharsbx($enum_id).'"'.
					($curVal!==false && $curVal==$enum_id?' selected':'').
					'>'.htmlspecialcharsEx($enum_value).'</option>';
			}
			$res .= '</select>';
		}
		elseif($arInput[0]=="textarea")
		{
			$res .= '<br><textarea rows="'.htmlspecialcharsbx($arInput[1]).'" cols="'.htmlspecialcharsbx($arInput[2]).'" name="'.htmlspecialcharsbx('OPTIONS['.$context.']['.$id.']').'" '.$strDis.' id="'.htmlspecialcharsbx($id).'">'.htmlspecialcharsbx($curVal===false? $arInput[3]: $curVal).'</textarea>';
		}

		return $res;
	}
Exemplo n.º 6
0
		}
		if ($safe_for_html)
		{
			$name = htmlspecialcharsbx($name);
			$description = htmlspecialcharsbx($description);
		}
	}
}

/***************************************************************************
							Обработка GET | POST
****************************************************************************/
$arrUsers = array();
$TICKET_LIST_URL = strlen($TICKET_LIST_URL)>0? CUtil::AddSlashes(htmlspecialcharsbx((substr($TICKET_LIST_URL, 0, 4) == 'http'?'':'/').$TICKET_LIST_URL)) : "ticket_list.php";
$TICKET_EDIT_URL = strlen($TICKET_EDIT_URL)>0? CUtil::AddSlashes(htmlspecialcharsbx((substr($TICKET_EDIT_URL, 0, 4) == 'http'?'':'/').$TICKET_EDIT_URL)) : "ticket_edit.php";
$TICKET_MESSAGE_EDIT_URL = strlen($TICKET_MESSAGE_EDIT_URL)>0? CUtil::AddSlashes(htmlspecialcharsbx((substr($TICKET_MESSAGE_EDIT_URL, 0, 4) == 'http'?'':'/').$TICKET_MESSAGE_EDIT_URL)) : "ticket_message_edit.php";

if (strlen($tf)<=0)
{
	$tf = ${COption::GetOptionString("main", "cookie_name", "BITRIX_SM")."_TICKET_FILTER"};
}
if (strlen($tf)<=0)
{
	$tf = "none";
}



$sTableID = "t_ticket_list";

if ($bADS)
Exemplo n.º 7
0
    echo empty($str_MESSAGE) ? 'style="display: none;"' : '';
    ?>
>
				<td>&nbsp;</td>
				<td>
					<?php 
    $arEmailFromList = \Bitrix\Sender\MailingChainTable::getEmailFromList();
    ?>
					<?php 
    echo GetMessage("sender_chain_edit_field_email_from_last");
    ?>
					<?php 
    foreach ($arEmailFromList as $email) {
        ?>
					<a class="sender-link-email" onclick="SetAddressToControl('EMAIL_FROM', '<?php 
        echo CUtil::AddSlashes(htmlspecialcharsbx($email));
        ?>
')">
						<?php 
        echo htmlspecialcharsbx($email);
        ?>
						</a><?php 
        echo end($arEmailFromList) == $email ? '' : ',';
        ?>
					<?php 
    }
    ?>
				</td>
			</tr>

			<tr class="hidden-when-show-template-list" <?php 
Exemplo n.º 8
0
                            }
                        }
                    }
                }
                if ($strError != "") {
                    $e = $APPLICATION->GetException();
                    if (!is_object($e)) {
                        $e = new CApplicationException($strError);
                    }
                    $message = new CAdminMessage(GetMessage("CLO_STORAGE_FILE_UPLOAD_ERROR"), $e);
                }
                if (is_object($message)) {
                    echo $message->Show();
                    $message = null;
                } elseif ($moveResult == CCloudStorage::FILE_PARTLY_UPLOADED) {
                    CAdminMessage::ShowMessage(array("TYPE" => "PROGRESS", "MESSAGE" => GetMessage("CLO_STORAGE_FILE_UPLOAD_IN_PROGRESS"), "DETAILS" => GetMessage("CLO_STORAGE_FILE_UPLOAD_PROGRESS", array("#bytes#" => CFile::FormatSize($bytes), "#file_size#" => CFile::FormatSize($fileSize))) . "#PROGRESS_BAR#", "HTML" => true, "PROGRESS_TOTAL" => $fileSize, "PROGRESS_VALUE" => $bytes, "BUTTONS" => array(array("VALUE" => GetMessage("CLO_STORAGE_FILE_STOP"), "ONCLICK" => 'window.location = \'' . CUtil::AddSlashes("/bitrix/admin/clouds_file_list.php?lang=" . urlencode(LANGUAGE_ID) . "&bucket=" . urlencode($obBucket->ID) . "&path=" . urlencode($path)) . '\''))));
                } else {
                    CAdminMessage::ShowMessage(array("MESSAGE" => GetMessage("CLO_STORAGE_FILE_UPLOAD_DONE"), "DETAILS" => GetMessage("CLO_STORAGE_FILE_UPLOAD_PROGRESS", array("#bytes#" => CFile::FormatSize($bytes), "#file_size#" => CFile::FormatSize($fileSize))), "HTML" => true, "TYPE" => "OK"));
                    ?>
<script>
					<?php 
                    echo $sTableID;
                    ?>
.GetAdminList('<?php 
                    echo CUtil::JSEscape($APPLICATION->GetCurPage() . '?lang=' . urlencode(LANGUAGE_ID) . '&bucket=' . urlencode($obBucket->ID) . '&path=' . urlencode($path));
                    ?>
');
				</script><?php 
                }
                require $_SERVER["DOCUMENT_ROOT"] . BX_ROOT . "/modules/main/include/epilog_admin_js.php";
            case "upload":
Exemplo n.º 9
0
    private static function GetFinderItemStructureItem($arParams, $arItem)
    {
        $arResult['PROVIDER'] = CUtil::AddSlashes($arParams['PROVIDER']);
        $arResult['ID'] = CUtil::AddSlashes($arItem['ID']);
        $arResult['AVATAR'] = CUtil::AddSlashes($arItem['AVATAR']);
        $arResult['NAME'] = htmlspecialcharsEx($arItem['NAME']);
        $arResult['DESC'] = empty($arItem['DESC']) ? '&nbsp;' : htmlspecialcharsEx($arItem['DESC']);
        $html = '<a href="#' . $arResult['ID'] . '" class="bx-finder-company-department-employee bx-finder-element" rel="' . $arResult['ID'] . '" onclick="return BX.Finder.onAddItem(\'' . $arResult['PROVIDER'] . '\', \'structure\', this, \'' . $arResult['ID'] . '\')" hidefocus="true">
						<div class="bx-finder-company-department-employee-icon"></div>
						<div class="bx-finder-company-department-employee-info">
							<div class="bx-finder-company-department-employee-name">' . $arResult['NAME'] . '</div>
							<div class="bx-finder-company-department-employee-position">' . $arResult['DESC'] . '</div>
						</div>
						<div style="' . (strlen($arResult['AVATAR']) > 0 ? 'background:url(\'' . $arResult['AVATAR'] . '\') no-repeat center center' : '') . '" class="bx-finder-company-department-employee-avatar"></div>
					</a>';
        return $html;
    }
Exemplo n.º 10
0
					<span class="adm-fn"><?=GetMessage('sender_chain_edit_field_email_from_desc')?></span>
				</td>
				<td>
					<input type="text" id="EMAIL_FROM" name="EMAIL_FROM" value="<?=$str_EMAIL_FROM?>">
				</td>
			</tr>

			<tr class="hidden-when-show-template-list" <?=(empty($str_MESSAGE) ? 'style="display: none;"' : '')?>>
				<td>&nbsp;</td>
				<td>
					<?
					$arEmailFromList = \Bitrix\Sender\MailingChainTable::getEmailFromList();
					?>
					<?echo GetMessage("sender_chain_edit_field_email_from_last")?>
					<?foreach($arEmailFromList as $email):?>
					<a class="sender-link-email" onclick="SetAddressToControl('EMAIL_FROM', '<?=CUtil::AddSlashes(htmlspecialcharsbx($email))?>')">
						<?=htmlspecialcharsbx($email)?>
						</a><?=(end($arEmailFromList)==$email ? '' : ',')?>
					<?endforeach?>
				</td>
			</tr>

			<tr class="hidden-when-show-template-list" <?=(empty($str_MESSAGE) ? 'style="display: none;"' : '')?>>
				<td colspan="2">&nbsp;</td>
			</tr>

			<tr class="adm-detail-required-field hidden-when-show-template-list" <?=(empty($str_MESSAGE) ? 'style="display: none;"' : '')?>>
				<td colspan="2" align="left">
					<div class="adm-detail-content-item-block">
						<span class="adm-detail-content-item-block-span"><?=GetMessage("sender_chain_edit_field_message")?></span>
						<?=\Bitrix\Sender\TemplateTable::initEditor(array(