feat(packs): PackDrawTable aggregate + IPackDrawTableRepository
Aggregate (Config + SlotRates + CardWeights) and a single-pack getter loaded as one unit per /pack/open. PackOpenService consumes the aggregate; tests use the production seed (fixture overlay) to validate shape. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -74,6 +74,7 @@ public class Program
|
||||
builder.Services.AddTransient<IPuzzleCatalogRepository, PuzzleCatalogRepository>();
|
||||
builder.Services.AddTransient<IDeckRepository, DeckRepository>();
|
||||
builder.Services.AddTransient<IPackRepository, PackRepository>();
|
||||
builder.Services.AddScoped<SVSim.Database.Repositories.PackDrawTables.IPackDrawTableRepository, SVSim.Database.Repositories.PackDrawTables.PackDrawTableRepository>();
|
||||
builder.Services.AddTransient<IBuildDeckRepository, BuildDeckRepository>();
|
||||
// Scoped (not Singleton) to avoid the singleton-depends-on-scoped-DbContext lifecycle
|
||||
// pitfall. Cost: one indexed single-row query per section per request — trivial. No
|
||||
|
||||
Reference in New Issue
Block a user