feat: 7月迭代
All checks were successful
构建并部署前端到测试环境 / build-and-deploy (push) Successful in 4m21s

This commit is contained in:
luo
2026-07-28 14:00:22 +08:00
parent f0a2b84e53
commit 2706c52a47
63 changed files with 4113 additions and 3945 deletions

View File

@@ -85,13 +85,22 @@
}
)
const getNormalizedQuery = () => {
const query: Record<string, unknown> = {}
const getNormalizedQuery = (): Record<string, string> => {
const query: Record<string, string> = {}
Object.entries(props.query || {}).forEach(([key, value]) => {
if (value === undefined || value === null || value === '') return
if (Array.isArray(value) && value.length === 0) return
query[key] = value
if (typeof value === 'string') {
query[key] = value
} else if (typeof value === 'number' || typeof value === 'boolean') {
query[key] = String(value)
} else if (Array.isArray(value)) {
query[key] = value.join(',')
} else {
query[key] = JSON.stringify(value)
}
})
return query