[Base] 修改 API 接口使得支持 GET 请求参数
All checks were successful
Build / build-and-test (push) Successful in 28s
All checks were successful
Build / build-and-test (push) Successful in 28s
This commit is contained in:
@ -8,13 +8,13 @@ export const useApiStore = defineStore('api', () => {
|
||||
return await execute()
|
||||
}
|
||||
|
||||
async function postData(url, payload) {
|
||||
const { execute } = useApiRequest('POST', url, payload)
|
||||
async function workSimpleSearch(keyword, page = 1) {
|
||||
const { execute } = useApiRequest('GET', 'search/simple', { keyword, page })
|
||||
return await execute()
|
||||
}
|
||||
|
||||
return {
|
||||
getWork,
|
||||
postData,
|
||||
workSimpleSearch
|
||||
}
|
||||
})
|
||||
|
Reference in New Issue
Block a user