fix: Tauri commands camelCase + PeopleView perPage

This commit is contained in:
2026-06-14 19:02:15 +08:00
parent 2d7e65da6f
commit 620736a170
2 changed files with 19 additions and 19 deletions

View File

@@ -146,7 +146,7 @@ const filteredPeople = computed(() => {
onMounted(async () => {
debugMsg.value = 'PeopleView mounted! Loading...'
try {
const result: any = await invoke('get_people', { page: 1, per_page: 1000 })
const result: any = await invoke('get_people', { page: 1, perPage: 1000 })
debugMsg.value = `get_people: ${Array.isArray(result)} length=${result?.length ?? 'N/A'}`
people.value = Array.isArray(result) ? result : []
} catch (e: any) {
@@ -185,8 +185,8 @@ async function selectPerson(p: any) {
selectedProfile.value = profiles.value[p.identity_uuid] || ''
activeTab.value = 'faces'
try {
const fResult: any = await invoke('get_faces', { uuid: p.identity_uuid, per_page: 100 })
const tResult: any = await invoke('get_traces', { uuid: p.identity_uuid, per_page: 100 })
const fResult: any = await invoke('get_faces', { uuid: p.identity_uuid, perPage: 100 })
const tResult: any = await invoke('get_traces', { uuid: p.identity_uuid, perPage: 100 })
faces.value = Array.isArray(fResult) ? fResult : []
traces.value = Array.isArray(tResult) ? tResult : []
} catch (e) { console.error('Failed to load details:', e) }
@@ -215,7 +215,7 @@ async function confirmDelete() {
async function loadCandidates() {
try {
const result: any = await invoke('get_face_candidates', { page: 1, per_page: 50 })
const result: any = await invoke('get_face_candidates', { page: 1, perPage: 50 })
candidates.value = Array.isArray(result) ? result : []
} catch (e) { console.error('Failed to load candidates:', e) }
}