【fix ESLint】src/views/modules/oss/OSSFileList.vue
This commit is contained in:
@@ -129,7 +129,7 @@ export default {
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
beforeUpload (file) {
|
beforeUpload (file) {
|
||||||
var fileType = file.type
|
const fileType = file.type
|
||||||
if (fileType === 'image') {
|
if (fileType === 'image') {
|
||||||
if (fileType.indexOf('image') < 0) {
|
if (fileType.indexOf('image') < 0) {
|
||||||
this.$message.warning('请上传图片')
|
this.$message.warning('请上传图片')
|
||||||
@@ -157,7 +157,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
ossDelete (id) {
|
ossDelete (id) {
|
||||||
var that = this
|
const that = this
|
||||||
that.$confirm({
|
that.$confirm({
|
||||||
title: '确认删除',
|
title: '确认删除',
|
||||||
content: '是否删除选中文件?',
|
content: '是否删除选中文件?',
|
||||||
@@ -168,7 +168,7 @@ export default {
|
|||||||
},
|
},
|
||||||
handlePreview (record) {
|
handlePreview (record) {
|
||||||
if (record && record.url) {
|
if (record && record.url) {
|
||||||
var fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${record.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${record.fileName}`
|
const fileFullUrl = `${window._CONFIG.domianWebSocketURL}/sys/common/download/${record.id}?token=${Vue.ls.get(ACCESS_TOKEN)}&fullfilename=${record.fileName}`
|
||||||
const url = `${window._CONFIG.onlinePreviewDomainURL}?url=${encodeURIComponent(Base64.encode(fileFullUrl))}`
|
const url = `${window._CONFIG.onlinePreviewDomainURL}?url=${encodeURIComponent(Base64.encode(fileFullUrl))}`
|
||||||
window.open(url)
|
window.open(url)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user