added authentication.
This commit is contained in:
12
wwwroot/js/login.js
Normal file
12
wwwroot/js/login.js
Normal file
@@ -0,0 +1,12 @@
|
||||
function performLogin() {
|
||||
var userName = $("#inputUserName").val();
|
||||
var userPassword = $("#inputUserPassword").val();
|
||||
var isPersistent = $("#inputPersistent").is(":checked");
|
||||
$.post('/Login/Login', {userName: userName, password: userPassword, isPersistent: isPersistent}, function (data) {
|
||||
if (data) {
|
||||
window.location.href = '/Home';
|
||||
} else {
|
||||
errorToast("Invalid Login Credentials, please try again.");
|
||||
}
|
||||
})
|
||||
}
|
||||
Reference in New Issue
Block a user