Implement all car endpoints

This commit is contained in:
2024-08-17 16:38:40 +02:00
parent a708ed25e7
commit 877e7989cd
22 changed files with 688 additions and 46 deletions

View File

@@ -0,0 +1,19 @@
using Microsoft.EntityFrameworkCore;
using Vegasco.WebApi.Cars;
using Vegasco.WebApi.Common;
using Vegasco.WebApi.Users;
namespace Vegasco.WebApi.Persistence;
public class ApplicationDbContext(DbContextOptions<ApplicationDbContext> options) : DbContext(options)
{
public DbSet<Car> Cars { get; set; }
public DbSet<User> Users { get; set; }
protected override void OnModelCreating(ModelBuilder modelBuilder)
{
base.OnModelCreating(modelBuilder);
modelBuilder.ApplyConfigurationsFromAssembly(typeof(IWebApiMarker).Assembly);
}
}