예제 #1
0
        public ActionResult ChanagePassword(string oldPassword, string newPassword)
        {
            var user = GetUserData();

            if (UserLogic.ChanagePassword(user.UserId, oldPassword, newPassword))
            {
                return(Json(new ResultModel(ApiStatusCode.OK)));
            }
            else
            {
                return(Json(new ResultModel(ApiStatusCode.密码修改失败)));
            }
        }
예제 #2
0
        public ActionResult ChanagePassword(string oldPassword, string newPassword)
        {
            try
            {
                var user = GetUserData();

                if (UserLogic.ChanagePassword(user.UserId, oldPassword, newPassword))
                {
                    return(Json(new ResultModel(ApiStatusCode.OK, "密码设置成功")));
                }
                else
                {
                    return(Json(new ResultModel(ApiStatusCode.密码修改失败)));
                }
            }
            catch (Exception ex)
            {
                LogHelper.Log(string.Format("AllyApplyAudit user:message:{0},StackTrace:{1}", ex.Message, ex.StackTrace), LogHelperTag.ERROR);
                return(Json(new ResultModel(ApiStatusCode.SERVICEERROR)));
            }
        }