Beispiel #1
0
        internal static User GetUserInfoByName(string pName)
        {
            GetUserInfoByParamsReq req = new GetUserInfoByParamsReq();

            req.BusinessData.UserName = pName;

            GetUserInfoByParamsRes res = _ClientServiceBase.ExecuteService <GetUserInfoByParamsReq, GetUserInfoByParamsRes>(WrapperSecurityProvider, req);

            if (res.Error != null)
            {
                throw Fwk.Exceptions.ExceptionHelper.ProcessException(res.Error);
            }

            return(res.BusinessData.UserInfo);
        }
Beispiel #2
0
        public void GetUserInfoByParams_NoService()
        {
            string strErrorResult = string.Empty;

            Fwk.Security.SVC.GetUserInfoByParamsService service = new Fwk.Security.SVC.GetUserInfoByParamsService();
            GetUserInfoByParamsReq req = new GetUserInfoByParamsReq();

            req.BusinessData.UserName = wTestUser.UserName;
            try
            {
                GetUserInfoByParamsRes res = service.Execute(req);
            }
            catch (Exception ex)
            {
                strErrorResult = Fwk.Exceptions.ExceptionHelper.GetAllMessageException(ex);
            }

            Assert.AreEqual <String>(strErrorResult, string.Empty, strErrorResult);
        }
Beispiel #3
0
        User GetByNAme(string pUserName)
        {
            GetUserInfoByParamsService service = new GetUserInfoByParamsService();
            GetUserInfoByParamsReq     req     = new GetUserInfoByParamsReq();

            req.BusinessData.UserName = pUserName;

            GetUserInfoByParamsRes res = null;

            try
            {
                //Comprovar si se creo el usuario
                res = service.Execute(req);
            }
            catch (Exception ex)
            {
                base.StrExceptionMessage = Fwk.Exceptions.ExceptionHelper.GetAllMessageException(ex);
                return(null);
            }

            return(res.BusinessData.UserInfo);
        }
Beispiel #4
0
        internal static User GetUserInfoByName(string pName)
        {

            GetUserInfoByParamsReq req = new GetUserInfoByParamsReq();
            req.BusinessData.UserName = pName;

            GetUserInfoByParamsRes res = _ClientServiceBase.ExecuteService<GetUserInfoByParamsReq, GetUserInfoByParamsRes>(WrapperSecurityProvider,req);

            if (res.Error != null)
                throw Fwk.Exceptions.ExceptionHelper.ProcessException(res.Error);

            return res.BusinessData.UserInfo;
        }
Beispiel #5
0
        public void GetUserInfoByParams_NoService()
        {
            string strErrorResult = string.Empty;
            Fwk.Security.SVC.GetUserInfoByParamsService service = new Fwk.Security.SVC.GetUserInfoByParamsService();
            GetUserInfoByParamsReq req = new GetUserInfoByParamsReq();
            req.BusinessData.UserName = wTestUser.UserName;
            try
            {

                GetUserInfoByParamsRes res = service.Execute(req);
            }
            catch (Exception ex)
            {
                strErrorResult = Fwk.Exceptions.ExceptionHelper.GetAllMessageException(ex);
            }

            Assert.AreEqual<String>(strErrorResult, string.Empty, strErrorResult);
        }
Beispiel #6
0
        User GetByNAme(string pUserName)
        {
            GetUserInfoByParamsService service = new GetUserInfoByParamsService();
            GetUserInfoByParamsReq req = new GetUserInfoByParamsReq();
            req.BusinessData.UserName = pUserName;

            GetUserInfoByParamsRes res = null;

            try
            {
                //Comprovar si se creo el usuario
                res = service.Execute(req);
                
            }
            catch (Exception ex)
            {
                base.StrExceptionMessage = Fwk.Exceptions.ExceptionHelper.GetAllMessageException(ex);
                return null;
            }
          
           return  res.BusinessData.UserInfo;
        }