|
|
@ -41,11 +41,9 @@ import Annex from '@/components/Annex/src/Annex.vue' |
|
|
|
import Remarks from '@/components/Remarks/src/Remarks.vue' |
|
|
|
import ChangeRecord from '@/components/ChangeRecord/src/ChangeRecord.vue' |
|
|
|
import Tabs from '@/components/Tabs/src/Tabs.vue' |
|
|
|
import * as DetailApi from '@/api/wms/detail' |
|
|
|
import * as RemarkApi from '@/api/wms/remark' |
|
|
|
import * as FileApi from '@/api/wms/file' |
|
|
|
|
|
|
|
const message = useMessage() // 消息弹窗 |
|
|
|
const { t } = useI18n() // 国际化 |
|
|
|
|
|
|
|
|
|
|
|
defineOptions({ name: 'Detail' }) |
|
|
@ -114,26 +112,7 @@ const remarksData = reactive({ |
|
|
|
|
|
|
|
// 变更记录默认数据 |
|
|
|
const changeRecordData = reactive({ |
|
|
|
changeRecordList: [{ |
|
|
|
name: '诸葛亮', |
|
|
|
type: 1, |
|
|
|
time: '2023年5月6日 17:16:00', |
|
|
|
}, { |
|
|
|
name: '刘备', |
|
|
|
type: 2, |
|
|
|
time: '2023年5月6日 17:16:00', |
|
|
|
}, { |
|
|
|
name: '曹操', |
|
|
|
type: 3, |
|
|
|
time: '2023年5月6日 17:16:00', |
|
|
|
file: [{ |
|
|
|
name: '这是个附件的名字.docx', |
|
|
|
url: 'http://localhost:12080/admin-api/system/user/get-import-template' |
|
|
|
}, { |
|
|
|
name: '这是个附件的名字.docx', |
|
|
|
url: 'http://localhost:12080/admin-api/system/user/get-import-template' |
|
|
|
}] |
|
|
|
}] |
|
|
|
changeRecordList: [] |
|
|
|
}) |
|
|
|
const detailData = ref("")//详情数据 |
|
|
|
// 获取附件列表篇 |
|
|
@ -152,17 +131,10 @@ const handleAnnexSuccess = () => { |
|
|
|
|
|
|
|
} |
|
|
|
// 删除附件成功之后所走的方法 |
|
|
|
const deleteAnnexSuccess = async (id) => { |
|
|
|
console.log('删除成功'); |
|
|
|
try { |
|
|
|
// 删除的二次确认 |
|
|
|
await message.delConfirm() |
|
|
|
// 发起删除 |
|
|
|
await FileApi.deleteFile(id) |
|
|
|
message.success(t('common.delSuccess')) |
|
|
|
getFileList() |
|
|
|
getChangeRecordList() |
|
|
|
} catch { } |
|
|
|
const deleteAnnexSuccess = async () => { |
|
|
|
|
|
|
|
getFileList() |
|
|
|
getChangeRecordList() |
|
|
|
} |
|
|
|
|
|
|
|
// Tabs当前选择 |
|
|
@ -204,7 +176,7 @@ defineExpose({ openDetail }) // 提供 open 方法,用于打开弹窗 |
|
|
|
const getRemarkList = async () => { |
|
|
|
detailLoading.value = true |
|
|
|
try { |
|
|
|
remarksData.remarksList = await DetailApi.getRemarkPage(remarksData.data) |
|
|
|
remarksData.remarksList = await RemarkApi.getRemarkPage(remarksData.data) |
|
|
|
} finally { |
|
|
|
detailLoading.value = false |
|
|
|
} |
|
|
@ -218,7 +190,7 @@ const remarksSubmitScuess = async (remark) => { |
|
|
|
// 获取变更记录 |
|
|
|
const getChangeRecordList = async () => { |
|
|
|
// remarksData.data.tableId = '1679654720693248010' |
|
|
|
changeRecordData.changeRecordList = await DetailApi.getChangeRecordPage(remarksData.data) |
|
|
|
changeRecordData.changeRecordList = await RemarkApi.getChangeRecordPage(remarksData.data) |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|