using DigitalData.TaskFlow.Infrastructure.Persistence.Models; using Microsoft.EntityFrameworkCore; namespace DigitalData.TaskFlow.Infrastructure.Persistence; /// /// EF Core DbContext for TaskFlow infrastructure data access. /// public sealed class TaskFlowDbContext(DbContextOptions options) : DbContext(options) { /// /// Gets the keyless result model used for workflow listing procedure reads. /// public DbSet WorkflowListingReadModels => Set(); protected override void OnModelCreating(ModelBuilder modelBuilder) { base.OnModelCreating(modelBuilder); modelBuilder.Entity(entity => { entity.HasNoKey(); entity.ToView(null); }); } }