public void Delete(int id, [FromBody] PlaceVM place) { PlaceDTO _place = _mapper.Map <PlaceDTO>(place); _place.Id = id; _placeService.Delete(_place); }
public PlaceVM Get(int id) { var place = _placeService.GetPlaceById(id); PlaceVM response = _mapper.Map <PlaceVM>(place); return(response); }
public IActionResult GetMenu(int menuCategotyID) { PlaceVM placeVM = new PlaceVM(this.Context); ViewBag.MenuCatID = menuCategotyID; ViewBag.menuCat = menuCategotyID; return(View(placeVM)); }
public IActionResult Index() { var allHumans = _context.Menschen.ToList(); var allAnimals = _context.Tiere.ToList(); PlaceVM placeVM = new PlaceVM { Animals = allAnimals, Humans = allHumans, PlaceName = "Walt Disney", Time = DateTime.Now }; return(View(placeVM)); }
public IActionResult GetAllSupermarketsbyArea(int AreaID) { PlaceVM placeVM = new PlaceVM(this.Context); return(View(placeVM.GetAllSupermarket(AreaID))); }
public IActionResult GetFilteredPlaces(int areaID, int placeCategoryID) { PlaceVM vM = new PlaceVM(_context); return(View(vM.FilterPlacesByAreaAndCategory(areaID, placeCategoryID))); }
public IActionResult GetSupermarketSections(int supermarketID) { PlaceVM vM = new PlaceVM(Context); return(View(vM.GetSupermarketMenuCategory(supermarketID))); }
public IActionResult GetAllAreaSupermarkets(int areaID) { PlaceVM vM = new PlaceVM(Context); return(View(vM.GetAllSupermarket(areaID))); }
public void Post([FromBody] PlaceVM place) { PlaceDTO _place = _mapper.Map <PlaceDTO>(place); _placeService.Insert(_place); }
public PlacePage(PlaceVM viewModel) { InitializeComponent(); ViewModel = viewModel; ViewModel.InventoryListVM.Navigation = this.Navigation; ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "1", Category = 1, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "2", Category = 2, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "3", Category = 3, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "4", Category = 4, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "5", Category = 5, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "6", Category = 6, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "7", Category = 1, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "8", Category = 2, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "9", Category = 3, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "10", Category = 4, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "11", Category = 5, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "12", Category = 6, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "13", Category = 1, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "14", Category = 2, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "15", Category = 3, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); ViewModel.InventoryListVM.InventoryObjects.Add(new InventoryObjectVM() { Name = "16", Category = 4, Description = "qedqe", ListViewModel = ViewModel.InventoryListVM }); this.BindingContext = ViewModel; }