PageSourceSearch

https://ocprof.ru/themes/individual/public/js/app.js

js ocprof.ru collected 2026-10-01 14:44:26 UTC 5,328 bytes, 179 lines download raw bytes

1$(function() {
2
3	//for ie8
4    var alertFallback = false;
5    if (typeof console === "undefined" || typeof console.log === "undefined") {
6        console = {};
7        if (alertFallback) {
8            console.log = function(msg) {
9                alert(msg);
10            };
11        } else {
12            console.log = function() {};
13        }
14    }
15
16    $.itexUp({
17        elementID: 'up', //ID элемента
18        showButtonHeight: 300, //Высота прокрутки в пикселя, когда появляется кнопка
19        speed: 1000 //Скорость прокрутки в милисекундах
20    });
21
22    $('table').wrap('<div class="table-responsive">');
23});
24
25
26$(document).ready(function() {
27    $('.navN .firstpage').attr('title', 'На первую');
28    $('.navN .lastpage').attr('title', 'На последнюю');
29	$('.navN .nextpage').attr('title', 'На следущую');
30	$('.navN .prevpage').attr('title', 'На предыдущую');
31
32	// img alt fix
33	$('img').each(function(){
34		if (!$(this).attr('alt')) { $(this).attr('alt',""); }
35	});
36
37    /*select2*/
38    $('select').select2({
39        minimumResultsForSearch: Infinity
40    });
41    
42    /*event2*/
43    $('.event2-block-header').click(function(){
44        $(this).toggleClass("on");
45        $(this).next('.event2-block-body').slideToggle();
46        return false;
47    });
48
49    /* slider2 */
50    $('.slider-event').slick({
51        autoplay: false,
52        dots: false,
53        arrows: true,
54        slidesToShow: 3,
55        slidesToScroll: 1,
56        responsive: [
57            {
58                breakpoint: 991,
59//сообщает, при какой ширине экрана нужно включать настройки
60                settings: {
61                    slidesToShow: 2,
62                    slidesToScroll: 1,
63                    infinite: true
64                }
65            },
66            {
67                breakpoint: 767,
68//сообщает, при какой ширине экрана нужно включать настройки
69                settings: {
70                    slidesToShow: 1,
71                    slidesToScroll: 1,
72                    infinite: true
73                }
74            }
75        ]
76    });
77    
78    /*gallery*/
79    $(".fancybox").fancybox({
80        'padding'		: 0,
81         autoDimensions: false,
82        'autoSize':     false,
83        'maxHeight':       '70%',
84        tpl : {
85            closeBtn: '<a title="" class="fancybox-item fancybox-close"></a>',
86            next: '<a title="" class="fancybox-nav fancybox-next"><span></span></a>',
87            prev: '<a title="" class="fancybox-nav fancybox-prev"><span></span></a>',
88        }
89    });
90
91    /*event2*/
92    $('.toggle').click(function(){
93        $(this).toggleClass("on");
94        $('.menu-1').slideToggle();
95    });
96	
97	$('print-modal').click (function(){
98		var html_to_print=$('div#exampleModal-2').html()
99		var iframe=$('<iframe id="print_frame">');
100		$('body').append(iframe);
101		var doc = $('#print_frame')[0].contentDocument || $('#print_frame')[0].contentWindow.document;
102		var win = $('#print_frame')[0].contentWindow || $('#print_frame')[0];
103		doc.getElementsByTagName('body')[0].innerHTML=html_to_print;
104		win.print();
105		$('iframe').remove();
106	});
107    
108
109    /*calendar*/
110    $( "#datepicker, #datepicker-responsive" ).datepicker();
111
112    /*hide fields*/
113    hideFields($('#select2-EventOrder_type-container').text());
114
115    $('#EventOrder_type').on('change', function() {
116        hideFields($('#select2-EventOrder_type-container').text());
117    });
118	
119	
120
121
122function printData(className)
123{
124    newWin= window.open("");
125    newWin.document.write($(className).html());
126    newWin.print();
127    newWin.close();
128}
129    function hideFields(type_discount) {
130        switch (type_discount) {
131            case 'Юридическое лицо':
132                $('.f-org').show();
133                $('#EventOrder_name_corp').attr('value', '');
134                $('#EventOrder_inn_corp').attr('value', '');
135                break;
136            default:
137                $('.f-org ').hide();
138                $('#EventOrder_name_corp').attr('value', 0);
139                $('#EventOrder_inn_corp').attr('value', 0);
140                break;
141        }
142    }
143});
144
145$(function() {
146    $('#inline').on('submit', function (event) {
147        event.preventDefault;
148		
149        var self = $(this);
150        var url = self.attr('action');
151
152        $.post(url, self.serialize(), function (response) {
153            var form = $('form', response);
154
155            if (form.attr('id') != undefined) {
156                var name= $('.f-name', response);
157                var phone= $('.f-phone', response);
158                var email= $('.f-email', response);
159                var recaptha = $('.recaptha', response);
160                $('.f-name').replaceWith(name);
161                $('.f-phone').replaceWith(phone);
162                $('.f-email').replaceWith(email);
163                $('.recaptha').replaceWith(recaptha);
164            }
165            else {
166                $('form').replaceWith("Ваше сообщение успешно отправлено!");
167                $('.contact-fos p').hide();
168            }
169
170        });
171
172        return false;
173    })
174});
175$(function() {
176	$('#order1').submit(function(){
177		yaCounter20532451.reachGoal('success');
178	});
179});

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.