Beispiel #1
0
        public async Task <HttpResponseMessage> AddProperties(AddPropertiesDto properties)
        {
            Response <Entities.Entities.Property> httpResponse = new Response <Entities.Entities.Property>();

            try
            {
                httpResponse.RequestState = true;
                httpResponse.ErrorState   = !await _propertyManager.AddProperties(properties.PropertyList.Adapt <List <Entities.Entities.Property> >());
            }
            catch (Exception ex)
            {
                httpResponse.ErrorState = true;
                httpResponse.ErrorList.Add(ex.Adapt <ApiException>());
            }
            return(httpResponse);
        }