This commit is contained in:
Suphonchai Phoonsawat 2026-08-19 12:15:20 +07:00
parent 9321f5a370
commit 25c2ce53cd
23 changed files with 1746 additions and 68 deletions

View file

@ -35,10 +35,12 @@ builder.Services.AddSwaggerGen(options =>
builder.Services.AddDbContext<AppDbContext>(options =>
options.UseNpgsql(builder.Configuration.GetConnectionString("Default")));
// MinIO / hash / current user
// MinIO / hash / docx generation / field sync / current user
builder.Services.Configure<MinioOptions>(builder.Configuration.GetSection(MinioOptions.SectionName));
builder.Services.AddSingleton<IObjectStorageService, ObjectStorageService>();
builder.Services.AddSingleton<IHashService, HashService>();
builder.Services.AddSingleton<IDocxGenerationService, DocxGenerationService>();
builder.Services.AddScoped<IFieldSyncService, FieldSyncService>();
builder.Services.AddHttpContextAccessor();
builder.Services.AddScoped<ICurrentUser, CurrentUser>();