文件查看方式

lvtianfang
吕天方 1 year ago
parent 47acb23fe8
commit 069fe29d04

@ -3,7 +3,7 @@
* @Author: kery.chen
* @Description: 总体概览左侧
* @Date: 2021-11-30 11:08:50
* @LastEditTime: 2023-10-25 14:51:49
* @LastEditTime: 2023-10-31 16:34:08
* @FilePath : \\tcingiocpro\\src\\views\\privateOrder\\ecosphere\\components\\componentLeft.vue
-->
<template>
@ -1151,15 +1151,15 @@ export default {
this.fileExtension = row["材料路径"].substring(
row["材料路径"].lastIndexOf(".") + 1
);
let newarr = row["材料路径"].split("/");
let lastArr = newarr.slice(newarr.indexOf("demo") + 1, newarr.length);
// let newarr = row[""].split("/");
// let lastArr = newarr.slice(newarr.indexOf("demo") + 1, newarr.length);
// console.log(row[''],'process.env.VUE_APP_BASE_API2')
if (this.fileExtension == "pdf") {
// this.pdfUrl = row[''];
// this.dialogDetails = true;
// console.log(this.pdfUrl,'this.pdfUrl')
// this.getNumPages(process.env.VUE_APP_BASE_API2 + row[""]);
this.getNumPages("/demo" + "/" + lastArr.join("/"));
this.getNumPages(row["材料路径"]);
// this.getNumPages("/demo" + "/" + lastArr.join("/"));
} else if (
this.fileExtension === "docx" ||
this.fileExtension === "doc"
@ -1293,7 +1293,7 @@ export default {
// console.log(this.fileExtension,'this.fileExtension')
if (this.fileExtension == "pdf") {
// this.pdfUrl = row[''];
this.getNumPages(process.env.VUE_APP_BASE_API2 + res.rows[0].fileUrl);
this.getNumPages(res.rows[0].fileUrl);
this.dialogDetails = true
} else if (
this.fileExtension === "docx" ||
@ -1302,7 +1302,7 @@ export default {
axios({
method: "get",
responseType: "blob", //
url: process.env.VUE_APP_BASE_API2 + res.rows[0].fileUrl,
url: res.rows[0].fileUrl,
}).then(({ data }) => {
if (data) {
this.$nextTick(() => {

@ -1,8 +1,8 @@
<!--
* @Author: lough11
* @Date: 2021-12-24 13:17:50
* @LastEditors: lough
* @LastEditTime: 2022-11-15 22:38:43
* @LastEditors: JC9527
* @LastEditTime: 2023-10-31 16:33:12
* @Description:
-->
<template>
@ -469,7 +469,7 @@ export default {
flex-wrap: wrap;
margin-top: 20px;
justify-content: space-between;
align-content: start;
align-content: flex-start;
.smallIcon {
margin-top: 28px;
height: 61px;

Loading…
Cancel
Save