'Field Nation', 'WorkMarket' => 'WorkMarket', 'Other' => 'Other', ]; public const SOURCE_TYPES = [ 'profile_pdf' => 'Profile PDF', 'screenshot' => 'Screenshot', 'csv_export' => 'CSV export', 'json_export' => 'JSON export', 'html_export' => 'HTML copy/export', 'plain_text' => 'Plain text paste/export', 'email_export' => 'Email or message export', 'other' => 'Other source', ]; public const PARSE_STATUSES = [ 'pending' => 'Pending parser', 'parsed' => 'Parsed', 'failed' => 'Parse failed', 'not_parseable' => 'Stored as proof only', ]; public const REVIEW_STATUSES = [ 'needs_review' => 'Needs provider review', 'provider_reviewed' => 'Provider reviewed', 'admin_reviewed' => 'Admin reviewed', 'approved_for_summary' => 'Approved for public summary', 'rejected_for_public' => 'Rejected for public display', ]; protected function casts(): array { return [ 'parsed_payload' => 'array', 'parse_warnings' => 'array', 'uploaded_at' => 'datetime', ]; } public function providerProfile(): BelongsTo { return $this->belongsTo(ProviderProfile::class); } public function externalProfileImport(): BelongsTo { return $this->belongsTo(ExternalProfileImport::class); } public function uploadedBy(): BelongsTo { return $this->belongsTo(User::class, 'uploaded_by_id'); } public function sourceTypeLabel(): string { return self::SOURCE_TYPES[$this->source_type] ?? $this->source_type; } public function parseStatusLabel(): string { return self::PARSE_STATUSES[$this->parse_status] ?? $this->parse_status; } public function reviewStatusLabel(): string { return self::REVIEW_STATUSES[$this->review_status] ?? $this->review_status; } }