fix: use update:modelvalue instead of using watch

This commit is contained in:
KerollesFathy
2025-12-16 21:05:04 +00:00
parent 49bc5750a1
commit cfbac5f2c4
2 changed files with 3 additions and 6 deletions

View File

@@ -33,7 +33,7 @@
v-model="currentCategory"
:options="categories.data"
:placeholder="__('Category')"
@change="updateParticipants()"
@update:modelValue="updateParticipants()"
/>
</div>
</div>
@@ -111,7 +111,7 @@ import {
Select,
usePageMeta,
} from 'frappe-ui'
import { computed, inject, onMounted, ref, watch } from 'vue'
import { computed, inject, onMounted, ref } from 'vue'
import { GraduationCap } from 'lucide-vue-next'
import { sessionStore } from '../stores/session'
import EmptyState from '@/components/EmptyState.vue'
@@ -220,10 +220,6 @@ usePageMeta(() => {
icon: brand.favicon,
}
})
watch(currentCategory, (val) => {
updateParticipants()
})
</script>
<style>
.headline {

View File

@@ -451,6 +451,7 @@ def get_certification_categories():
category = doc.course_title if doc.course_title else doc.batch_title
if not category or category in seen:
continue
seen.add(category)
categories.append({"label": category, "value": category})
return categories