🔍 Problem Statement
📖 Description
Design a robust PostgreSQL schema to support core entities of the freelance platform. The schema should cover users, projects, milestones, contracts, and disputes, with indexing strategies for efficient queries.
Expected Behavior
- Users: Store freelancer and client profiles with wallet addresses, authentication details, and role distinctions.
- Projects: Represent client-created projects with metadata (title, description, budget, deadlines).
- Milestones: Track project milestones with title, description, amount, due date, and status.
- Contracts: Link freelancers to projects, including terms, escrow details, and status.
- Disputes: Record disputes raised by clients or freelancers, with reason, evidence, and resolution status.
🛠 Technical Notes
✅ Acceptance Criteria
- Schema includes tables for users, projects, milestones, contracts, and disputes.
- Relationships are correctly defined with foreign keys.
- Indexes are applied to critical query paths (wallet, project, milestone, contract).
- Schema passes migration tests and integrates with backend APIs.
npm run lint and npm run build succeed.
- No regression in authentication, wallet connection, or dashboard features.
📈 Expected Impact
High — Would significantly improve user experience
🔍 Problem Statement
📖 Description
Design a robust PostgreSQL schema to support core entities of the freelance platform. The schema should cover users, projects, milestones, contracts, and disputes, with indexing strategies for efficient queries.
Expected Behavior
🛠 Technical Notes
Schema Design:
created_at,updated_at) for auditing.Indexing Strategy:
Scalability Considerations:
✅ Acceptance Criteria
npm run lintandnpm run buildsucceed.📈 Expected Impact
High — Would significantly improve user experience