feat(10-02): register TendersModule with marketplace self-seed + singleton poll config
- tenders.seed.ts seeds slug 'tender-radar' (isSystem: true, category 'procurement') - tenders.module.ts self-seeds registry on boot (mirrors DkvModule pattern) - upserts singleton doe-opendata TenderSourcePollConfig row (global, no forTenant()) - TendersModule added to app.module.ts imports
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
import { ModuleRegistryService } from '../module-registry/module-registry.service';
|
||||
|
||||
/**
|
||||
* Seeds the tender-radar module into the module registry.
|
||||
*
|
||||
* Called during TendersModule initialization to ensure the
|
||||
* "tender-radar" module record exists in the database (CONFIG-01).
|
||||
*
|
||||
* isSystem: true registers the module in the registry but does NOT
|
||||
* auto-activate it per tenant. Admin must activate via Marketplace UI.
|
||||
*/
|
||||
export async function seedTendersModule(
|
||||
moduleRegistryService: ModuleRegistryService,
|
||||
): Promise<void> {
|
||||
await moduleRegistryService.seedModule({
|
||||
slug: 'tender-radar',
|
||||
name: 'Ausschreibungs-Radar',
|
||||
version: '1.0.0',
|
||||
category: 'procurement',
|
||||
description: {
|
||||
de: 'Deutsche Ausschreibungen automatisch erfassen und durchsuchen',
|
||||
en: 'Automatically track and search German public tenders',
|
||||
},
|
||||
isSystem: true,
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user