Skip to content

feat: Setup database modules and migrations#3

Open
ayo-ola0710 wants to merge 1 commit into
XtreemSpark:mainfrom
ayo-ola0710:Database_initailization
Open

feat: Setup database modules and migrations#3
ayo-ola0710 wants to merge 1 commit into
XtreemSpark:mainfrom
ayo-ola0710:Database_initailization

Conversation

@ayo-ola0710

Copy link
Copy Markdown

What was done

Optimized tool selectionI added a PostgreSQL + TypeORM foundation: installed typeorm, pg, @nestjs/typeorm, class-validator, and class-transformer; created TypeORM config and DataSource in src/database/database.config.ts and src/database/data.source.ts; added a DatabaseModule (src/database/database.module.ts) and wired it into src/app.module.ts; implemented seven entities (User, NGO, Donation, Volunteer, Task, TaskSubmission, Reward) under src/entities/ with relations and timestamps; created an initial migration migrations/1720569600000-CreateInitialSchema.ts; added a .env.example and a DATABASE_SETUP.md with setup/migration instructions; and updated package.json with migration scripts so you can run npm run migration:run to apply the schema.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant