|
|
@@ -108,7 +108,12 @@ export default {
|
|
|
window.open('https://view.officeapps.live.com/op/view.aspx?src=' + file.url, '_blank');
|
|
|
},
|
|
|
previewPdf(file) {
|
|
|
- window.open(this.$baseUrl + '/pdf/web/viewer.html?file=' + file.url, '_blank');
|
|
|
+ console.log(this.$baseUrl.substr(-1));
|
|
|
+ if (this.$baseUrl.substr(-1) == '/') {
|
|
|
+ window.open(this.$baseUrl + 'pdf/web/viewer.html?file=' + file.url, '_blank');
|
|
|
+ } else {
|
|
|
+ window.open(this.$baseUrl + '/pdf/web/viewer.html?file=' + file.url, '_blank');
|
|
|
+ }
|
|
|
},
|
|
|
isImage(file) {
|
|
|
return /\.(jpg|jpeg|png|gif|bmp|webp)$/i.test(file.url);
|