[HttpGet][Route("Urunler/FiyataGoreTop10")]public async Task<System.Web.Http.IHttpActionResult> FiyatTop10(){var s1 = await (from u in db.Productsselect new{u.ProductID,u.ProductName,u.UnitPrice}).OrderByDescending(p=>p.UnitPrice).Take(10).ToListAsync();if (s1 == null){return NotFound();}return Ok(s1);}
Yorumlar
Yorum Gönder