Exemplo n.º 1
0
        public async Task <IActionResult> Delete()
        {
            if (!string.IsNullOrEmpty(RouteData.Values["id"].ToString()))
            {
                var id     = int.Parse(RouteData.Values["id"].ToString());
                var @class = new DAL.Class
                {
                    CLASSID = id
                };
                await _class.DeleteClass(@class);

                await AddLog(id + " numaralı sınıf silindi.");
            }
            return(RedirectToAction("Index"));
        }
Exemplo n.º 2
0
 public void Delete(SchoolCheckIn.CheckIn.Model.Class classModel)
 {
     PetaPoco.Database db = new PetaPoco.Database("DatabaseConn");
     db.BeginTransaction();
     try
     {
         _classService.Class(db);
         _classService.DeleteClass(classModel);
         db.CompleteTransaction();
     }
     catch (Exception e)
     {
         db.AbortTransaction();
         throw e;
     }
 }
Exemplo n.º 3
0
 public void Delete(int id)
 {
     objClass.DeleteClass(id);
 }