Esempio n. 1
0
        public async Task <IActionResult> AddAdmin(Adminstrator newAdmin)
        {
            if (ModelState.IsValid)
            {
                _adb.Add(newAdmin);
                await _adb.SaveChangesAsync();

                return(RedirectToAction("AIndex"));
            }
            return(View(newAdmin));
        }
 public void AddStockExchange(StockExchange stockExchange)
 {
     context.Add(stockExchange);
     context.SaveChanges();
 }