recaptcha hotfix after merge on production

This commit is contained in:
merelendor 2022-08-29 11:44:13 +03:00
parent f7351a80c1
commit e492abcce5
3 changed files with 21 additions and 50 deletions

3
.gitignore vendored
View File

@ -6,4 +6,5 @@ robots.txt
sitemap*
.xml
.htsecure
cron/yasprav.log
cron/yasprav.log
vizitka/tmp/

View File

@ -60,33 +60,9 @@ function form_leasing_request_submit()
{
grecaptcha.execute($("meta[name=recaptcha_site_key]").attr("content"), { action: 'submit' }).then(function(token)
{
<<<<<<< HEAD
if(response.status == "complete")
{
$("#form_leasing_process").css("display","none");
$("#form_leasing_success").css("display","flex");
$("#send_button_text").css("display", "block");
$("#send_button_spinner").css("display", "none");
leasing_form_submitting = false;
try
{
ym(66905533,'reachGoal','leasingform')
}
catch(e)
{
console.error(e);
}
}
else if(response.status == "error")
=======
formData.append("recaptcha_token", token);
$.ajax(
>>>>>>> 096fd217ce378867757d3998e9b6669473b0db85
{
url: "/api/forms/", type: 'POST', success: function(response)
{
@ -98,8 +74,17 @@ function form_leasing_request_submit()
$("#send_button_text").css("display", "block");
$("#send_button_spinner").css("display", "none");
leasing_form_submitting = false;
try
{
ym(66905533,'reachGoal','leasingform')
}
catch(e)
{
console.error(e);
}
}
else if(response.status === "error")
{

View File

@ -60,33 +60,9 @@ function form_leasing_request_submit()
{
grecaptcha.execute($("meta[name=recaptcha_site_key]").attr("content"), { action: 'submit' }).then(function(token)
{
<<<<<<< HEAD
if(response.status == "complete")
{
$("#form_leasing_process").css("display","none");
$("#form_leasing_success").css("display","flex");
$("#send_button_text").css("display", "block");
$("#send_button_spinner").css("display", "none");
leasing_form_submitting = false;
try
{
ym(66905533,'reachGoal','leasingform')
}
catch(e)
{
console.error(e);
}
}
else if(response.status == "error")
=======
formData.append("recaptcha_token", token);
$.ajax(
>>>>>>> 096fd217ce378867757d3998e9b6669473b0db85
{
url: "/api/forms/", type: 'POST', success: function(response)
{
@ -100,6 +76,15 @@ function form_leasing_request_submit()
$("#send_button_spinner").css("display", "none");
leasing_form_submitting = false;
try
{
ym(66905533,'reachGoal','leasingform')
}
catch(e)
{
console.error(e);
}
}
else if(response.status === "error")
{