Tiago Yamamoto
d3c06f5564
feat: expand testing, add fast seeder options, hardcode superadmin
...
- start.sh: Add options 8 (Seed LITE - skip cities) and 9 (Run All Tests)
- seeder: Add seed:lite, seed:fast scripts and --skip-locations flag
- seeder: Remove superadmin creation (now via backend migration)
- backend: Update 010_seed_super_admin.sql with hardcoded hash (Admin@2025! + pepper)
- backend: Expand jwt_service_test.go with 5 new tests (+10% coverage)
- frontend: Fix api.test.ts URL duplication bug, add error handling tests
- seeder: Add SQL data files to .gitignore
2025-12-24 17:07:45 -03:00
Tiago Yamamoto
052f5169c5
test(auth): add comprehensive auth tests with 98.6% coverage
...
Backend Tests Added:
- auth_middleware_test.go: 25+ tests for HeaderAuthGuard, OptionalHeaderAuthGuard, RequireRoles, TenantGuard, ExtractRoles, hasRole (100% coverage)
- cors_middleware_test.go: 7 tests for CORS origin validation (100% coverage)
- jwt_service_test.go: expanded with expiration parsing, wrong signing method tests (94.4% coverage)
Features:
- Maximum console.log/fmt.Printf output for debugging
- Tests for JWT from header and cookie fallback
- Tests for role-based access (case-insensitive)
- Tests for tenant enforcement
- Tests for token expiration parsing (7d, 2h, invalid formats)
Total backend auth coverage: 98.6%
2025-12-24 16:20:56 -03:00
Tiago Yamamoto
c1078563df
refactor(roles): rename companyAdmin->admin and jobSeeker->candidate
2025-12-24 13:30:50 -03:00
Tiago Yamamoto
1b4f1d1555
refactor: migrate core tables to UUID v7 and update roadmap
2025-12-24 12:30:49 -03:00
Tiago Yamamoto
38a94bcbce
feat: implement high priority features
...
1. Advanced Search (backend)
- Add salaryMin, salaryMax, currency, sortBy to JobFilterQuery
- Add 5+ filters: visa, salary range, currency, language level
- Add 4 sort options: recent, salary_asc, salary_desc, relevance
2. Email Service (backend)
- Create Resend API integration (email_service.go)
- 3 HTML email templates: welcome, password_reset, application_received
- Add RESEND_API_KEY, EMAIL_FROM, APP_URL env vars
3. i18n (frontend)
- Create 4 language files: pt-BR, en-US, es-ES, ja-JP
- 100+ translation keys per language
- Covers: common, nav, auth, jobs, profile, company, footer
4. Stripe Integration (backend)
- Create payment_handler.go with checkout session creation
- Webhook handler with signature verification
- Support for checkout.session.completed, payment_intent events
2025-12-24 11:40:53 -03:00
Tiago Yamamoto
7d99e77468
refactor: unify schema - eliminate core_* tables
...
BREAKING CHANGE: Removed core_companies, core_users, core_user_roles tables
Migrations:
- Create 020_unify_schema.sql: adds tenant_id, email, name to users table
- Create user_roles table (replaces core_user_roles)
- Disable 009_create_core_tables.sql (renamed to .disabled)
- Update 010_seed_super_admin.sql to use unified tables
Backend Repositories:
- company_repository.go: use companies table with INT id
- user_repository.go: use users/user_roles with INT id conversion
Seeders:
- All seeders now use companies/users/user_roles tables
- Removed all core_* table insertions
- Query companies by slug to get SERIAL id
This eliminates the redundancy between core_* and legacy tables.
2025-12-24 11:06:31 -03:00
Tiago Yamamoto
340911b4d1
feat(auth): add cookie parsing and JWT auth guard to backoffice
...
- Add JWT auth guard with Bearer token and cookie support
- Update .env.example files with PASSWORD_PEPPER documentation
- Update seeder to use PASSWORD_PEPPER for password hashing
- Update seeder README with hash verification examples
- Fix frontend auth and page components
- Update backend JWT service and seed migration
2025-12-24 10:27:04 -03:00
Tiago Yamamoto
02f35b46b6
feat: implement dynamic dashboard, auth hardening (pepper/httponly) and backend tests
2025-12-24 01:30:33 -03:00
Tiago Yamamoto
743b2842c0
feat: Enhance platform with funny jobs, FAQ, Skeleton UI, and Tests
2025-12-22 23:48:56 -03:00
Tiago Yamamoto
9c17a7a15a
Add paginated users listing
2025-12-22 16:43:54 -03:00
Tiago Yamamoto
fdd67b8cd6
Merge branch 'hml' into dev
2025-12-11 14:59:40 -03:00
Tiago Yamamoto
ce6e35aefd
feat(backend): implement S3 object storage with pre-signed URLs
...
- Add s3_storage.go service using AWS SDK v2
- Support custom S3-compatible endpoints (Civo)
- Implement pre-signed URL generation for uploads/downloads
- Add storage_handler.go with REST endpoints
- Register protected storage routes in router
- Graceful degradation when S3 not configured
2025-12-11 14:41:25 -03:00
Tiago Yamamoto
a505726786
fix: refactor dashboard urls, fix layout duplication and resolve backend api errors
2025-12-09 20:29:49 -03:00
Tiago Yamamoto
1c7ef95c1a
first commit
2025-12-09 19:04:48 -03:00