diff options
author | Struan Donald <struan@exo.org.uk> | 2013-05-24 11:37:14 +0100 |
---|---|---|
committer | Struan Donald <struan@exo.org.uk> | 2013-05-24 11:37:14 +0100 |
commit | 490e11e7030ec445dcf7b18d29838e9d90b7d41a (patch) | |
tree | de958a042878f3ebe8a9ad76455a33a147a2a0c8 /www/js | |
parent | 96161b33aa5dcdf9be97b8274c406184ea9dd36e (diff) |
login page design and sort behaviour of hiding/showing on login/out
Diffstat (limited to 'www/js')
-rw-r--r-- | www/js/views/login.js | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/www/js/views/login.js b/www/js/views/login.js index 98ede73..312eda5 100644 --- a/www/js/views/login.js +++ b/www/js/views/login.js @@ -35,8 +35,8 @@ that.model.set('name', data.name); that.model.save(); FMS.isLoggedIn = 1; - $('#password_row').hide(); - $('#success_row').show(); + that.$('#password_row').hide(); + that.$('#success_row').show(); } else { that.validationError('form_email', FMS.strings.login_error); } @@ -57,12 +57,13 @@ timeout: 30000, success: function( data, status ) { FMS.isLoggedIn = 0; - $('#password_row').hide(); - $('#success_row').show(); that.model.set('password', ''); that.model.save(); - $('#signed_in_row').hide(); - $('#password_row').show(); + that.$('#form_email').val(''); + that.$('#form_password').val(''); + that.$('#success_row').hide(); + that.$('#signed_in_row').hide(); + that.$('#password_row').show(); }, error: function() { // TODO fix this |