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 : |
'use strict'; import { Popup } from 'main.popup'; import { Button, ButtonColor, ButtonSize } from "ui.buttons"; import {Loc, Tag} from "main.core"; export class ConfirmDeleteDialog { constructor(params = {}) { this.entry = params.entry; } show() { this.dialog = new Popup({ titleBar: Loc.getMessage('EC_DEL_REC_EVENT'), content: this.getContent(), className: 'calendar__confirm-dialog', lightShadow: true, maxWidth: 700, minHeight: 120, autoHide: true, closeByEsc: true, draggable: true, closeIcon: true, animation: 'fading-slide', contentBackground: "#fff", overlay: { opacity: 15 }, cacheable: false, }); this.dialog.show(); } getContent() { const thisEventButton = new Button({ size: ButtonSize.MEDIUM, color: ButtonColor.LIGHT_BORDER, text: Loc.getMessage('EC_REC_EV_ONLY_THIS_EVENT'), events: { click: () => { this.entry.deleteThis(); this.close(); }, }, }); const nextEventButton = new Button({ size: ButtonSize.MEDIUM, color: ButtonColor.LIGHT_BORDER, text: Loc.getMessage('EC_REC_EV_NEXT'), events: { click: () => { this.entry.deleteNext(); this.close(); }, }, }); const allEventButton = new Button({ size: ButtonSize.MEDIUM, color: ButtonColor.LIGHT_BORDER, text: Loc.getMessage('EC_REC_EV_ALL'), events: { click : () => { this.entry.deleteAll(); this.close(); }, }, }); return Tag.render` <div class="calendar__confirm-dialog-content"> ${thisEventButton.render()} ${nextEventButton.render()} ${allEventButton.render()} </div> `; } close() { if (this.dialog) { this.dialog.close(); } } }