summaryrefslogtreecommitdiff
path: root/StoneIsland/platforms/ios/www/js/lib/auth/SignupView.js
diff options
context:
space:
mode:
authorJules Laplace <jules@okfoc.us>2015-12-02 21:00:30 -0500
committerJules Laplace <jules@okfoc.us>2015-12-02 21:00:30 -0500
commit393dc6eaf8d5a119c9cf71f1f5dac44abf70db59 (patch)
tree84d2856b9b7c97731970347a9357722f63679b4e /StoneIsland/platforms/ios/www/js/lib/auth/SignupView.js
parentd6910087feae6cd30141a615f2de753c37af14b8 (diff)
build..
Diffstat (limited to 'StoneIsland/platforms/ios/www/js/lib/auth/SignupView.js')
-rw-r--r--StoneIsland/platforms/ios/www/js/lib/auth/SignupView.js15
1 files changed, 12 insertions, 3 deletions
diff --git a/StoneIsland/platforms/ios/www/js/lib/auth/SignupView.js b/StoneIsland/platforms/ios/www/js/lib/auth/SignupView.js
index 22b310de..bba959bd 100644
--- a/StoneIsland/platforms/ios/www/js/lib/auth/SignupView.js
+++ b/StoneIsland/platforms/ios/www/js/lib/auth/SignupView.js
@@ -4,7 +4,8 @@ var SignupView = FormView.extend({
action: sdk.account.signup,
last_data: null,
-
+
+/*
test_data: {
"Email": "testit.account" + Math.floor(Math.random() * 10000000) + "@yoox.com",
"Password": "TestPassword",
@@ -16,7 +17,8 @@ var SignupView = FormView.extend({
"DataProfiling": true,
"DataProfiling2": true,
},
-
+*/
+
events: {
"click .privacy-msg": "privacy_link",
"submit form": "save",
@@ -47,6 +49,7 @@ var SignupView = FormView.extend({
"Surname": "Please enter your last name.",
"Email": "Please enter a valid email address.",
"ConfirmEmail": "Please enter a valid email address.",
+ "BirthDay": "Please enter your birthday.",
"Password": "Please enter your password.",
"Password2": "Please enter your password again.",
"DataProfiling": "You must agree to data profiling.",
@@ -97,7 +100,13 @@ var SignupView = FormView.extend({
},
error: function(data){
- console.log('error', data)
+ try {
+ data = JSON.parse(data.responseText)
+ app.signup.show_errors([[ 'Name', data['Error']['Description'] ]])
+ }
+ catch (e) {
+ app.signup.show_errors([[ 'Name', "There was an unknown error." ]])
+ }
},
cancel: function(){