Esempio n. 1
0
        public ResponseDto <List <AddressCountryDto> > GetCountryList()
        {
            ResponseBo <List <AddressCountryBo> > responseBo = addressBusiness.GetCountryList(base.ToBaseBo());

            ResponseDto <List <AddressCountryDto> > responseDto = responseBo.ToResponseDto <List <AddressCountryDto>, List <AddressCountryBo> >();

            if (responseBo.IsSuccess && responseBo.Bo != null)
            {
                responseDto.Dto = new List <AddressCountryDto>();
                foreach (AddressCountryBo itemBo in responseBo.Bo)
                {
                    responseDto.Dto.Add(new AddressCountryDto()
                    {
                        Id        = itemBo.Id,
                        Name      = itemBo.Name,
                        HasStates = itemBo.HasStates
                    });
                }
            }

            return(responseDto);
        }