//public ActionResult Create(PropertyModel propertyModel,HttpPostedFileBase fileBase ) //{ // IEnumerable<PropertyType> propertyTypes = propertyBL.GetPropertyType(); // ViewBag.propertyId = new SelectList(propertyTypes, "PropertyTypeID", "Type"); // Property property = new Property(); // if (fileBase != null && fileBase.ContentLength > 0) // { // var fileName = Path.GetFileName(fileBase.FileName); // var path = Path.Combine(Server.MapPath("~/App_Data/Images"), fileName); // fileBase.SaveAs(path); // } // if (ModelState.IsValid) // { // propertyModel.Image = new byte[fileBase.ContentLength]; // fileBase.InputStream.Read(propertyModel.Image, 0, fileBase.ContentLength); // property = AutoMapper.Mapper.Map<PropertyModel, Property>(propertyModel); // if (propertyBL.Create(property) > 0) // { // TempData["TypeId"] = property; // return RedirectToAction("AddFeature", "PropertyFeature"); // } // else // { // ViewBag.Message = "failed"; // } // } // return View(); //} public List <int> GetFeatureValues(int id) { Dictionary <int, int> PropertyValues = propertyBL.EditPropertyValues(id); foreach (KeyValuePair <int, int> item in PropertyValues) { FeatureKey.Add(item.Key); } return(FeatureKey); }