示例#1
0
 public ActionResult Edit(int?Id)
 {
     if (!Id.HasValue)
     {
         return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
     }
     return(View(repository.Find(Id.Value)));
 }
示例#2
0
        public IActionResult DeletePartner(long id)
        {
            Partner partner = partner_repo.Find(id);

            if (partner == null)
            {
                return(NotFound());
            }

            partner_repo.Delete(partner);
            return(Ok());
        }