示例#1
0
 /// <summary>
 /// Obtiens un role selon son id.
 /// </summary>
 /// <param name="id"></param>
 /// <returns></returns>
 public RoleDTO Get_By_ID(int id)
 {
     try
     {
         using (CarRentalEntities context = new CarRentalEntities())
         {
             return(roleMapping.MapToRoleDTO(context.usp_Role_Get_By_ID(id).FirstOrDefault()));
         }
     }
     catch (Exception)
     {
         throw;
     }
 }