public async Task <IActionResult> OnGetAsync(int?id) { if (id == null) { return(NotFound()); } masina = await _context.masina.FirstOrDefaultAsync(m => m.id == id); if (masina == null) { return(NotFound()); } ViewData["DealerID"] = new SelectList(_context.Set <Dealer>(), "ID", "DealerName"); return(Page()); }
public IActionResult OnGet() { ViewData["DealerID"] = new SelectList(_context.Set <Dealer>(), "ID", "DealerName"); return(Page()); }