Ejemplo n.º 1
0
        public ResultEntity <CityEntity> Update(CityEntity cityEntity)
        {
            var validationResult = new ResultEntity <CityEntity>();

            using (var cityDA = new CityDA())
            {
                var resultUpdate = cityDA.Update(cityEntity);

                if (resultUpdate <= 0)
                {
                    validationResult.Warning.Add("Failed Updating City!");
                    return(validationResult);
                }

                validationResult.Value = cityEntity;
            }

            return(validationResult);
        }
Ejemplo n.º 2
0
 /// <summary>
 /// This Function is used to Update previously added City in database and is performed by SuperAdmin Only.
 /// </summary>
 public static bool Update(City info)
 {
     return(CityDA.Update(info));
 }