public ActionResult DeleteConfirmed(int id)
        {
            InvoiceStatistic invoiceStatistic = db.InvoiceStatistics.Find(id);

            db.InvoiceStatistics.Remove(invoiceStatistic);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
 public ActionResult Edit([Bind(Include = "GenreId,TrackId,TotalTrackCharge,TimeCreated")] InvoiceStatistic invoiceStatistic)
 {
     if (ModelState.IsValid)
     {
         db.Entry(invoiceStatistic).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(invoiceStatistic));
 }
        public ActionResult Create([Bind(Include = "GenreId,TrackId,TotalTrackCharge,TimeCreated")] InvoiceStatistic invoiceStatistic)
        {
            if (ModelState.IsValid)
            {
                db.InvoiceStatistics.Add(invoiceStatistic);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(invoiceStatistic));
        }
        // GET: InvoiceStatistics/Delete/5
        public ActionResult Delete(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            InvoiceStatistic invoiceStatistic = db.InvoiceStatistics.Find(id);

            if (invoiceStatistic == null)
            {
                return(HttpNotFound());
            }
            return(View(invoiceStatistic));
        }