@@ -155,14 +155,19 @@ builder.Services.AddScoped<IExpenseService, ExpenseService>();
|
||||
builder.Services.AddScoped<IMonthlyStatementService, MonthlyStatementService>();
|
||||
builder.Services.AddScoped<IFinanceDashboardService, FinanceDashboardService>();
|
||||
builder.Services.AddScoped<IChurchProfileService, ChurchProfileService>();
|
||||
builder.Services.AddScoped<ISettingsService, SettingsService>();
|
||||
builder.Services.AddScoped<IDisbursementService, DisbursementService>();
|
||||
builder.Services.AddScoped<ROLAC.API.Services.Disbursement.ICheckPrintService,
|
||||
ROLAC.API.Services.Disbursement.CheckPrintService>();
|
||||
builder.Services.AddScoped<IMealAttendanceService, MealAttendanceService>();
|
||||
|
||||
// ── Notifications (email via SMTP + Line) ──────────────────────────────────
|
||||
// IOptions binding stays only as the one-time seed/fallback; the runtime source of truth is the
|
||||
// DB-backed NotificationSetting row, read (and hot-reloaded) via INotificationSettingsService.
|
||||
builder.Services.Configure<ROLAC.API.Services.Notifications.SmtpOptions>(config.GetSection("Smtp"));
|
||||
builder.Services.Configure<ROLAC.API.Services.Notifications.LineOptions>(config.GetSection("Line"));
|
||||
builder.Services.AddSingleton<ROLAC.API.Services.Notifications.INotificationSettingsService,
|
||||
ROLAC.API.Services.Notifications.NotificationSettingsService>();
|
||||
builder.Services.AddScoped<ROLAC.API.Services.Notifications.ISmtpDispatcher,
|
||||
ROLAC.API.Services.Notifications.MailKitSmtpDispatcher>();
|
||||
builder.Services.AddScoped<ROLAC.API.Services.Notifications.IEmailService,
|
||||
|
||||
Reference in New Issue
Block a user