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/cvetdv.ru/bitrix/js/skyweb24.popuppro/admin/ |
Upload File : |
BX.ready(function(){BX.namespace("PopupproAdminSlider");BX.PopupproAdminSlider=function(){this.init()};BX.PopupproAdminSlider.prototype={init:function(){this.c_wrap=document.querySelector(".slide_type");if(!this.c_wrap){return} this._events()},selectSlide:function(slide){let type=slide.dataset.id;this._changeActiveSlide(slide.dataset.id);$('input[name=type]').val(slide.dataset.id);setDescription();managerPopupPro.createTemplateForm(type);this._selectContactTab(type);BX.onCustomEvent('onChangeTemplate',[{type:type,template:!1}])},_changeActiveSlide:function(type){this.c_wrap.querySelectorAll(".slide").forEach((item)=>{item.classList.remove("active");if(item.dataset.id===type){item.classList.add("active");document.querySelector("input[name='type']").value=type}})},_selectContactTab:function(type){if(managerPopupPro&&type=='contact'){$('.block.contacts').css('display','block')}else{$('.block.contacts').css('display','none')} if(managerPopupPro&&(type=='banner'||type=='video'||type=='action'||type=='contact'||type=='html'||type=='coupon'||type=='roulette'||type=='discount'||type=='thimbles')){$('.block.timer').css('display','block')}else{$('.block.timer').css('display','none')} if(managerPopupPro&&type=='roulette'){$('.block.roulette').css('display','block')}else{$('.block.roulette').css('display','none')} if(managerPopupPro&&type=='thimbles'){$('.thimbles.table.constructor-prize').css('display','block')}else{$('.thimbles.table.constructor-prize').css('display','none')}},_events:function(){let _self=this;BX.bindDelegate(this.c_wrap,"click",{className:"slide"},function(){_self.selectSlide(this)});BX.addCustomEvent('onTemplatesLoaded',function(AdminTemplates){_self._changeActiveSlide(AdminTemplates.getTypeSelectedName());_self._selectContactTab(AdminTemplates.getTypeSelectedName())})}}})