mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-31 21:19:21 +03:00
PreRelease 1.8.3
This commit is contained in:
parent
39566292af
commit
0ea982671b
40 changed files with 712 additions and 370 deletions
|
|
@ -34,8 +34,17 @@
|
|||
this.loginError = ko.observable(false);
|
||||
this.passwordError = ko.observable(false);
|
||||
|
||||
this.loginErrorAnimation = ko.observable(false).extend({'falseTimeout': 500});
|
||||
this.passwordErrorAnimation = ko.observable(false).extend({'falseTimeout': 500});
|
||||
|
||||
this.loginFocus = ko.observable(false);
|
||||
|
||||
this.formHidden = ko.observable(false);
|
||||
|
||||
this.formError = ko.computed(function () {
|
||||
return this.loginErrorAnimation() || this.passwordErrorAnimation();
|
||||
}, this);
|
||||
|
||||
this.login.subscribe(function () {
|
||||
this.loginError(false);
|
||||
}, this);
|
||||
|
|
@ -44,6 +53,14 @@
|
|||
this.passwordError(false);
|
||||
}, this);
|
||||
|
||||
this.loginError.subscribe(function (bV) {
|
||||
this.loginErrorAnimation(!!bV);
|
||||
}, this);
|
||||
|
||||
this.passwordError.subscribe(function (bV) {
|
||||
this.passwordErrorAnimation(!!bV);
|
||||
}, this);
|
||||
|
||||
this.submitRequest = ko.observable(false);
|
||||
this.submitError = ko.observable('');
|
||||
|
||||
|
|
@ -51,6 +68,9 @@
|
|||
|
||||
Utils.triggerAutocompleteInputChange();
|
||||
|
||||
this.loginError(false);
|
||||
this.passwordError(false);
|
||||
|
||||
this.loginError('' === Utils.trim(this.login()));
|
||||
this.passwordError('' === Utils.trim(this.password()));
|
||||
|
||||
|
|
@ -67,6 +87,7 @@
|
|||
{
|
||||
if (oData.Result)
|
||||
{
|
||||
this.formHidden(true);
|
||||
require('App/Admin').loginAndLogoutReload(true);
|
||||
}
|
||||
else if (oData.ErrorCode)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue