fix: update gender search logic in StudentsTable to use enum values for improved consistency

This commit is contained in:
Yoga Pangestu 2026-04-02 11:58:50 +07:00
parent aa3bb2ec76
commit 10d90a0297

View File

@ -67,11 +67,11 @@ public static function configure(Table $table): Table
$search = strtolower($search);
if (str_contains('laki-laki', $search)) {
$query->orWhere('sex', 'male');
$query->orWhere('sex', Sex::Male);
}
if (str_contains('perempuan', $search)) {
$query->orWhere('sex', 'female');
$query->orWhere('sex', Sex::Female);
}
}),