3namespace Bitrix\Bizproc\BaseType;
5use Bitrix\Bizproc\FieldType;
6use Bitrix\Main\Localization\Loc;
8Loc::loadMessages(__FILE__);
35 $fields = self::getDocumentSelectFields($fieldType,
true);
38 $result .=
'<select onchange="'.htmlspecialcharsbx($callbackFunctionName).
'(this.options[this.selectedIndex].value)">';
40 $fieldsNames = array_keys(
$fields);
41 if (!in_array($selectedField, $fieldsNames))
42 $selectedField = isset($fieldsNames[0]) ? $fieldsNames[0] :
'';
46 $result .=
'<option value="'.htmlspecialcharsbx(
$name).
'"'.(($selectedField ==
$name) ?
" selected" :
"").
'>'
51 $result .=
'<!--__defaultOptionsValue:'.$selectedField.
'--><!--__modifyOptionsPromt:'.Loc::getMessage(
'BPDT_INTERNALSELECT_OPT_LABEL').
'-->';
65 $fields = self::getDocumentSelectFields($fieldType);
68 if (isset(
$fields[$optionsValue][
'Options']))
73 return static::normalizeOptions(
$options);
81 private static function getDocumentSelectFields(
FieldType $fieldType, $ignoreAliases =
false)
83 $runtime = \CBPRuntime::getRuntime();
84 $runtime->startRuntime();
85 $documentService = $runtime->getService(
'DocumentService');
96 if ($field[
'Type'] ===
'select' && mb_substr(
$key, -10) !==
'_PRINTABLE')
99 if (isset($field[
'Alias']) && !$ignoreAliases)
101 $result[$field[
'Alias']] = $field;
116 return parent::convertPropertyToView($fieldType, $viewMode, $property);
static renderControlOptions(FieldType $fieldType, $callbackFunctionName, $value)
static getFieldOptions(FieldType $fieldType)
static convertPropertyToView(FieldType $fieldType, int $viewMode, array $property)
const RENDER_MODE_JN_MOBILE
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
htmlspecialcharsbx($string, $flags=ENT_COMPAT, $doubleEncode=true)
if(empty($signedUserToken)) $key