'integer', // Cast the 'telepon' attribute to integer 'agama' => 'integer', // Cast the 'agama' attribute to integer ]; public function user() { return $this->hasMany(User::class, 'id', 'user_id'); } }