当前位置: 首页>>代码示例>>PHP>>正文


PHP CAdminList::EditAction方法代码示例

本文整理汇总了PHP中CAdminList::EditAction方法的典型用法代码示例。如果您正苦于以下问题:PHP CAdminList::EditAction方法的具体用法?PHP CAdminList::EditAction怎么用?PHP CAdminList::EditAction使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在CAdminList的用法示例。


在下文中一共展示了CAdminList::EditAction方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: array

    }
}
$orderConvert = array('CURR' => 'CURRENCY', 'DATE' => 'DATE_RATE');
if (!isset($by)) {
    $by = 'DATE_RATE';
}
$by = strtoupper($by);
if (isset($orderConvert[$by])) {
    $by = $orderConvert[$by];
}
if (!isset($order)) {
    $order = 'DESC';
}
$order = strtoupper($order);
$rateOrder = array($by => $order);
if ($CURRENCY_RIGHT == "W" && $adminList->EditAction()) {
    /** @global array $FIELDS */
    foreach ($FIELDS as $ID => $arFields) {
        $ID = (int) $ID;
        if (!$adminList->IsUpdated($ID)) {
            continue;
        }
        $arCurR = CCurrencyRates::GetByID($ID);
        $arFields["CURRENCY"] = $arCurR["CURRENCY"];
        $res = CCurrencyRates::Update($ID, $arFields);
        if (!$res) {
            if ($e = $APPLICATION->GetException()) {
                $adminList->AddUpdateError(GetMessage("SAVE_ERROR") . $ID . ": " . str_replace("<br>", " ", $e->GetString()), $ID);
            }
        }
    }
开发者ID:akniyev,项目名称:itprom_dobrohost,代码行数:31,代码来源:currencies_rates.php

示例2: CAdminSorting

    // system's epilog
    exit;
}
require_once $_SERVER["DOCUMENT_ROOT"] . "/bitrix/modules/learning/prolog.php";
IncludeModuleLangFile(__FILE__);
$sTableID = "t_learning_group_admin";
$oSort = new CAdminSorting($sTableID, "ID", "desc");
// sort initializing
$lAdmin = new CAdminList($sTableID, $oSort);
// list initializing
$filter = new CAdminFilter($sTableID . "_filter", array(GetMessage('LEARNING_ADMIN_GROUPS_TITLE'), 'ID', GetMessage('LEARNING_ADMIN_GROUPS_ACTIVE'), GetMessage('LEARNING_ADMIN_GROUPS_CODE'), GetMessage('LEARNING_ADMIN_GROUPS_COURSE_TITLE'), GetMessage('LEARNING_ADMIN_GROUPS_COURSE_LESSON_ID'), GetMessage('LEARNING_ADMIN_GROUPS_SORT'), GetMessage('LEARNING_ADMIN_GROUPS_ACTIVE_FROM'), GetMessage('LEARNING_ADMIN_GROUPS_ACTIVE_TO')));
$arFilterFields = array("filter_title", "filter_id", "filter_active", "filter_code", "filter_course_title", "filter_course_lesson_id", "filter_sort", "filter_active_from_from", "filter_active_from_to", "filter_active_to_from", "filter_active_to_to");
$lAdmin->InitFilter($arFilterFields);
// filter initializing
$arFilter = array('ID' => $filter_id, 'ACTIVE' => $filter_active, 'TITLE' => $filter_title, 'CODE' => $filter_code, 'SORT' => $filter_sort, '>=ACTIVE_FROM' => $filter_active_from_from, '<=ACTIVE_FROM' => $filter_active_from_to, '>=ACTIVE_TO' => $filter_active_to_from, '<=ACTIVE_TO' => $filter_active_to_to, 'COURSE_TITLE' => $filter_course_title, 'COURSE_LESSON_ID' => $filter_course_lesson_id);
if ($lAdmin->EditAction()) {
    foreach ($FIELDS as $ID => $arFields) {
        if (!$lAdmin->IsUpdated($ID)) {
            continue;
        }
        if (!CLearningGroup::update((int) $ID, $arFields)) {
            if ($e = $APPLICATION->GetException()) {
                $lAdmin->AddUpdateError(GetMessage("SAVE_ERROR") . $ID . ": " . $e->GetString(), $ID);
            }
        }
    }
}
// group and single actions processing
if ($arID = $lAdmin->GroupAction()) {
    if ($_REQUEST['action_target'] == 'selected') {
        $rsData = CLearningGroup::GetList(array($by => $order), $arFilter);
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:31,代码来源:learn_group_admin.php

示例3: foreach

            $arFilter[">MAILING_UNSUBSCRIPTION.MAILING_ID"] = 0;
            $needGroup = true;
        } else {
            $arFilter["=MAILING_UNSUBSCRIPTION.MAILING_ID"] = $find_unsubscribed;
        }
    }
    foreach ($arFilter as $k => $v) {
        if (!in_array($k, array('=CONTACT_LIST.LIST_ID', '>MAILING_UNSUBSCRIPTION.MAILING_ID', '>MAILING_SUBSCRIPTION.MAILING_ID')) && empty($v)) {
            unset($arFilter[$k]);
        }
    }
}
if (isset($order)) {
    $order = $order == 'asc' ? 'ASC' : 'DESC';
}
if ($lAdmin->EditAction() && $POST_RIGHT == "W") {
    foreach ($FIELDS as $ID => $arFields) {
        if (!$lAdmin->IsUpdated($ID)) {
            continue;
        }
        $connection = \Bitrix\Main\Application::getInstance()->getConnection();
        $connection->startTransaction();
        $ID = IntVal($ID);
        $dataPrimary = array('ID' => $ID);
        $arData = \Bitrix\Sender\ContactTable::getRowById($dataPrimary);
        if ($arData) {
            foreach ($arFields as $key => $value) {
                $arData[$key] = $value;
            }
            unset($arData['ID']);
            $dataUpdateDb = \Bitrix\Sender\ContactTable::update($dataPrimary, $arData);
开发者ID:Hawkart,项目名称:megatv,代码行数:31,代码来源:contact_admin.php

示例4: CAdminSorting

<?php

require_once $_SERVER["DOCUMENT_ROOT"] . "/bitrix/modules/main/include/prolog_admin_before.php";
require_once $_SERVER["DOCUMENT_ROOT"] . "/bitrix/modules/currency/include.php";
$CURRENCY_RIGHT = $APPLICATION->GetGroupRight("currency");
if ($CURRENCY_RIGHT == "D") {
    $APPLICATION->AuthForm(GetMessage("ACCESS_DENIED"));
}
__IncludeLang(GetLangFileName($_SERVER["DOCUMENT_ROOT"] . "/bitrix/modules/currency/lang/", "/currencies.php"));
require_once $_SERVER["DOCUMENT_ROOT"] . "/bitrix/modules/currency/prolog.php";
$sTableID = "t_currencies";
$oSort = new CAdminSorting($sTableID, "sort", "asc");
$lAdmin = new CAdminList($sTableID, $oSort);
if ($lAdmin->EditAction() && $CURRENCY_RIGHT == "W") {
    foreach ($FIELDS as $ID => $arFields) {
        $ID = substr($ID, 0, 3);
        if (!$lAdmin->IsUpdated($ID)) {
            continue;
        }
        if (!CCurrency::Update($ID, $arFields)) {
            if ($ex = $APPLICATION->GetException()) {
                $lAdmin->AddUpdateError(GetMessage("CURRENCY_SAVE_ERR", array("#ID#" => $ID, "#ERROR_TEXT#" => $ex->GetString())), $ID);
            } else {
                $lAdmin->AddUpdateError(GetMessage("CURRENCY_SAVE_ERR2", array("#ID#" => $ID)), $ID);
            }
        }
    }
}
if ($CURRENCY_RIGHT == "W" && ($arID = $lAdmin->GroupAction())) {
    if ($_REQUEST['action_target'] == 'selected') {
        $rsData = CCurrency::GetList($by, $order);
开发者ID:k-kalashnikov,项目名称:geekcon_new,代码行数:31,代码来源:currencies.php

示例5: array

$arFilterFields = array("filter_user_id", "filter_login", "filter_user", "filter_active");
$lAdmin->InitFilter($arFilterFields);
$arFilter = array();
if (IntVal($filter_user_id) > 0) {
    $arFilter["USER_ID"] = IntVal($filter_user_id);
}
if (strlen($filter_login) > 0) {
    $arFilter["USER_LOGIN"] = $filter_login;
}
if (strlen($filter_user) > 0) {
    $arFilter["%USER_USER"] = $filter_user;
}
if (strlen($filter_active) > 0) {
    $arFilter["ACTIVE"] = $filter_active;
}
if ($lAdmin->EditAction() && $saleModulePermissions >= "W") {
    foreach ($FIELDS as $ID => $arFields) {
        $DB->StartTransaction();
        $ID = IntVal($ID);
        if (!$lAdmin->IsUpdated($ID)) {
            continue;
        }
        if (!CSaleUserCards::Update($ID, $arFields)) {
            if ($ex = $APPLICATION->GetException()) {
                $lAdmin->AddUpdateError($ex->GetString(), $ID);
            } else {
                $lAdmin->AddUpdateError(str_replace("#ID#", $ID, GetMessage("SCA_ERROR_UPDATE")), $ID);
            }
            $DB->Rollback();
        }
        $DB->Commit();
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:31,代码来源:ccards_admin.php

示例6: array

$arFilterFields = array("find_name", "find_id", "find_user_type", "find_server", "find_server_type", "find_active", "find_lid");
if ($lAdmin->IsDefaultFilter()) {
    $find_user_type = 'admin';
    $set_filter = 'Y';
}
$lAdmin->InitFilter($arFilterFields);
//инициализация фильтра
$arFilter = array("ID" => $find_id, "NAME" => $find_name, "LID" => $find_lid, "SERVER_TYPE" => $find_server_type, "SERVER" => $find_server, "ACTIVE" => $find_active);
if ($find_user_type == 'user') {
    $arFilter['!USER_ID'] = 0;
} else {
    if ($find_user_type == 'admin') {
        $arFilter['USER_ID'] = 0;
    }
}
if ($MOD_RIGHT == "W" && $lAdmin->EditAction()) {
    foreach ($FIELDS as $ID => $arFields) {
        $ID = intval($ID);
        if (!$lAdmin->IsUpdated($ID)) {
            continue;
        }
        $DB->StartTransaction();
        if (!CMailBox::Update($ID, $arFields)) {
            $e = $APPLICATION->GetException();
            $lAdmin->AddUpdateError(GetMessage("MAIL_SAVE_ERROR") . " #" . $ID . ": " . $e->GetString(), $ID);
            $DB->Rollback();
        }
        $DB->Commit();
    }
}
// обработка действий групповых и одиночных
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:31,代码来源:mail_mailbox_admin.php

示例7: CAdminList

##############################################
$strError = "";
require_once $_SERVER["DOCUMENT_ROOT"] . "/bitrix/modules/main/include/prolog_admin_before.php";
require_once $_SERVER["DOCUMENT_ROOT"] . BX_ROOT . "/modules/main/prolog.php";
define("HELP_FILE", "settings/sites/template_admin.php");
$edit_php = $USER->CanDoOperation('edit_php');
if (!$edit_php && !$USER->CanDoOperation('view_other_settings') && !$USER->CanDoOperation('lpa_template_edit')) {
    $APPLICATION->AuthForm(GetMessage("ACCESS_DENIED"));
}
IncludeModuleLangFile(__FILE__);
$sTableID = "tbl_template";
$lAdmin = new CAdminList($sTableID, $oSort);
if ($_REQUEST['mode'] == 'list' || $_REQUEST['mode'] == 'frame') {
    CFile::DisableJSFunction(true);
}
if ($lAdmin->EditAction() && $edit_php) {
    foreach ($FIELDS as $ID => $arFields) {
        if (!$lAdmin->IsUpdated($ID)) {
            continue;
        }
        $ob = new CSiteTemplate();
        if (!$ob->Update($ID, $arFields)) {
            $lAdmin->AddUpdateError(GetMessage("SAVE_ERROR") . $ID . ": " . $ob->LAST_ERROR, $ID);
        }
    }
}
if (($arID = $lAdmin->GroupAction()) && $edit_php) {
    if ($_REQUEST['action_target'] == 'selected') {
        $arID = array();
        $rsData = CSiteTemplate::GetList($by, $order, array());
        while ($arRes = $rsData->Fetch()) {
开发者ID:k-kalashnikov,项目名称:geekcon_new,代码行数:31,代码来源:template_admin.php

示例8: CAdminContextMenu

    $context = new CAdminContextMenu($aContext);
    $context->Show();
    CAdminMessage::ShowMessage(GetMessage("LEARNING_BAD_COURSE"));
    require $_SERVER["DOCUMENT_ROOT"] . "/bitrix/modules/main/include/epilog_admin.php";
    die;
}
$sTableID = "t_test_admin";
$oSort = new CAdminSorting($sTableID, "sort", "asc");
// sort initializing
$lAdmin = new CAdminList($sTableID, $oSort);
// list initializing
$arFilterFields = array("filter_name", "filter_active");
$lAdmin->InitFilter($arFilterFields);
// filter initializing
$arFilter = array("ACTIVE" => $filter_active, "?NAME" => $filter_name, "COURSE_ID" => $COURSE_ID);
if (!$isReadOnly && $lAdmin->EditAction()) {
    foreach ($FIELDS as $ID => $arFields) {
        $ID = intval($ID);
        if (!$lAdmin->IsUpdated($ID)) {
            continue;
        }
        $DB->StartTransaction();
        $ob = new CTest();
        if (!$ob->Update($ID, $arFields)) {
            if ($e = $APPLICATION->GetException()) {
                $e = $APPLICATION->GetException();
                $lAdmin->AddUpdateError(GetMessage("SAVE_ERROR") . $ID . ": " . $e->GetString(), $ID);
                $DB->Rollback();
            }
        }
        $DB->Commit();
开发者ID:Satariall,项目名称:izurit,代码行数:31,代码来源:learn_test_admin.php

示例9: foreach

 foreach ($columns as $code => $fld) {
     $arFilterFields[] = 'find_' . $code;
     $arFilterTitles[] = $fld['title'];
 }
 $sTableID = "tbl_external_service_list";
 $oFilter = new CAdminFilter($sTableID . "_filter", $arFilterTitles);
 $oSort = new CAdminSorting($sTableID, "SORT", "asc");
 $lAdmin = new CAdminList($sTableID, $oSort);
 $lAdmin->InitFilter($arFilterFields);
 // order, select and filter for the list
 $listParams = Helper::proxyListRequest('list');
 #####################################
 #### ACTIONS
 #####################################
 global $DB;
 if ($lAdmin->EditAction() && $userIsAdmin) {
     foreach ($FIELDS as $id => $arFields) {
         $DB->StartTransaction();
         if (!$lAdmin->IsUpdated($id)) {
             // if there were no data change on this row - do nothing with it
             continue;
         }
         try {
             $res = Helper::update($id, $arFields);
             if (!empty($res['errors'])) {
                 foreach ($res['errors'] as &$error) {
                     $error = '&nbsp;&nbsp;' . $error;
                 }
                 unset($error);
                 throw new Main\SystemException(implode(',<br />', $res['errors']));
             }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:31,代码来源:location_external_service_list.php

示例10: CAdminSorting

require_once $_SERVER["DOCUMENT_ROOT"] . FX_ROOT . "/modules/main/prolog.php";
define("HELP_FILE", "settings/culture_admin.php");
if (!$USER->CanDoOperation('edit_other_settings') && !$USER->CanDoOperation('view_other_settings')) {
    $APPLICATION->AuthForm(GetMessage("ACCESS_DENIED"));
}
$isAdmin = $USER->CanDoOperation('edit_other_settings');
use Freetrix\Main;
use Freetrix\Main\Localization\CultureTable;
use Freetrix\Main\Localization\Loc;
Loc::loadMessages(__FILE__);
$tableID = "tbl_culture";
$sorting = new CAdminSorting($tableID, "name", "asc");
$adminList = new CAdminList($tableID, $sorting);
/** @var $request Main\HttpRequest */
$request = Main\Context::getCurrent()->getRequest();
if ($adminList->EditAction() && $isAdmin) {
    foreach ($request["FIELDS"] as $ID => $arFields) {
        if (!$adminList->IsUpdated($ID)) {
            continue;
        }
        $result = CultureTable::update($ID, $arFields);
        if (!$result->isSuccess()) {
            $adminList->AddUpdateError("(ID=" . $ID . ") " . implode("<br>", $result->getErrorMessages()), $ID);
        }
    }
}
if (($arID = $adminList->GroupAction()) && $isAdmin) {
    if ($request['action_target'] == 'selected') {
        $arID = array();
        $data = CultureTable::getList();
        while ($culture = $data->fetch()) {
开发者ID:ASDAFF,项目名称:open_bx,代码行数:31,代码来源:culture_admin.php

示例11: array

        $res = array("TODO" => 0, "DONE" => 0);
    }
    if ($res["TODO"] == 0) {
        CAdminMessage::ShowMessage(array("TYPE" => "OK", "HTML" => true, "MESSAGE" => GetMessage("customrank_saved")));
    } else {
        CAdminMessage::ShowMessage(array("TYPE" => "PROGRESS", "HTML" => true, "MESSAGE" => GetMessage("customrank_progress"), "DETAILS" => "#PROGRESS_BAR#", "PROGRESS_TOTAL" => $res["DONE"] + $res["TODO"], "PROGRESS_VALUE" => $res["DONE"]));
    }
    require $_SERVER["DOCUMENT_ROOT"] . BX_ROOT . "/modules/main/include/epilog_admin_js.php";
} else {
    $sTableID = "tbl_search";
    $oSort = new CAdminSorting($sTableID, "ID", "desc");
    $lAdmin = new CAdminList($sTableID, $oSort);
    $FilterArr = array("find", "find_type", "find_id", "find_site_id", "find_module_id", "find_param1");
    $lAdmin->InitFilter($FilterArr);
    $arFilter = array("ID" => $find != "" && $find_type == "id" ? $find : $find_id, "SITE_ID" => $find_site_id == "NOT_REF" ? "" : ($find != "" && $find_type == "site_id" ? $find : $find_site_id), "MODULE_ID" => $find_module_id, "PARAM1" => $find_param1);
    if ($lAdmin->EditAction() && $SEARCH_RIGHT >= "W" && is_array($FIELDS)) {
        foreach ($FIELDS as $ID => $arFields) {
            if (!$lAdmin->IsUpdated($ID)) {
                continue;
            }
            $DB->StartTransaction();
            $ID = IntVal($ID);
            $cData = new CSearchCustomRank();
            if (($rsData = $cData->GetByID($ID)) && ($arData = $rsData->Fetch())) {
                foreach ($arFields as $key => $value) {
                    $arData[$key] = $value;
                }
                if (!$cData->Update($ID, $arData)) {
                    $lAdmin->AddGroupError(GetMessage("customrank_edit_error") . $cData->LAST_ERROR, $ID);
                    $DB->Rollback();
                }
开发者ID:k-kalashnikov,项目名称:geekcon_new,代码行数:31,代码来源:search_customrank_admin.php

示例12: CAdminSorting

$oSort = new CAdminSorting($sTableID, "timestamp_x", "desc");
$lAdmin = new CAdminList($sTableID, $oSort);
$arFilterRows = array("ID" => "ID", "URL" => GetMessage("CTRL_MEMB_ADMIN_FILTER_URL"), "GROUP" => GetMessage("CTRL_MEMB_ADMIN_FILTER_GROUP"), "UNIQID" => GetMessage("CTRL_MEMB_ADMIN_FILTER_UNIQID"), "ACTIVE" => GetMessage("CTRL_MEMB_ADMIN_FILTER_ACTIVE"), "DISCONN" => GetMessage("CTRL_MEMB_ADMIN_FILTER_DISCONN"), "MODIFIED" => GetMessage("CTRL_MEMB_ADMIN_FILTER_MODIFIED"), "CREATED" => GetMessage("CTRL_MEMB_ADMIN_FILTER_CREATED"), "ACT_FROM" => GetMessage("CTRL_MEMB_ADMIN_FILTER_ACT_FROM"), "ACT_TO" => GetMessage("CTRL_MEMB_ADMIN_FILTER_ACT_TO"), "CONTACT_PERSON" => GetMessage("CTRL_MEMB_ADMIN_CONTACT_PERSON"), "EMAIL" => GetMessage("CTRL_MEMB_ADMIN_EMAIL"));
$USER_FIELD_MANAGER->AddFindFields($entity_id, $arFilterRows);
$filter = new CAdminFilter($sTableID . "_filter_id", $arFilterRows);
$arFilterFields = array("find_name", "find_id", "find_active", "find_disconnected", "find_active_from_from", "find_active_from_to", "find_active_to_from", "find_active_to_to", "find_controller_group_id", "find_timestamp_x_from", "find_timestamp_x_to", "find_created_from", "find_created_to", "find_member_id", "find_url", "find_contact_person", "find_email");
$USER_FIELD_MANAGER->AdminListAddFilterFields($entity_id, $arFilterFields);
$lAdmin->InitFilter($arFilterFields);
$arFilter = array("ID" => $find_id, "%NAME" => $find_name, "%EMAIL" => $find_email, "%CONTACT_PERSON" => $find_contact_person, "ACTIVE" => $find_active, "DISCONNECTED" => $find_disconnected, ">=DATE_ACTIVE_FROM" => $find_active_from_from, "<=DATE_ACTIVE_FROM" => $find_active_from_to, ">=DATE_ACTIVE_TO" => $find_active_to_from, "<=DATE_ACTIVE_TO" => $find_active_to_to, "CONTROLLER_GROUP_ID" => $find_controller_group_id, ">=TIMESTAMP_X" => $find_timestamp_x_from, "<=TIMESTAMP_X" => $find_timestamp_x_to, ">=DATE_CREATE" => $find_created_from, "<=DATE_CREATE" => $find_created_to, "%MEMBER_ID" => $find_member_id, "%URL" => $find_url);
$USER_FIELD_MANAGER->AdminListAddFilter($entity_id, $arFilter);
$arGroups = array();
$dbr_groups = CControllerGroup::GetList(array("SORT" => "ASC", "NAME" => "ASC", "ID" => "ASC"));
while ($ar_groups = $dbr_groups->Fetch()) {
    $arGroups[$ar_groups["ID"]] = $ar_groups["NAME"];
}
if ($MOD_RIGHT >= "V" && $lAdmin->EditAction()) {
    foreach ($FIELDS as $ID => $arFields) {
        $ID = intval($ID);
        if (!$lAdmin->IsUpdated($ID)) {
            continue;
        }
        $DB->StartTransaction();
        $USER_FIELD_MANAGER->AdminListPrepareFields($entity_id, $arFields);
        if (!CControllerMember::Update($ID, $arFields)) {
            $e = $APPLICATION->GetException();
            $lAdmin->AddUpdateError(GetMessage("CTRL_MEMB_ADMIN_SAVE_ERR") . " #" . $ID . ": " . $e->GetString(), $ID);
            $DB->Rollback();
        }
        $DB->Commit();
    }
}
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:31,代码来源:controller_member_admin.php

示例13: CAdminSorting

$adminListTableID = 't_currencies';
$adminSort = new CAdminSorting($adminListTableID, 'SORT', 'ASC');
$adminList = new CAdminList($adminListTableID, $adminSort);

$filter = array();
$filterFields = array();

if (!isset($by))
	$by = 'SORT';
if (!isset($order))
	$order = 'ASC';
$by = strtoupper($by);
$order = strtoupper($order);

if ($adminList->EditAction() && $CURRENCY_RIGHT == "W")
{
	if (isset($FIELDS) && is_array($FIELDS))
	{
		foreach ($FIELDS as $ID => $arFields)
		{
			$ID = Currency\CurrencyManager::checkCurrencyID($ID);
			if ($ID === false)
				continue;

			if (!$adminList->IsUpdated($ID))
				continue;

			if (!CCurrency::Update($ID, $arFields))
			{
				if ($ex = $APPLICATION->GetException())
开发者ID:akniyev,项目名称:arteva.ru,代码行数:30,代码来源:currencies.php

示例14: substr

        continue;
    }
    if (array_key_exists($key . '_EXACT_MATCH', $_REQUEST) && $_REQUEST[$key . '_EXACT_MATCH'] == 'Y') {
        $op = '=';
    } else {
        $op = '%';
    }
    if (array_key_exists($key, $_REQUEST) && strlen($_REQUEST[$key]) > 0) {
        if (in_array($key . '_EXACT_MATCH', $arFilterFields)) {
            $arFilter[$op . substr($key, 5)] = $_REQUEST[$key];
        } else {
            $arFilter[substr($key, 5)] = $_REQUEST[$key];
        }
    }
}
if ($bAdmin && $lAdmin->EditAction()) {
    $obSUG = new CSupportUserGroup();
    foreach ($FIELDS as $ID => $arFields) {
        $ID = intval($ID);
        if (!$lAdmin->IsUpdated($ID)) {
            continue;
        }
        $arUpdate["SORT"] = intval($arFields["SORT"]);
        if (!$obSUG->Update($ID, $arUpdate)) {
            $ex = $APPLICATION->GetException();
            $lAdmin->AddUpdateError($ex->GetString(), $ID);
        }
        /*
        if (strlen(trim($arFields["NAME"]))>0)
        {
        	CTicketSLA::Set(array("NAME" => $arFields["NAME"], "PRIORITY" => $arFields["PRIORITY"]), $ID);
开发者ID:k-kalashnikov,项目名称:geekcon_new,代码行数:31,代码来源:ticket_group_list.php

示例15: array

    global $strError;
    $str = "";
    $strError .= $str;
    if (strlen($str) > 0) {
        global $lAdmin;
        $lAdmin->AddFilterError($str);
        return false;
    }
    return true;
}
$arFilter = array();
if (CheckFilter($arFilterFields)) {
    $arFilter = array("ID" => $find != '' && $find_type == "id" ? $find : $find_id, "LETTER" => $find_letter, "MODULE_ID" => $find_module_id, "SYS" => $find_sys, "BINDING" => $find_binding);
}
// обработка редактирования (права доступа!)
if ($lAdmin->EditAction() && $USER->CanDoOperation('edit_tasks')) {
    foreach ($FIELDS as $ID => $arFields) {
        $ID = IntVal($ID);
        if (!$lAdmin->IsUpdated($ID)) {
            continue;
        }
        CTask::Update($ID, $arFields);
    }
}
// обработка действий групповых и одиночных
if (($arID = $lAdmin->GroupAction()) && $USER->CanDoOperation('edit_tasks')) {
    if ($_REQUEST['action_target'] == 'selected') {
        $arID = array();
        $rsData = CTask::GetList(array($by => $order), $arFilter);
        while ($arRes = $rsData->Fetch()) {
            $arID[] = $arRes['ID'];
开发者ID:spas-viktor,项目名称:books,代码行数:31,代码来源:task_admin.php


注:本文中的CAdminList::EditAction方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。