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


PHP CBitrixComponent::onPrepareComponentParams方法代码示例

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


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

示例1: onPrepareComponentParams

 public function onPrepareComponentParams($params)
 {
     $params = parent::onPrepareComponentParams($params);
     if (!isset($this->arParams["WIDTH"])) {
         $this->arParams["WIDTH"] = 400;
     }
     if (!isset($this->arParams["HEIGHT"])) {
         $this->arParams["HEIGHT"] = 400;
     }
     if (!isset($this->arParams["SELECTED_STORE"])) {
         $this->arParams["SELECTED_STORE"] = 0;
         if (isset($params["STORES_LIST"]) && is_array($params["STORES_LIST"])) {
             reset($params["STORES_LIST"]);
             $this->arParams["SELECTED_STORE"] = key($params["STORES_LIST"]);
         }
     }
     return $params;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:18,代码来源:class.php

示例2: onPrepareComponentParams

 /**
  * @param $arParams
  * @return array
  */
 public function onPrepareComponentParams($arParams)
 {
     $arParams['FILTER_NAME'] = $this->initFilterName($arParams['FILTER_NAME']);
     $this->loadTooltipFromSocialNetwork($arParams);
     $arParams["NAME_TEMPLATE"] = empty($arParams["NAME_TEMPLATE"]) || !trim($arParams["NAME_TEMPLATE"]) ? CSite::GetNameFormat() : $arParams["NAME_TEMPLATE"];
     //set default to Y
     $arParams['SHOW_LOGIN'] = empty($arParams['SHOW_LOGIN']) || $arParams['SHOW_LOGIN'] != "N" ? "Y" : "N";
     //if not set value, set to default
     $arParams["PM_URL"] = empty($arParams["PM_URL"]) ? "/company/personal/messages/chat/#USER_ID#/" : $arParams["PM_URL"];
     $arParams["PATH_TO_CONPANY_DEPARTMENT"] = empty($arParams["PATH_TO_CONPANY_DEPARTMENT"]) ? "/company/structure.php?set_filter_structure=Y&structure_UF_DEPARTMENT=#ID#" : $arParams["PATH_TO_CONPANY_DEPARTMENT"];
     $arParams["PATH_TO_VIDEO_CALL"] = IsModuleInstalled("video") && empty($arParams["PATH_TO_VIDEO_CALL"]) ? "/company/personal/video/#USER_ID#/" : $arParams["PATH_TO_VIDEO_CALL"];
     TrimArr($arParams['ALPHABET_LANG']);
     $arParams['ALPHABET_LANG'] = empty($arParams['ALPHABET_LANG']) ? array(LANGUAGE_ID) : $arParams['ALPHABET_LANG'];
     $arParams['CURRENT_VIEW'] = $this->getCurrentView($arParams);
     $arParams['LIST_URL'] = $this->getApplication()->GetCurPage();
     if (!$arParams['DETAIL_URL']) {
         $arParams['DETAIL_URL'] = $arParams['LIST_URL'] . '?ID=#USER_ID#';
     }
     return parent::onPrepareComponentParams($arParams);
 }
开发者ID:mrdeadmouse,项目名称:u136006,代码行数:24,代码来源:class.php

示例3: onPrepareComponentParams

 public function onPrepareComponentParams($arParams)
 {
     $arParams['action'] = strtolower($arParams['action']);
     $arParams['inviteFromUserId'] = (int) $arParams['inviteFromUserId'];
     $arParams['attachToUserId'] = (int) $arParams['attachToUserId'];
     $arParams['attachToUserIds'] = empty($arParams['attachToUserIds']) ? array() : $arParams['attachToUserIds'];
     $arParams['unshareUserIds'] = empty($arParams['unshareUserIds']) ? array() : $arParams['unshareUserIds'];
     $arParams['inviteDescription'] = empty($arParams['inviteDescription']) ? '' : $arParams['inviteDescription'];
     $arParams['canEdit'] = !empty($arParams['canEdit']);
     $arParams['pathToUser'] = !empty($arParams['pathToUser']) ? $arParams['pathToUser'] : '/company/personal/user/#user_id#/';
     $arParams['pathToGroup'] = !empty($arParams['pathToGroup']) ? $arParams['pathToGroup'] : '/workgroups/group/#group_id#/';
     $arParams['userListType'] = !empty($arParams['userListType']) ? strtolower($arParams['userListType']) : 'cannot_edit';
     $arParams['currentUserCanUnshare'] = !empty($arParams['currentUserCanUnshare']);
     if (!is_array($arParams['attachToUserIds'])) {
         $arParams['attachToUserIds'] = array();
     }
     if (!is_array($arParams['unshareUserIds'])) {
         $arParams['unshareUserIds'] = array();
     }
     return parent::onPrepareComponentParams($arParams);
 }
开发者ID:mrdeadmouse,项目名称:u136006,代码行数:21,代码来源:class.php

示例4: onPrepareComponentParams

 public function onPrepareComponentParams($arParams)
 {
     $arParams = parent::onPrepareComponentParams($arParams);
     $arParams = array_merge(static::getInternalComponentParameters(), $arParams);
     if (!isset($arParams['GREEDY_PARTS'])) {
         $arParams['GREEDY_PARTS'] = array();
     } elseif (is_string($arParams['GREEDY_PARTS'])) {
         $arParams['GREEDY_PARTS'] = trim(explode(',', $arParams['GREEDY_PARTS']));
     }
     return $arParams;
 }
开发者ID:digitalwand,项目名称:mvc.base,代码行数:11,代码来源:class.php

示例5: onPrepareComponentParams

 public function onPrepareComponentParams($arParams)
 {
     $arParams['createType'] = !empty($arParams['createType']) ? strtolower($arParams['createType']) : null;
     $arParams['newFileName'] = !empty($arParams['newFileName']) ? $arParams['newFileName'] : '';
     $arParams['commitDoc'] = !empty($arParams['commitDoc']);
     return parent::onPrepareComponentParams($arParams);
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:7,代码来源:editdoccomponentbase.php


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