Commit 1ff541b28630f9b579b83cd7b55b213686fe88a7
1 parent
7a0f8200
Committing updated code for login restructured
Showing
1 changed file
with
7 additions
and
6 deletions
400-SOURCECODE/AIAHTML5.API/Controllers/AuthenticateController.cs
@@ -130,6 +130,7 @@ namespace AIAHTML5.API.Controllers | @@ -130,6 +130,7 @@ namespace AIAHTML5.API.Controllers | ||
130 | { | 130 | { |
131 | objUser.IsCorrectPassword = false; | 131 | objUser.IsCorrectPassword = false; |
132 | objUser.IncorrectLoginAttemptCount = AIAHTML5.API.Models.Users.checkNoOfWrongAttempts(objUser.Id) + 1; | 132 | objUser.IncorrectLoginAttemptCount = AIAHTML5.API.Models.Users.checkNoOfWrongAttempts(objUser.Id) + 1; |
133 | + objUser.LoginFailureCauseId = ErrorHelper.E_PASSWORD_NOT_MATCH; | ||
133 | //01. insert wrong attempt in dtabase | 134 | //01. insert wrong attempt in dtabase |
134 | if (objUser.IncorrectLoginAttemptCount == 1) | 135 | if (objUser.IncorrectLoginAttemptCount == 1) |
135 | { | 136 | { |
@@ -165,12 +166,12 @@ namespace AIAHTML5.API.Controllers | @@ -165,12 +166,12 @@ namespace AIAHTML5.API.Controllers | ||
165 | } | 166 | } |
166 | } | 167 | } |
167 | } | 168 | } |
168 | - if (objUser.License != null && !string.IsNullOrEmpty(objUser.License.AccountNumber)) | ||
169 | - { | ||
170 | - int result = AIAHTML5.API.Models.Users.insertUserLoginLog(objUser.License.AccountNumber, objUser.LoginFailureCauseId, null, objUser.EditionId.ToString(), null); | ||
171 | - if (result < 0) | ||
172 | - logger.Fatal("Unable to insert wrong attempt detail in UserLoginLog table for accountNumber= " + objUser.License.AccountNumber); | ||
173 | - } | 169 | + //if (objUser.License != null && !string.IsNullOrEmpty(objUser.License.AccountNumber)) |
170 | + //{ | ||
171 | + // int result = AIAHTML5.API.Models.Users.insertUserLoginLog(objUser.License.AccountNumber, objUser.LoginFailureCauseId, null, objUser.EditionId.ToString(), null); | ||
172 | + // if (result < 0) | ||
173 | + // logger.Fatal("Unable to insert wrong attempt detail in UserLoginLog table for accountNumber= " + objUser.License.AccountNumber); | ||
174 | + //} | ||
174 | } | 175 | } |
175 | } | 176 | } |
176 | 177 |