PageSourceSearch

https://gkgross.ru/local/templates/gkgross-ru/components/complex/feedback/repair/form-repair.js

js gkgross.ru collected 2026-10-07 00:02:25 UTC 2,884 bytes, 47 lines download raw bytes

1jQuery(document).on('submit', 'form#form-repair', function() { 
2    var form = jQuery(this);
3    var phone = form.find('input[name="user_phone"]').val();
4    var fio = form.find('input[name="user_name"]').val();
5    var email = form.find('input[name="user_email"]').val();
6    var comp = form.find('input[name="user_comp"]').val();
7    var inn = form.find('input[name="user_inn"]').val();
8    var pos = form.find('input[name="user_pos"]').val();
9    var vin = form.find('input[name="user_vin"]').val();
10    var MESSAGE = form.find('textarea[name="MESSAGE"]').val();
11    var sub = 'Отслеживаемая форма обратной связи "Заявка на ремонт"';
12    var ct_site_id = '64250'; /* ID сайта внутри Calltouch */
13    var ct_data = { 
14        user_name: fio,
15        user_phone: phone,
16        user_email: email,
17        user_comp: comp,
18        user_inn: inn,
19        user_pos: pos,
20        user_vin: vin,
21        MESSAGE: MESSAGE,
22        subject: sub,
23        requestUrl: location.href,
24        sessionId: window.ct('calltracking_params','76cfhvi0').sessionId /* Чтобы определить источник заявки, передаем ID сессии Calltouch sessionId. Вместо wgblo7m9 нужно передавать mod_id скрипта Calltouch. */
25    };
26
27    /* При необходимости делаем проверку на корректность собранных с формы данных */
28    /* Например, обязательным для заполнения на форме является поле с телефоном, проверяем его наличие и не пустое ли оно */
29    if (typeof(phone) !== 'undefined' && phone !== '' && typeof(fio) !== 'undefined' && fio !== '' && typeof(email) !== 'undefined' && email !== '' && typeof(comp) !== 'undefined' && comp !== '' && typeof(inn) !== 'undefined' && inn !== '' && typeof(pos) !== 'undefined' && pos !== '' && typeof(vin) !== 'undefined' && vin !== '' && typeof(MESSAGE) !== 'undefined' && MESSAGE !== '' ) {
30       //*console.log('Отправка AJAX-запроса...');
31        /* Выполняем AJAX-запрос */
32        jQuery.ajax({ 
33            url: 'https://api.calltouch.ru/calls-service/RestAPI/requests/'+ct_site_id+'/register/', 
34            dataType: 'json', 
35            type: 'POST', 
36            data: ct_data,
37            success: function(response) {
38               //*console.log('Успешный AJAX-запрос:', response);
39            },
40            error: function(jqXHR, textStatus, errorThrown) {
41                //*console.error('Ошибка AJAX-запроса:', textStatus, errorThrown);
42            }
43        }); 
44    } else {
45        //*console.warn('Некорректный номер телефона. AJAX-запрос не будет выполнен.');
46    }
47});

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.