AnonSec Shell
Server IP : 85.193.89.191  /  Your IP : 18.118.31.93
Web Server : Apache
System : Linux 956367-cx40159.tmweb.ru 3.10.0-1160.105.1.el7.x86_64 #1 SMP Thu Dec 7 15:39:45 UTC 2023 x86_64
User : bitrix ( 600)
PHP Version : 8.1.27
Disable Function : NONE
MySQL : OFF  |  cURL : OFF  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /home/bitrix/www/bitrix/activities/bitrix/getlistsdocumentactivity/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     

Current File : /home/bitrix/www/bitrix/activities/bitrix/getlistsdocumentactivity/properties_dialog.php
<? if (!defined("B_PROLOG_INCLUDED") || B_PROLOG_INCLUDED!==true)die();
/** @var \Bitrix\Bizproc\Activity\PropertiesDialog $dialog */
$elementId = $dialog->getMap()['ElementId'];
$docType = $dialog->getMap()['DocumentType'];
$fields = $dialog->getMap()['Fields'];
?>
<tr>
	<td align="right" width="40%" valign="top">
		<span class="adm-required-field"><?=htmlspecialcharsbx($elementId['Name'])?>:</span>
	</td>
	<td width="60%">
		<?=$dialog->renderFieldControl($elementId, null, true, \Bitrix\Bizproc\FieldType::RENDER_MODE_DESIGNER)?>
	</td>
</tr>

<tr>
	<td align="right" width="40%" valign="top">
		<span class="adm-required-field"><?=htmlspecialcharsbx($docType['Name'])?>:</span>
	</td>
	<td width="60%" id="doctype_container">
		<?=$dialog->renderFieldControl($docType, null, false, \Bitrix\Bizproc\FieldType::RENDER_MODE_DESIGNER)?>
	</td>
</tr>

<tr id="fields_container">
	<td align="right" width="40%" valign="top">
		<span class="adm-required-field"><?=htmlspecialcharsbx($fields['Name'])?>:</span>
	</td>
	<td width="60%">
		<?=$dialog->renderFieldControl($fields, null, false, \Bitrix\Bizproc\FieldType::RENDER_MODE_DESIGNER)?>
	</td>
</tr>

<script>
	BX.ready(function()
	{
		var container = BX('doctype_container');
		var select = container ? container.querySelector('[name="lists_document_type"]') : null;
		var fieldsSelect = BX('fields_container').querySelector('select');

		BX.bind(select, 'change', function()
			{
				var documentType = this.value;
				BX.cleanNode(fieldsSelect);

				if (!documentType)
				{
					return;
				}

				BX.ajax({
					method: 'POST',
					dataType: 'json',
					url: '/bitrix/tools/bizproc_activity_ajax.php',
					data:  {
						'site_id': BX.message('SITE_ID'),
						'sessid' : BX.bitrix_sessid(),
						'document_type' : <?=Cutil::PhpToJSObject($dialog->getDocumentType())?>,
						'activity': 'GetListsDocumentActivity',
						'lists_document_type': documentType,
						'form_name': <?=Cutil::PhpToJSObject($formName)?>
					},
					onsuccess: function(response)
					{
						if (response)
						{
							response.options.forEach(function(opt)
							{
								fieldsSelect.appendChild(BX.create('option', {
									props: {value: opt.value},
									text: opt.text
								}))
							});
						}
					}
				});
			}
		);
	});
</script>

Anon7 - 2022
AnonSec Team