public void AddReportJob(ReportJob reportJob)
 {
     if (reportJob == null)
     {
         throw new ArgumentNullException(nameof(reportJob));
     }
     _context.Add(reportJob);
 }
예제 #2
0
        public async Task <IActionResult> Create([Bind("idCrypto,Name,Symbol,Price,Change24h,Change7d")] Crypto crypto)
        {
            if (ModelState.IsValid)
            {
                _context.Add(crypto);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(crypto));
        }