重构:基础设施 -> 文件管理 接口文件调整

This commit is contained in:
dlarmor 2023-03-14 11:50:31 +08:00
parent fe2fa21d44
commit 1a7f89a8e2

View File

@ -87,7 +87,7 @@
</template> </template>
<script setup lang="ts" name="Config"> <script setup lang="ts" name="Config">
import { dateFormatter } from '@/utils/formatTime' import { dateFormatter } from '@/utils/formatTime'
import * as FileApi from '@/api/infra/fileList' import * as FileApi from '@/api/infra/file'
import FileUploadForm from './form.vue' import FileUploadForm from './form.vue'
const message = useMessage() // const message = useMessage() //
const { t } = useI18n() // const { t } = useI18n() //
@ -108,7 +108,7 @@ const queryFormRef = ref() // 搜索的表单
const getList = async () => { const getList = async () => {
loading.value = true loading.value = true
try { try {
const data = await FileApi.getFilePageApi(queryParams) const data = await FileApi.getFilePage(queryParams)
list.value = data.list list.value = data.list
total.value = data.total total.value = data.total
} finally { } finally {
@ -140,7 +140,7 @@ const handleDelete = async (id: number) => {
// //
await message.delConfirm() await message.delConfirm()
// //
await FileApi.deleteFileApi(id) await FileApi.deleteFile(id)
message.success(t('common.delSuccess')) message.success(t('common.delSuccess'))
// //
await getList() await getList()