mirror of
https://gitee.com/mateos/mateclaw.git
synced 2026-09-13 03:13:41 +08:00
fix(wiki): type kbId/pageId props as number|string to prevent ID precision loss
This commit is contained in:
parent
0d94cb1f93
commit
c9f73bbbd5
@ -734,11 +734,11 @@ export const wikiApi = {
|
||||
getProcessingStatus: (kbId: number) => http.get(`/wiki/knowledge-bases/${kbId}/processing-status`),
|
||||
|
||||
// RFC-029: Relations
|
||||
getRelatedPages: (kbId: number, slug: string, topK = 5) =>
|
||||
getRelatedPages: (kbId: number | string, slug: string, topK = 5) =>
|
||||
http.get(`/wiki/kb/${kbId}/pages/${encodeURIComponent(slug)}/related`, { params: { topK } }),
|
||||
explainRelation: (kbId: number, slugA: string, slugB: string) =>
|
||||
http.get(`/wiki/kb/${kbId}/pages/${encodeURIComponent(slugA)}/relation/${encodeURIComponent(slugB)}`),
|
||||
getPageCitations: (kbId: number, pageId: number) =>
|
||||
getPageCitations: (kbId: number | string, pageId: number | string) =>
|
||||
http.get(`/wiki/kb/${kbId}/pages/${pageId}/citations`),
|
||||
|
||||
// RFC-030: Jobs
|
||||
|
||||
@ -36,8 +36,8 @@ const { t } = useI18n()
|
||||
|
||||
const props = defineProps<{
|
||||
modelValue: boolean
|
||||
pageId: number
|
||||
kbId: number
|
||||
pageId: number | string
|
||||
kbId: number | string
|
||||
}>()
|
||||
|
||||
defineEmits<{
|
||||
|
||||
@ -35,7 +35,7 @@ import { wikiApi } from '@/api/index'
|
||||
const { t } = useI18n()
|
||||
|
||||
const props = defineProps<{
|
||||
kbId: number
|
||||
kbId: number | string
|
||||
slug: string
|
||||
}>()
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user