Helper :: getResponsibleUserExpression: Bitrix method

      
<?php 
//  Bitrix\Bizproc\Automation\Helper :: getResponsibleUserExpression()
//  /dist/bitrix/modules/bizproc/lib/automation/helper.php:106

    
public static function getResponsibleUserExpression(array $documentType)
    {
        
$documentUserFields = static::getDocumentFields($documentType'user');
        
$result null;

        if (isset(
$documentUserFields['ASSIGNED_BY_ID']) || isset($documentUserFields['RESPONSIBLE_ID']))
        {
            
$responsibleKey = isset($documentUserFields['ASSIGNED_BY_ID']) ? 'ASSIGNED_BY_ID' 'RESPONSIBLE_ID';
            
$result '{=Document:'.$responsibleKey.'}';
        }
        elseif (isset(
$documentUserFields['CREATED_BY']))
        {
            
$result '{=Document:CREATED_BY}';
        }
        return 
$result;
    }