diff options
Diffstat (limited to 'StoneIsland/www/js/lib/account')
| -rw-r--r-- | StoneIsland/www/js/lib/account/LoginView.js | 12 | ||||
| -rw-r--r-- | StoneIsland/www/js/lib/account/LogoutView.js | 1 | ||||
| -rw-r--r-- | StoneIsland/www/js/lib/account/SignupView.js | 23 |
3 files changed, 32 insertions, 4 deletions
diff --git a/StoneIsland/www/js/lib/account/LoginView.js b/StoneIsland/www/js/lib/account/LoginView.js index 31137c55..5058d335 100644 --- a/StoneIsland/www/js/lib/account/LoginView.js +++ b/StoneIsland/www/js/lib/account/LoginView.js @@ -3,24 +3,30 @@ var LoginView = View.extend({ el: "#login", events: { + "click .newuser": "newuser", "submit form": "submit", }, initialize: function(){ this.$form = this.$("form") + this.$msg = this.$(".msg") }, show: function(){ this.$form.get(0).reset() + this.$msg.html("* Your personal and payment information will always remain private") document.body.className = "login" }, + newuser: function(){ + app.router.go("account/signup") + }, + submit: function(e){ e.preventDefault() }, success: function(){ - // change login in ui to logout or whatever }, - -})
\ No newline at end of file + +}) diff --git a/StoneIsland/www/js/lib/account/LogoutView.js b/StoneIsland/www/js/lib/account/LogoutView.js index d5b70aff..45abc303 100644 --- a/StoneIsland/www/js/lib/account/LogoutView.js +++ b/StoneIsland/www/js/lib/account/LogoutView.js @@ -14,7 +14,6 @@ var LogoutView = View.extend({ }, success: function(){ - // change login in ui to logout or whatever }, })
\ No newline at end of file diff --git a/StoneIsland/www/js/lib/account/SignupView.js b/StoneIsland/www/js/lib/account/SignupView.js index 395c0b00..c6cd2930 100644 --- a/StoneIsland/www/js/lib/account/SignupView.js +++ b/StoneIsland/www/js/lib/account/SignupView.js @@ -1,5 +1,28 @@ var SignupView = View.extend({ el: "#signup", + + events: { + "submit form": "submit", + }, + + initialize: function(){ + this.$form = this.$("form") + this.$msg = this.$(".msg") + }, + + show: function(){ + this.$form.get(0).reset() + this.$msg.html("* Your personal and payment information will always remain private") + document.body.className = "signup" + }, + + submit: function(e){ + e.preventDefault() + }, + + success: function(){ + // change login in ui to logout or whatever + }, })
\ No newline at end of file |
