8 (800) 100-5-100 Для всех регионов России - бесплатно
Заполните заявку Заполнение займет не более 3 минут
Получите подтверждение С Вами свяжется специалист по указанному номеру
Получите деньги В офисе банка или бесплатно доставим

Например, Иванов Иван Иванович

дд.мм.гггг

Например, [email protected]

' ); $('#credit_amount_slider').slider({ range: 'min', min: minAmount, max: maxAmount, step: 1000, value: amount }); setMinAmount(minAmount); setMaxAmount(maxAmount); setAmount(amount); $('#credit_amount_slider').slider('option', 'slide', function(event, ui){ setAmount(ui.value); // Зависимость допустимого срока кредита от суммы кредита var htm = ''; if (getAmount() 7 дней'; htm += ''; } else if (getAmount() > 20000){ htm += ''; htm += ''; htm += ''; htm += ''; htm += ''; } else{ htm += ''; htm += ''; htm += ''; htm += ''; htm += ''; htm += ''; htm += ''; } $('#credit_period').html(htm); }); $('#credit_period').change(function(){ var period = $(this).val(); if (period == '7 дней' || period == '14 дней'){ setMinAmount(2000); setMaxAmount(20000); } else if (period == '0'){ setMinAmount(2000); setMaxAmount(300000); } else{ setMinAmount(10000); setMaxAmount(300000); } }); /** * Выбор регионов. Начало */ // Регион прописки var reg_region = $('#registration_region').val(); $('#registration_region').parent().html(drawRegionsSelect(reg_region) + ''); // Регион проживания var live_region = $('#living_region').val(); if (live_region == reg_region){ $('#living_region').parent().html(' совпадает с регионом прописки'); } else{ $('#living_region').parent().html(drawRegionsSelect(live_region) + ''); } bindRegionsEvent(); $('#flag_regions_identity').click(function(){ $(this).parent().html(drawRegionsSelect(live_region) + ''); bindRegionsEvent(); }); function drawRegionsSelect(selected){ var html = ''; if (selected === 'Краснодарский край') {html += '';} else {html += '';} if (selected === 'Астраханская область') {html += '';} else {html += '';} html += ''; if (selected === 'Ростовская область') {html += '';} else {html += '';} if (selected === 'Волгоградская область') {html += '';} else {html += '';} html += '
Краснодарский крайКраснодарский крайАстраханская областьАстраханская область
Ростовская областьРостовская областьВолгоградская областьВолгоградская область
'; return html; } function bindRegionsEvent(){ $('.region-select .region').click(function(){ $(this).parents('.region-select').find('a').each(function(){ $(this).removeAttr('disabled').removeClass('btn').addClass('region'); }); $(this).attr('disabled', 'disabled').removeClass('region').addClass('btn'); $(this).parents('.controls').find('input').val($(this).text()); }); } /** * Выбор регионов. Конец */ $('#CreditConsumerCashSplit_form').submit(function (event) { if(document.getElementById('flag_regions_identity') !== null){ $('#living_region').val($('#registration_region').val()); } $('#credit_amount').val(getAmount()); }); /** * Вспомогательные функции */ // Разделение разрядов числа function intFormat(Int) { Int = intValue(Int); Int = Int.toFixed(0); return Int.replace(/(\d\d\d\d\d\d)$/, ' $1').replace(/(\d\d\d)$/, ' $1'); } // Получить числовое значение function intValue(Int) { Int = Int + ''; Int = Int.replace(/[^0-9]/g, ''); Int = parseInt(Int); return Int; } // Проверка наличия значения в массиве function inArray(needle, haystack) { for (ind in haystack) { if (haystack[ind] == needle) { return true; } } return false; } });