I can't register from a client. Is shows DrupalGap API Call Error:

\":\"A valid date is required for \\u0414\\u0430\\u0442\\u0430 \\u0440\\u043e\\u0436\\u0434\\u0435\\u043d\\u0438\\u044f.\",\"field_first_name][und][0][value\":\"\\u0418\\u043c\\u044f field is required.\",\"field_last_name][und][0][value\":\"\\u0424\\u0430\\u043c\\u0438\\u043b\\u0438\\u044f field is required.\",\"captcha_response\":\"What code is in the image? field is required.\",\"terms_of_use\":\"I agree with these terms field is required.\"}}","status":406,"statusText":"Not Acceptable: Password field is required. A valid date is required for Дата рождения. Имя field is required. Фамилия field is required. What code is in the image? field is required. I agree with these terms field is required."},"textStatus":"error","errorThrown":"Not Acceptable: Password field is required. A valid date is required for Дата рождения. Имя field is required. Фамилия field is required. What code is in the image? field is required. I agree with these terms field is required."}
01-21 09:15:24.019 3757-3757/com.***.siteclient I/Web Console﹕ {"jqXHR":{"readyState":4,"responseText":"{\"form_errors\":{\"pass\":\"Password field is required.\",\"field_birthday][und][0][value\":\"A valid date is requ

Help Me Please

CommentFileSizeAuthor
#1 error.PNG106.16 KBdecentyo

Comments

decentyo’s picture

StatusFileSize
new106.16 KB
decentyo’s picture

I figured out...

tyler.frankenstein’s picture

Title: Register » User Register
Status: Active » Closed (works as designed)

Please share how you figured it out, thanks.

From the screen shots, it looks like your registration form has custom fields on it. The latest snapshot of the 7.x-1.x-alpha mobile app dev kit now supports custom fields on the user registration form. If you have a date field on the form, you'll need the DrupalGap Date module (currently only supports the year component).

eudaemonia’s picture

I'm having a similar user registration problem. I cordova run iOS and I can login/log out through the app just fine. But if I register an account through the app, it does create the account on my site, but the user can't log in with it (through the app or the website). It seems that the app is not setting the password or something like that. If I reset the password for the user, then the user can log in through the app.

So, to sum up when a user creates an account through the app, I get the message "index.html, registration complete!" and then "Alert: Wrong username or password". Any ideas?

tyler.frankenstein’s picture

What version of the Services module are you using?

There is a known "bug" with Services that results in the password not being set properly on registration:

#2198005: Services User Register resource does not set the right password
#2195489: PHP Parse error: syntax error, unexpected ':' in user_resource.inc on line 286

Try applying that patch (if necessary) to your Services module, then let me know if that fixes it or not.

eudaemonia’s picture

I'm using Services 7.x-3.7. I applied the patch to user_resources.inc and ran update.php, cleared caches, AND IT'S FIXED! I am so glad I asked. Thanks for the quick reply!