askbot-dragon 1.7.79-beta → 1.7.81-beta
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/components/previewPdf.vue +27 -26
package/package.json
CHANGED
|
@@ -283,35 +283,36 @@ export default {
|
|
|
283
283
|
},
|
|
284
284
|
computed: {
|
|
285
285
|
pdfStyle () {
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
286
|
+
return {
|
|
287
|
+
paddingTop: this.isPc ? '30px' : '0', // 30px 是 加上外层的 20 流出 50的上边距展示 放大缩小操作栏
|
|
288
|
+
paddingBottom: this.tagIds > 1 ? '60px' : '0',
|
|
289
|
+
height: '100%'
|
|
290
|
+
}
|
|
291
291
|
},
|
|
292
292
|
previewUrl () {
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
293
|
+
console.debug('VUE_APP_ENV', process.env.VUE_APP_ENV)
|
|
294
|
+
let url = process.env.VUE_APP_ENV === 'production' ? 'https://kkfileview.askbot.cn/onlinePreview?url=' : 'https://test.open.askbot.cn/kkfileview/onlinePreview?url='
|
|
295
|
+
// if(this.url != '') {
|
|
296
|
+
// if(/[\u4E00-\u9FA5]+/g.test(this.url)) {
|
|
297
|
+
// url += btoa(encodeURIComponent(this.url))
|
|
298
|
+
// } else {
|
|
299
|
+
// url += btoa(this.url)
|
|
300
|
+
// }
|
|
301
|
+
// }
|
|
302
|
+
url = url + this.url
|
|
303
|
+
if (this.sourceFileType == '.ppt' || this.sourceFileType == '.pptx' || this.sourceFileType == '.pdf') {
|
|
304
|
+
url += '&officePreviewType=pdf'
|
|
305
|
+
if (this.watermark) {
|
|
306
|
+
url = this.watermark.textWatermarkValue ? (url += '&textWatermarkValue=' + this.watermark.textWatermarkValue) : url
|
|
307
|
+
url = this.watermark.visitorWatermarkValue ? (url += '&visitorWatermarkValue=' + this.watermark.visitorWatermarkValue) : url
|
|
308
|
+
}
|
|
309
|
+
console.log('textWatermarkStr 216', this.textWatermarkStr)
|
|
310
|
+
if (this.textWatermarkStr) {
|
|
311
|
+
url += '&textWatermarkValue=' + this.textWatermarkStr
|
|
312
|
+
}
|
|
313
|
+
return url
|
|
312
314
|
}
|
|
313
|
-
|
|
314
|
-
},
|
|
315
|
+
}
|
|
315
316
|
// fileType() {
|
|
316
317
|
// const fileType = this.url.substring(this.url.lastIndexOf('.'));
|
|
317
318
|
// if (fileType === '.mp4' || fileType === '.MP4' || fileType === '.MOV' || fileType === '.mov') {
|