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


PHP CCrmOwnerType::ResolveName方法代码示例

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


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

示例1: save

 protected static function save()
 {
     $ary = array();
     foreach (self::$items as $entityTypeID => $time) {
         $ary[\CCrmOwnerType::ResolveName($entityTypeID)] = $time->format(\DateTime::ISO8601);
     }
     Main\Config\Option::set('crm', 'crm_uf_history', serialize($ary), '');
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:8,代码来源:userfieldhistory.php

示例2: GetDocumentNames

 public static function GetDocumentNames($ownerTypeID, $ownerID)
 {
     if (!(IsModuleInstalled('bizproc') && CModule::IncludeModule('bizproc'))) {
         return false;
     }
     $ownerTypeID = intval($ownerTypeID);
     $ownerID = intval($ownerID);
     $docName = self::ResolveDocumentName($ownerTypeID);
     if ($docName === '') {
         return array();
     }
     $ownerTypeName = CCrmOwnerType::ResolveName($ownerTypeID);
     if ($ownerTypeName === '') {
         return array();
     }
     /*$arDocumentStates = CBPDocument::GetDocumentStates(
     			array('crm', $docName, $ownerTypeName),
     			array('crm', $docName, $ownerTypeName.'_'.$ownerID)
     		);*/
     $arDocumentStates = CBPStateService::GetDocumentStates(array('crm', $docName, $ownerTypeName . '_' . $ownerID));
     $result = array();
     foreach ($arDocumentStates as $arDocumentState) {
         if ($arDocumentState['ID'] !== '' && $arDocumentState['TEMPLATE_NAME'] !== '') {
             $result[] = $arDocumentState['TEMPLATE_NAME'];
         }
     }
     return $result;
 }
开发者ID:mrdeadmouse,项目名称:u136006,代码行数:28,代码来源:crm_bizproc_helper.php

示例3: __construct

 public function __construct($dstEntityTypeID, $srcEntityTypeID, $srcEntityID)
 {
     parent::__construct($dstEntityTypeID);
     $this->srcEntityTypeID = $srcEntityTypeID;
     $this->srcEntityTypeName = \CCrmOwnerType::ResolveName($srcEntityTypeID);
     $this->srcEntityID = $srcEntityID;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:7,代码来源:entityconversionfileviewer.php

示例4: CheckImportPermission

 public static function CheckImportPermission($enitityType, $userPermissions = null)
 {
     $enitityTypeName = is_numeric($enitityType) ? CCrmOwnerType::ResolveName($enitityType) : strtoupper(strval($enitityType));
     if (!$userPermissions) {
         $userPermissions = self::GetUserPermissions();
     }
     return !$userPermissions->HavePerm($enitityTypeName, BX_CRM_PERM_NONE, 'IMPORT');
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:8,代码来源:crm_authorization_helper.php

示例5: externalize

 public function externalize()
 {
     $results = array();
     foreach ($this->items as $k => $v) {
         $results[\CCrmOwnerType::ResolveName($k)] = $v->externalize();
     }
     return $results;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:8,代码来源:entityconversionconfig.php

示例6: createMap

 /**
  * Create conversion map for destination entity type
  * @static
  * @param int $entityTypeID Destination Entity Type ID
  * @return EntityConversionMap
  */
 public static function createMap($entityTypeID)
 {
     if (!is_int($entityTypeID)) {
         $entityTypeID = (int) $entityTypeID;
     }
     if (!\CCrmOwnerType::IsDefined($entityTypeID)) {
         throw new Main\ArgumentOutOfRangeException('dstEntityTypeID', \CCrmOwnerType::FirstOwnerType, \CCrmOwnerType::LastOwnerType);
     }
     if ($entityTypeID !== \CCrmOwnerType::Deal && $entityTypeID !== \CCrmOwnerType::Invoice) {
         $dstEntityTypeName = \CCrmOwnerType::ResolveName($entityTypeID);
         throw new Main\NotSupportedException("Entity type: '{$dstEntityTypeName}' is not supported in current context");
     }
     $map = new EntityConversionMap(\CCrmOwnerType::Quote, $entityTypeID);
     if ($entityTypeID === \CCrmOwnerType::Deal) {
         //region Deal Map Static Field Bindings
         $map->createItem('TITLE');
         $map->createItem('COMMENTS');
         $map->createItem('ASSIGNED_BY_ID');
         $map->createItem('OPENED');
         $map->createItem('OPPORTUNITY');
         $map->createItem('CURRENCY_ID');
         $map->createItem('TAX_VALUE');
         $map->createItem('EXCH_RATE');
         $map->createItem('LOCATION_ID');
         $map->createItem('LEAD_ID');
         $map->createItem('COMPANY_ID');
         $map->createItem('CONTACT_ID');
         $map->createItem('PRODUCT_ROWS');
         //endregion
         //region Invoice Map User Field Bindings
         $intersections = UserFieldSynchronizer::getIntersection(\CCrmOwnerType::Quote, \CCrmOwnerType::Deal);
         foreach ($intersections as $intersection) {
             $map->createItem($intersection['SRC_FIELD_NAME'], $intersection['DST_FIELD_NAME']);
         }
         //endregion
     }
     if ($entityTypeID === \CCrmOwnerType::Invoice) {
         //region Invoice Map Static Field Bindings
         $map->createItem('TITLE', 'ORDER_TOPIC');
         $map->createItem('COMPANY_ID', 'UF_COMPANY_ID');
         $map->createItem('CONTACT_ID', 'UF_CONTACT_ID');
         $map->createItem('DEAL_ID', 'UF_DEAL_ID');
         $map->createItem('ASSIGNED_BY_ID', 'RESPONSIBLE_ID');
         $map->createItem('COMMENTS');
         $map->createItem('PRODUCT_ROWS');
         //endregion
         //region Invoice Map User Field Bindings
         $intersections = UserFieldSynchronizer::getIntersection(\CCrmOwnerType::Quote, \CCrmOwnerType::Invoice);
         foreach ($intersections as $intersection) {
             $map->createItem($intersection['SRC_FIELD_NAME'], $intersection['DST_FIELD_NAME']);
         }
         //endregion
     }
     return $map;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:61,代码来源:quoteconversionmapper.php

示例7: getEntityMultifieldValues

 protected static function getEntityMultifieldValues($entityTypeID, $entityID, $typeID)
 {
     $results = array();
     $dbResult = \CCrmFieldMulti::GetList(array('ID' => 'asc'), array('TYPE_ID' => $typeID, 'ENTITY_ID' => \CCrmOwnerType::ResolveName($entityTypeID), 'ELEMENT_ID' => $entityID));
     if (is_object($dbResult)) {
         while ($fields = $dbResult->Fetch()) {
             $results[] = $fields['VALUE'];
         }
     }
     return $results;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:11,代码来源:datagenerator.php

示例8: createDuplicate

 /**
  * @return Duplicate
  */
 public function createDuplicate($entityTypeID, $rootEntityID, $userID, $enablePermissionCheck, $enableRanking, $limit = 0)
 {
     if ($entityTypeID !== \CCrmOwnerType::Lead && $entityTypeID !== \CCrmOwnerType::Contact && $entityTypeID !== \CCrmOwnerType::Company) {
         throw new Main\NotSupportedException("Entity type: '" . \CCrmOwnerType::ResolveName($entityTypeID) . "' is not supported in current context");
     }
     /** @var Duplicate $dup **/
     $dup = new Duplicate($this, array());
     $query = static::createQuery();
     $query->addSelect('ENTITY_ID');
     $query->addFilter('=ENTITY_TYPE_ID', $entityTypeID);
     static::setQueryFilter($query, $this->getMatches());
     if ($enablePermissionCheck) {
         $permissions = isset($params['PERMISSIONS']) ? $params['PERMISSIONS'] : null;
         if ($permissions === null) {
             $permissions = \CCrmPerms::GetUserPermissions($userID);
         }
         $permissionSql = \CCrmPerms::BuildSql(\CCrmOwnerType::ResolveName($entityTypeID), '', 'READ', array('RAW_QUERY' => true, 'PERMS' => $permissions));
         if ($permissionSql === false) {
             //Access denied;
             return null;
         }
         if ($permissionSql !== '') {
             $query->addFilter('@ENTITY_ID', new Main\DB\SqlExpression($permissionSql));
         }
     }
     if ($limit > 0) {
         $query->setLimit($limit);
     }
     if ($rootEntityID > 0) {
         $dup->setRootEntityID($rootEntityID);
         $query->addFilter('!ENTITY_ID', $rootEntityID);
         $query->addFilter('!@ENTITY_ID', DuplicateIndexMismatch::prepareQueryField($this, $entityTypeID, $rootEntityID, $userID));
     }
     $dbResult = $query->exec();
     $rankings = array();
     while ($fields = $dbResult->fetch()) {
         $entityID = isset($fields['ENTITY_ID']) ? intval($fields['ENTITY_ID']) : 0;
         if ($entityID <= 0) {
             continue;
         }
         $entity = new DuplicateEntity($entityTypeID, $entityID);
         if ($enableRanking) {
             $rankings[] = $entity->getRanking();
         }
         $dup->addEntity($entity);
     }
     $this->onAfterDuplicateCreated($dup, $entityTypeID, $userID, $enablePermissionCheck, $enableRanking, $rankings);
     if ($enableRanking) {
         DuplicateEntityRanking::initializeBulk($rankings, array('CHECK_PERMISSIONS' => $enablePermissionCheck, 'USER_ID' => $userID));
     }
     return $dup;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:55,代码来源:duplicatecriterion.php

示例9: ParseEntityKey

 public static function ParseEntityKey($key, &$entityInfo)
 {
     if (preg_match(self::$ENTITY_KEY, strval($key), $match) !== 1) {
         $entityInfo = array();
         return false;
     }
     $entityTypeAbbr = strtoupper($match[1]);
     $entityID = intval($match[2]);
     $entityTypeID = CCrmOwnerType::ResolveID($entityTypeAbbr);
     $entityTypeName = CCrmOwnerType::ResolveName($entityTypeID);
     $entityInfo = array('ENTITY_TYPE_ABBR' => $entityTypeAbbr, 'ENTITY_TYPE_ID' => $entityTypeID, 'ENTITY_TYPE_NAME' => $entityTypeName, 'ENTITY_ID' => $entityID);
     return true;
 }
开发者ID:mrdeadmouse,项目名称:u136006,代码行数:13,代码来源:entity_helper.php

示例10: preparePermissionSql

 protected function preparePermissionSql()
 {
     if ($this->permissionSql !== null) {
         return $this->permissionSql;
     }
     $userID = $this->getUserID();
     if (\CCrmPerms::IsAdmin($userID)) {
         $this->permissionSql = '';
     } else {
         $this->permissionSql = \CCrmPerms::BuildSql(\CCrmOwnerType::ResolveName($this->getEntityTypeID()), '', 'READ', array('RAW_QUERY' => true, 'PERMS' => \CCrmPerms::GetUserPermissions($userID)));
     }
     return $this->permissionSql;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:13,代码来源:dedupedatasource.php

示例11: EnsureResponsibilityImported

 public static function EnsureResponsibilityImported($entityTypeID, $userID, $reset = false)
 {
     if (!CCrmOwnerType::IsDefined($entityTypeID)) {
         return false;
     }
     $userID = intval($userID);
     if ($userID <= 0) {
         $userID = CCrmSecurityHelper::GetCurrentUser();
     }
     $reset = (bool) $reset;
     $optionName = strtolower(CCrmOwnerType::ResolveName($entityTypeID)) . '_sl_subscr_import';
     if ($reset || CUserOptions::GetOption('crm', $optionName, 'N', $userID) !== 'Y') {
         self::GetCurrent()->ImportResponsibility($entityTypeID, $userID, 5000);
         CUserOptions::SetOption('crm', $optionName, 'Y', false, $userID);
     }
     return true;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:17,代码来源:sonet_subscription.php

示例12: create

 /** Create new entity merger by specified entity type ID
  * @static
  * @param int $entityTypeID
  * @param int $currentUserID
  * @param bool $enablePermissionCheck
  * @return EntityMerger
  */
 public static function create($entityTypeID, $currentUserID, $enablePermissionCheck = false)
 {
     if (!is_int($entityTypeID)) {
         $entityTypeID = (int) $entityTypeID;
     }
     if (!\CCrmOwnerType::IsDefined($entityTypeID)) {
         throw new Main\ArgumentException('Is not defined', 'entityTypeID');
     }
     if ($entityTypeID === \CCrmOwnerType::Lead) {
         return new LeadMerger($currentUserID, $enablePermissionCheck);
     } elseif ($entityTypeID === \CCrmOwnerType::Contact) {
         return new ContactMerger($currentUserID, $enablePermissionCheck);
     } elseif ($entityTypeID === \CCrmOwnerType::Company) {
         return new CompanyMerger($currentUserID, $enablePermissionCheck);
     } else {
         throw new Main\NotSupportedException("Entity type: '" . \CCrmOwnerType::ResolveName($entityTypeID) . "' is not supported in current context");
     }
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:25,代码来源:entitymergerfactory.php

示例13: enabledFor

 public function enabledFor($entityTypeID, $enable)
 {
     if (!is_int($entityTypeID)) {
         throw new Main\ArgumentTypeException('entityTypeID', 'integer');
     }
     if (!\CCrmOwnerType::IsDefined($entityTypeID)) {
         throw new Main\NotSupportedException("Entity ID: '{$entityTypeID}' is not supported in current context");
     }
     if (!is_bool($enable)) {
         if (is_numeric($enable)) {
             $enable = $enable > 0;
         } elseif (is_string($enable)) {
             $enable = strtoupper($enable) === 'Y';
         } else {
             $enable = false;
         }
     }
     $this->settings['enableFor'][\CCrmOwnerType::ResolveName($entityTypeID)] = $enable ? 'Y' : 'N';
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:19,代码来源:duplicatecontrol.php

示例14: PrepareTemplate

 public static function PrepareTemplate($template, $entityTypeID, $entityID, $contentTypeID = 0)
 {
     $template = strval($template);
     if ($template === '') {
         return '';
     }
     $entityTypeName = CCrmOwnerType::ResolveName($entityTypeID);
     $entityID = intval($entityID);
     if ($entityTypeName === '' || $entityID <= 0) {
         return $template;
     }
     $matches = null;
     $result = preg_match_all('/#' . $entityTypeName . '\\.[^#]+#/i', $template, $matches, PREG_OFFSET_CAPTURE);
     if (!(is_int($result) && $result > 0)) {
         return $template;
     }
     $mapper = self::ResolveMapper($entityTypeID, $entityID);
     if ($mapper === null) {
         return $template;
     }
     $contentTypeID = intval($contentTypeID);
     if (!CCrmContentType::IsDefined($contentTypeID)) {
         $contentTypeID = CCrmContentType::PlainText;
     }
     $mapper->SetContentType($contentTypeID);
     $replaceKeys = array();
     $replaceValues = array();
     foreach ($matches[0] as &$match) {
         $key = $match[0];
         if (isset($replacements[$key])) {
             continue;
         }
         $path = substr($key, 1, strlen($key) - 2);
         $replaceKeys[] = $key;
         $replaceValues[] = $mapper->MapPath($path);
     }
     unset($match);
     return !empty($replaceKeys) ? str_replace($replaceKeys, $replaceValues, $template) : $template;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:39,代码来源:template_manager.php

示例15: GetTypeMap

 public function GetTypeMap($typeID)
 {
     $typeID = intval($typeID);
     if (!CCrmOwnerType::IsDefined($typeID)) {
         return null;
     }
     if (!isset(self::$MAP_BY_LANG[LANGUAGE_ID])) {
         self::$MAP_BY_LANG[LANGUAGE_ID] = array();
     }
     if (isset(self::$MAP_BY_LANG[LANGUAGE_ID][$typeID])) {
         return self::$MAP_BY_LANG[LANGUAGE_ID][$typeID];
     }
     IncludeModuleLangFile(__FILE__);
     if ($typeID === CCrmOwnerType::Lead) {
         return self::$MAP_BY_LANG[LANGUAGE_ID][CCrmOwnerType::Lead] = array('typeId' => CCrmOwnerType::Lead, 'typeName' => CCrmOwnerType::ResolveName(CCrmOwnerType::Lead), 'fields' => array(array('id' => 'ID', 'name' => 'ID'), array('id' => 'TITLE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_TITLE')), array('id' => 'LAST_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_LAST_NAME')), array('id' => 'NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_NAME')), array('id' => 'SECOND_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_SECOND_NAME')), array('id' => 'FORMATTED_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_FORMATTED_NAME')), array('id' => 'COMPANY_TITLE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_COMPANY_TITLE')), array('id' => 'SOURCE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_SOURCE')), array('id' => 'SOURCE_DESCRIPTION', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_SOURCE_DESCRIPTION')), array('id' => 'STATUS', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_STATUS')), array('id' => 'STATUS_DESCRIPTION', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_STATUS_DESCRIPTION')), array('id' => 'POST', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_POST')), array('id' => 'ADDRESS', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_ADDRESS')), array('id' => 'CURRENCY', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_CURRENCY')), array('id' => 'OPPORTUNITY', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_OPPORTUNITY')), array('id' => 'OPPORTUNITY_FORMATTED', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_OPPORTUNITY_FORMATTED')), array('id' => 'ASSIGNED_BY_FULL_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_ASSIGNED_BY_FULL_NAME')), array('id' => 'ASSIGNED_BY_WORK_POSITION', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_ASSIGNED_BY_POST')), array('id' => 'CREATED_BY_FULL_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_CREATED_BY_FULL_NAME')), array('id' => 'MODIFY_BY_FULL_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_MODIFY_BY_FULL_NAME')), array('id' => 'DATE_CREATE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_DATE_CREATE')), array('id' => 'DATE_MODIFY', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_DATE_MODIFY')), array('id' => 'COMMENTS', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_COMMENTS'))));
     } elseif ($typeID === CCrmOwnerType::Deal) {
         return self::$MAP_BY_LANG[LANGUAGE_ID][CCrmOwnerType::Deal] = array('typeId' => CCrmOwnerType::Deal, 'typeName' => CCrmOwnerType::ResolveName(CCrmOwnerType::Deal), 'fields' => array(array('id' => 'ID', 'name' => 'ID'), array('id' => 'TITLE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_TITLE')), array('id' => 'TYPE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_TYPE')), array('id' => 'STAGE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_STAGE')), array('id' => 'PROBABILITY', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_PROBABILITY')), array('id' => 'CURRENCY', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_CURRENCY')), array('id' => 'OPPORTUNITY', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_OPPORTUNITY')), array('id' => 'OPPORTUNITY_FORMATTED', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_OPPORTUNITY_FORMATTED')), array('id' => 'COMPANY', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_COMPANY'), 'typeId' => CCrmOwnerType::Company), array('id' => 'CONTACT', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_CONTACT'), 'typeId' => CCrmOwnerType::Contact), array('id' => 'BEGINDATE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_BEGINDATE')), array('id' => 'CLOSEDATE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_CLOSEDATE')), array('id' => 'ASSIGNED_BY_FULL_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_ASSIGNED_BY_FULL_NAME')), array('id' => 'ASSIGNED_BY_WORK_POSITION', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_ASSIGNED_BY_POST')), array('id' => 'CREATED_BY_FULL_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_CREATED_BY_FULL_NAME')), array('id' => 'MODIFY_BY_FULL_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_MODIFY_BY_FULL_NAME')), array('id' => 'DATE_CREATE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_DATE_CREATE')), array('id' => 'DATE_MODIFY', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_DATE_MODIFY')), array('id' => 'COMMENTS', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_COMMENTS'))));
     } elseif ($typeID === CCrmOwnerType::Contact) {
         return self::$MAP_BY_LANG[LANGUAGE_ID][CCrmOwnerType::Contact] = array('typeId' => CCrmOwnerType::Contact, 'typeName' => CCrmOwnerType::ResolveName(CCrmOwnerType::Contact), 'fields' => array(array('id' => 'ID', 'name' => 'ID'), array('id' => 'LAST_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_LAST_NAME')), array('id' => 'NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_NAME')), array('id' => 'SECOND_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_SECOND_NAME')), array('id' => 'FORMATTED_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_FORMATTED_NAME')), array('id' => 'POST', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_POST')), array('id' => 'ADDRESS', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_ADDRESS')), array('id' => 'TYPE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_TYPE')), array('id' => 'SOURCE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_SOURCE')), array('id' => 'SOURCE_DESCRIPTION', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_STATUS_DESCRIPTION')), array('id' => 'COMPANY', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_COMPANY'), 'typeId' => CCrmOwnerType::Company), array('id' => 'ASSIGNED_BY_FULL_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_ASSIGNED_BY_FULL_NAME')), array('id' => 'ASSIGNED_BY_WORK_POSITION', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_ASSIGNED_BY_POST')), array('id' => 'CREATED_BY_FULL_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_CREATED_BY_FULL_NAME')), array('id' => 'MODIFY_BY_FULL_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_MODIFY_BY_FULL_NAME')), array('id' => 'DATE_CREATE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_DATE_CREATE')), array('id' => 'DATE_MODIFY', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_DATE_MODIFY')), array('id' => 'COMMENTS', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_COMMENTS'))));
     } elseif ($typeID === CCrmOwnerType::Company) {
         return self::$MAP_BY_LANG[LANGUAGE_ID][CCrmOwnerType::Company] = array('typeId' => CCrmOwnerType::Company, 'typeName' => CCrmOwnerType::ResolveName(CCrmOwnerType::Company), 'fields' => array(array('id' => 'ID', 'name' => 'ID'), array('id' => 'TITLE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_TITLE')), array('id' => 'TYPE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_COMPANY_TYPE')), array('id' => 'ADDRESS', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_ACTUAL_ADDRESS')), array('id' => 'ADDRESS_LEGAL', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_ADDRESS_LEGAL')), array('id' => 'BANKING_DETAILS', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_BANKING_DETAILS')), array('id' => 'INDUSTRY', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_INDUSTRY')), array('id' => 'EMPLOYEES', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_EMPLOYEES')), array('id' => 'CURRENCY', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_CURRENCY')), array('id' => 'REVENUE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_REVENUE')), array('id' => 'REVENUE_FORMATTED', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_REVENUE_FORMATTED')), array('id' => 'ASSIGNED_BY_FULL_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_ASSIGNED_BY_FULL_NAME')), array('id' => 'ASSIGNED_BY_WORK_POSITION', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_ASSIGNED_BY_POST')), array('id' => 'CREATED_BY_FULL_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_CREATED_BY_FULL_NAME')), array('id' => 'MODIFY_BY_FULL_NAME', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_MODIFY_BY_FULL_NAME')), array('id' => 'DATE_CREATE', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_DATE_CREATE')), array('id' => 'DATE_MODIFY', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_DATE_MODIFY')), array('id' => 'COMMENTS', 'name' => GetMessage('CRM_TEMPLATE_ADAPTER_COMMENTS'))));
     }
     return null;
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:24,代码来源:template_adapter.php


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