0
0
MyDarling/Controllers/HomeController.cs

19 lines
429 B
C#
Raw Normal View History

2023-01-31 14:54:32 +03:00
using Microsoft.AspNetCore.Mvc;
2023-02-01 09:30:01 +03:00
using Microsoft.EntityFrameworkCore;
using MyDarling.Models;
2023-01-31 14:54:32 +03:00
namespace MyDarling.Controllers
{
public class HomeController : Controller
{
2023-02-01 09:30:01 +03:00
private DataContext context;
public HomeController(DataContext context)
{
this.context = context;
}
2023-01-31 14:54:32 +03:00
public IActionResult Index()
{
2023-02-01 09:30:01 +03:00
return View(context.UnderwearBundles.Include(bundle => bundle.Figures).Where(x => x.Price != 0));
2023-01-31 14:54:32 +03:00
}
}
}