feat:库存列表导出文件名增加灵枢或众妙
This commit is contained in:
@@ -241,6 +241,7 @@ export default {
|
|||||||
'content': content
|
'content': content
|
||||||
})
|
})
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
|
if (data && data.code === 0) {
|
||||||
this.$message({
|
this.$message({
|
||||||
message: '成功',
|
message: '成功',
|
||||||
type: 'success'
|
type: 'success'
|
||||||
@@ -252,6 +253,12 @@ export default {
|
|||||||
attr.push(voices)
|
attr.push(voices)
|
||||||
this.fileListVoices = attr
|
this.fileListVoices = attr
|
||||||
console.log(res)
|
console.log(res)
|
||||||
|
} else {
|
||||||
|
this.$message.error(res.msg)
|
||||||
|
}
|
||||||
|
}).catch(() => {
|
||||||
|
this.loading = false
|
||||||
|
this.$message.error('请求失败')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 富文本内容赋值
|
// 富文本内容赋值
|
||||||
|
|||||||
@@ -199,7 +199,9 @@ export default {
|
|||||||
})
|
})
|
||||||
const link = document.createElement('a')
|
const link = document.createElement('a')
|
||||||
link.href = window.URL.createObjectURL(blob)
|
link.href = window.URL.createObjectURL(blob)
|
||||||
link.download = this.bizType === 1 ? '入库记录.xlsx' : '出库记录.xlsx'
|
const merchantPrefix = this.merchantId === '2' ? '众妙' : '灵枢'
|
||||||
|
const recordName = this.bizType === 1 ? '入库记录' : '出库记录'
|
||||||
|
link.download = `${merchantPrefix}${recordName}.xlsx`
|
||||||
link.click()
|
link.click()
|
||||||
window.URL.revokeObjectURL(link.href)
|
window.URL.revokeObjectURL(link.href)
|
||||||
this.$message.success('导出成功')
|
this.$message.success('导出成功')
|
||||||
|
|||||||
@@ -208,7 +208,8 @@ export default {
|
|||||||
})
|
})
|
||||||
const link = document.createElement('a')
|
const link = document.createElement('a')
|
||||||
link.href = window.URL.createObjectURL(blob)
|
link.href = window.URL.createObjectURL(blob)
|
||||||
link.download = '库存统计.xlsx'
|
const merchantPrefix = this.merchantId === '2' ? '众妙' : '灵枢'
|
||||||
|
link.download = `${merchantPrefix}库存统计.xlsx`
|
||||||
link.click()
|
link.click()
|
||||||
window.URL.revokeObjectURL(link.href)
|
window.URL.revokeObjectURL(link.href)
|
||||||
this.$message.success('导出成功')
|
this.$message.success('导出成功')
|
||||||
|
|||||||
Reference in New Issue
Block a user