Ejemplo n.º 1
0
        public async Task <IHttpActionResult> ChangeUserName(string newUserName, string password, string validateCode, string userName = "")
        {
            userName = UserContract.UserInfos.Single(x => x.Id == OperatorId).SysUser.UserName;
            var result = await UserContract.ChangeUserName(userName, newUserName, password, validateCode);

            return(Json(result.ToApiResult()));
        }
Ejemplo n.º 2
0
        public async Task <ActionResult> ChangeUserName(string userName, string newUserName, string password, string validateCode)
        {
            if (OperatorId == 0)
            {
                return(Json(new ApiResult("身份信息错误", OperationResultType.Error)));
            }
            var result = await UserContract.ChangeUserName(userName, newUserName, password, validateCode);

            return(Json(result.ToApiResult()));
        }