belongsTo(User::class); } // Menghitung confidence dari model dan nilai sertifikat public function getFinalConfidenceAttribute() { $modelConfidence = 50; // dari model $sertifikatConfidence = 0; if (!is_null($this->certificate_score)) { // 40 poin setara dengan 50% confidence tambahan $sertifikatConfidence = ($this->certificate_score / 40) * 50; } return $modelConfidence + $sertifikatConfidence; // total maksimal: 100 } public function getCertificateUrlAttribute() { return $this->certificate_path ? asset('storage/' . $this->certificate_path) : null; } }