コード例 #1
0
        public Guid DoLogin([FromBody] UserCredential credential)
        {
            Logger.LogDebug($"User '{credential.userName}' tries to login.");
            Guid sessionId = _loginManager.DoLogin(credential.userName, credential.password);

            return(sessionId);
        }
コード例 #2
0
ファイル: LoginController.cs プロジェクト: shafkathaider/HRMS
        public ActionResult Login(string employeeId, string password)
        {
            OrganizationInformation organization = new OrganizationInformation();

            var msg = _iLoginManager.DoLogin(employeeId, password);

            if (msg.MessageType == MessageTypes.Success)
            {
                CreateSession(employeeId);
            }
            else
            {
                Session["Session"] = null;
            }

            return(Json(msg, JsonRequestBehavior.AllowGet));
        }