Commit eaf3972b authored by Gabriel Monnerat's avatar Gabriel Monnerat

fix issue to reload page when an user is created.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@44164 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent d2a188af
...@@ -154,22 +154,16 @@ function displayLoginForm(){ \n ...@@ -154,22 +154,16 @@ function displayLoginForm(){ \n
displayFormMessage("Please confirm your password correctly..");\n displayFormMessage("Please confirm your password correctly..");\n
return false;\n return false;\n
}\n }\n
$.ajax({\n $.getJSON(\'ERPSite_createUNGUser?\' + $("form#create-user").serialize(), function(response){\n
type: \'post\',\n if (response == null){\n
url: \'ERPSite_createUNGUser\',\n displayFormMessage(formHash.login_name + " is not available, please try another...");\n
data: $("form#create-user").serializeArray(),\n return false;\n
dataType: "json",\n }\n
success: function(data){\n else {\n
if (jQuery.parseJSON(data) == null){\n var paramStr = "first_name=" + formHash.firstname +\n
displayFormMessage(formHash.login_name + " is not available, please try another...");\n "&" + "last_name=" + formHash.lastname;\n
return false;\n setTimeout(waitCreateUNGUser(paramStr), 2000); \n
}\n }\n
else {\n
var paramStr = "first_name=" + formHash.firstname +\n
"&" + "last_name=" + formHash.lastname;\n
setTimeout(waitCreateUNGUser(paramStr), 2000); \n
}\n
},\n
});\n });\n
});\n });\n
});\n });\n
......
281 282
\ No newline at end of file \ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment