Exemplo n.º 1
0
        public ActionResult Supprimer(int id)
        {
            BlocageServiceAPI rsa = new BlocageServiceAPI();
            BlocageDetails    r   = new BlocageDetails(rsa.Donner(id));

            return(View(r));
        }
Exemplo n.º 2
0
        public ActionResult Details(int id)
        {
            BlocageServiceAPI rsa = new BlocageServiceAPI();
            Blocage           r   = rsa.Donner(id);
            BlocageDetails    rd  = new BlocageDetails(r);

            return(View(rd));
        }
Exemplo n.º 3
0
 public static Blocage VersBlocage(this BlocageDetails e)
 {
     if (e == null)
     {
         return(null);
     }
     return(new Blocage {
         id = e.id, actif = e.actif, description = e.description, nom = e.nom
     });
 }
Exemplo n.º 4
0
 public ActionResult Supprimer(int id, BlocageDetails r)
 {
     if (ModelState.IsValid)
     {
         BlocageServiceAPI rsa = new BlocageServiceAPI();
         bool b = rsa.Supprimer(id);
         if (b)
         {
             return(RedirectToAction("Index"));
         }
     }
     return(View(r));
 }