|
@@ -1188,12 +1188,12 @@ const batchUploadSaveApi = async (rows) => {
|
|
|
}
|
|
|
|
|
|
//确认上传保存
|
|
|
-const archiveFileBatchUpdate = async (rows) => {
|
|
|
+const archiveFileBatchUpdate = async (rows, type) => {
|
|
|
uploadSaveLoading.value = true
|
|
|
- const { error, code } = await tuningApi.archiveFileBatchUpdate({
|
|
|
- list: rows,
|
|
|
- }, false)
|
|
|
- //判断状态
|
|
|
+ const apiMethod = type === 2 ? tuningApi.batchUpdateInfo : tuningApi.archiveFileBatchUpdate
|
|
|
+
|
|
|
+ const { error, code } = await apiMethod({ list: rows }, false)
|
|
|
+
|
|
|
uploadSaveLoading.value = false
|
|
|
if (!error && code === 200) {
|
|
|
window.$message?.success('保存成功')
|
|
@@ -1226,7 +1226,7 @@ const batchUploadSave = async () => {
|
|
|
element.endDate = dates ? dates[1] : null
|
|
|
element.autoFileSort = index + 1
|
|
|
})
|
|
|
- await archiveFileBatchUpdate(rows)
|
|
|
+ await archiveFileBatchUpdate(rows, editType.value)
|
|
|
} else {
|
|
|
await batchUploadSaveApi(rows)
|
|
|
}
|