update 导入校验修改
This commit is contained in:
@@ -239,29 +239,29 @@ export const ConfigurableTableMixin = {
|
||||
importModalLoading && importModalLoading.destroy()
|
||||
this.loading = false
|
||||
if (info.file.response.success) {
|
||||
// this.$message.success(`${info.file.name} 文件上传成功`);
|
||||
if (info.file.response.code === 201) {
|
||||
const { message, result: { msg, fileUrl, fileName } } = info.file.response
|
||||
const href = window._CONFIG.domianURL + fileUrl
|
||||
this.$warning({
|
||||
title: message,
|
||||
content: (
|
||||
<div>
|
||||
<span>{msg}</span><br />
|
||||
<span>具体详情请 <a href={href} target="_blank" download={fileName}>点击下载</a> </span>
|
||||
</div>
|
||||
)
|
||||
})
|
||||
} else {
|
||||
this.$message.success(info.file.response.message || `${info.file.name} 文件上传成功`)
|
||||
}
|
||||
this.loadData()
|
||||
} else {
|
||||
if (Array.isArray(info.file.response.result) && info.file.response.result.length > 0) {
|
||||
this.messageLineFeed(this.$t('fileImportError'), info.file.response.result)
|
||||
} else {
|
||||
// this.$message.success(`${info.file.name} 文件上传成功`);
|
||||
if (info.file.response.code === 201) {
|
||||
const { message, result: { msg, fileUrl, fileName } } = info.file.response
|
||||
const href = window._CONFIG.domianURL + fileUrl
|
||||
this.$warning({
|
||||
title: message,
|
||||
content: (
|
||||
<div>
|
||||
<span>{msg}</span><br />
|
||||
<span>具体详情请 <a href={href} target="_blank" download={fileName}>点击下载</a> </span>
|
||||
</div>
|
||||
)
|
||||
})
|
||||
} else {
|
||||
this.$message.success(info.file.response.message || `${info.file.name} 文件上传成功`)
|
||||
}
|
||||
this.loadData()
|
||||
this.$message.error(`${info.file.name} ${info.file.response.message}.`)
|
||||
}
|
||||
} else {
|
||||
this.$message.error(`${info.file.name} ${info.file.response.message}.`)
|
||||
}
|
||||
} else if (info.file.status === 'error') {
|
||||
// 销毁这个提示
|
||||
|
||||
Reference in New Issue
Block a user