mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-27 00:52:50 +00:00
- Introduced a new step in the onboarding process to select company nationality (Ethiopian or Foreign). - Updated API and service layers to handle nationality data for companies. - Added support for uploading multiple business license files for each operational profile. - Refactored company and forwarder forms to include new license upload step. - Created a reusable RoleLicenseStep component for managing license file uploads. - Implemented utility functions for phone number handling. - Added migrations to update the database schema for nationality and business license files.
24 lines
747 B
TypeScript
24 lines
747 B
TypeScript
import { AppDataSource } from "../data-source";
|
|
import { FileUploadSettingsSeeder } from "../seed/file-upload-settings.seeder";
|
|
|
|
/**
|
|
* Idempotently (re)seed the company onboarding file-upload settings, including
|
|
* the nationality-based document sets (ethiopian / foreign). Run on demand:
|
|
* pnpm --filter @edr/freight-api seed:file-upload-settings
|
|
*/
|
|
async function run() {
|
|
await AppDataSource.initialize();
|
|
try {
|
|
const seeder = new FileUploadSettingsSeeder(AppDataSource);
|
|
await seeder.run();
|
|
console.log("Seeded company onboarding file-upload settings.");
|
|
} finally {
|
|
await AppDataSource.destroy();
|
|
}
|
|
}
|
|
|
|
run().catch((error) => {
|
|
console.error("Failed to seed file-upload settings:", error);
|
|
process.exit(1);
|
|
});
|