/// <summary> /// Show items used in current shelter. /// </summary> /// <param name="shelterId"></param> /// <returns></returns> public ActionResult ShelterItems(int shelterId) { ViewData["ShelterId"] = shelterId; return(PartialView("Grid/_GridForShelterItems", new ShelterItemsModel { ShelterKey = shelterId, ShelterItems = ShelterRepository.GetShelterItemsDetail(shelterId) })); }
/// <summary> /// Get model for ShelterItems. /// </summary> /// <param name="shelterId">shelterId for which items to be shown.</param> /// <returns></returns> private static ShelterItemsModel GetShelterItems(int shelterId) { return(new ShelterItemsModel { ShelterKey = shelterId, ShelterItems = ShelterRepository.GetShelterItemsDetail(shelterId) }); }