diff --git a/src/pages/processCenter/pages/creatProcess/bzdy/step1-1.vue b/src/pages/processCenter/pages/creatProcess/bzdy/step1-1.vue index 79dff1783..6b0cf9cb0 100644 --- a/src/pages/processCenter/pages/creatProcess/bzdy/step1-1.vue +++ b/src/pages/processCenter/pages/creatProcess/bzdy/step1-1.vue @@ -46,14 +46,14 @@ v-model="form.modelNameList" clearable > -
+
-
- {{ item.name }} +
+ {{ item.name }}
@@ -74,14 +74,14 @@ v-model="form.fjNameList" clearable > -
+
-
- {{ item.name }} +
+ {{ item.name }}
diff --git a/src/pages/processCenter/pages/creatProcess/bzdy/step1.vue b/src/pages/processCenter/pages/creatProcess/bzdy/step1.vue index ae1b8ef08..a759791e9 100644 --- a/src/pages/processCenter/pages/creatProcess/bzdy/step1.vue +++ b/src/pages/processCenter/pages/creatProcess/bzdy/step1.vue @@ -46,14 +46,14 @@ v-model="form.modelNameList" clearable > -
+
-
- {{ item.name }} +
+ {{ item.name }}
@@ -74,14 +74,14 @@ v-model="form.fjNameList" clearable > -
+
-
- {{ item.name }} +
+ {{ item.name }}
diff --git a/src/pages/processCenter/pages/creatProcess/bzdy/step2.vue b/src/pages/processCenter/pages/creatProcess/bzdy/step2.vue index 5535f6b24..c64557857 100644 --- a/src/pages/processCenter/pages/creatProcess/bzdy/step2.vue +++ b/src/pages/processCenter/pages/creatProcess/bzdy/step2.vue @@ -42,13 +42,13 @@ -
-
- {{ item.name }} +
+
+ {{ item.name }}
@@ -58,13 +58,13 @@
-
-
- {{ item.name }} +
+
+ {{ item.name }}
diff --git a/src/pages/processCenter/pages/creatProcess/bzdy/step3.vue b/src/pages/processCenter/pages/creatProcess/bzdy/step3.vue index 9991a3e2e..9fb360147 100644 --- a/src/pages/processCenter/pages/creatProcess/bzdy/step3.vue +++ b/src/pages/processCenter/pages/creatProcess/bzdy/step3.vue @@ -42,13 +42,13 @@ -
-
- {{ item.name }} +
+
+ {{ item.name }}
@@ -58,13 +58,13 @@
-
-
- {{ item.name }} +
+
+ {{ item.name }}
@@ -97,20 +97,18 @@
-
- - 点击上传 - -
+ + 点击上传 +
@@ -439,6 +437,7 @@ } }, fileUpload () { + this.fileMadel = true }, handleTabs(name) { diff --git a/src/pages/processCenter/pages/creatProcess/bzdy/step4.vue b/src/pages/processCenter/pages/creatProcess/bzdy/step4.vue index b2e23d503..d368c4532 100644 --- a/src/pages/processCenter/pages/creatProcess/bzdy/step4.vue +++ b/src/pages/processCenter/pages/creatProcess/bzdy/step4.vue @@ -42,13 +42,13 @@ -
-
- {{ item.name }} +
+
+ {{ item.name }}
@@ -58,13 +58,13 @@
-
-
- {{ item.name }} +
+
+ {{ item.name }}
@@ -95,14 +95,14 @@
-
+
{{ form.fileName }}
diff --git a/src/pages/processCenter/pages/creatProcess/bzdy/step5.vue b/src/pages/processCenter/pages/creatProcess/bzdy/step5.vue index 160df19ce..e3c3837a3 100644 --- a/src/pages/processCenter/pages/creatProcess/bzdy/step5.vue +++ b/src/pages/processCenter/pages/creatProcess/bzdy/step5.vue @@ -42,24 +42,26 @@ - -
- {{ form.hzfileName }} -
-
- - 点击上传 - +
+
+
+ {{ form.hzfileName }} +
+ +
+ + 点击上传 + @@ -97,9 +99,13 @@ label="回执文件" align="center"> @@ -227,7 +233,7 @@ import ProcessHeader from '../../components/ProcessHeader' import ProcessFooter from '../../components/ProcessFooter' import ProcessTitle from '../../components/ProcessTitle' - import {inboundLiaisonDetail,saveTaskForPub,changeAssigneeNew} from 'api/process' + import {inboundLiaisonDetail,saveTaskForPub,changeAssigneeNew,getBusStandFileByAttId} from 'api/process' import axios from "axios"; export default { @@ -266,6 +272,42 @@ ProcessTitle }, methods: { + getBusStandFileByAttId(attId) { + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + clickButtonToUpload2(file) { + const attId = file + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, handleTransfer() { this.drawerModal = true }, diff --git a/src/pages/processCenter/pages/creatProcess/bzdy/step6.vue b/src/pages/processCenter/pages/creatProcess/bzdy/step6.vue index 87da7b48f..fe18dfe5e 100644 --- a/src/pages/processCenter/pages/creatProcess/bzdy/step6.vue +++ b/src/pages/processCenter/pages/creatProcess/bzdy/step6.vue @@ -42,8 +42,14 @@ -
- {{ form.hzfileName }} +
+ {{ form.hzfileName }} +
- - @@ -92,8 +98,14 @@ label="文件" align="center"> @@ -217,7 +229,7 @@ import ProcessHeader from '../../components/ProcessHeader' import ProcessFooter from '../../components/ProcessFooter' import ProcessTitle from '../../components/ProcessTitle' - import {inboundLiaisonDetail,changeAssigneeNew} from 'api/process' + import {inboundLiaisonDetail,changeAssigneeNew,getBusStandFileByAttId} from 'api/process' import axios from "axios"; export default { @@ -257,6 +269,42 @@ ProcessTitle }, methods: { + getBusStandFileByAttId(attId) { + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + clickButtonToUpload2(file) { + const attId = file + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, handleTransfer() { this.drawerModal = true }, diff --git a/src/pages/processCenter/pages/creatProcess/bzdy/step7.vue b/src/pages/processCenter/pages/creatProcess/bzdy/step7.vue index e170af563..98aa6d46b 100644 --- a/src/pages/processCenter/pages/creatProcess/bzdy/step7.vue +++ b/src/pages/processCenter/pages/creatProcess/bzdy/step7.vue @@ -42,8 +42,14 @@ -
- {{ form.hzfileName }} +
+ {{ form.hzfileName }} +
- - @@ -92,8 +98,14 @@ label="文件" align="center"> @@ -217,7 +229,7 @@ import ProcessHeader from '../../components/ProcessHeader' import ProcessFooter from '../../components/ProcessFooter' import ProcessTitle from '../../components/ProcessTitle' - import {inboundLiaisonDetail,changeAssigneeNew} from 'api/process' + import {inboundLiaisonDetail,changeAssigneeNew,getBusStandFileByAttId} from 'api/process' import axios from "axios"; export default { @@ -257,6 +269,42 @@ ProcessTitle }, methods: { + getBusStandFileByAttId(attId) { + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + clickButtonToUpload2(file) { + const attId = file + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, handleTransfer() { this.drawerModal = true }, diff --git a/src/pages/processCenter/pages/creatProcess/bzdy/step8.vue b/src/pages/processCenter/pages/creatProcess/bzdy/step8.vue index 5024d3034..49b5f88d5 100644 --- a/src/pages/processCenter/pages/creatProcess/bzdy/step8.vue +++ b/src/pages/processCenter/pages/creatProcess/bzdy/step8.vue @@ -42,8 +42,14 @@ -
- {{ form.hzfileName }} +
+ {{ form.hzfileName }} +
- - @@ -92,8 +98,14 @@ label="文件" align="center"> @@ -217,7 +229,7 @@ import ProcessHeader from '../../components/ProcessHeader' import ProcessFooter from '../../components/ProcessFooter' import ProcessTitle from '../../components/ProcessTitle' - import {inboundLiaisonDetail,changeAssigneeNew} from 'api/process' + import {inboundLiaisonDetail,changeAssigneeNew,getBusStandFileByAttId} from 'api/process' import axios from "axios"; export default { @@ -257,6 +269,42 @@ ProcessTitle }, methods: { + getBusStandFileByAttId(attId) { + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + clickButtonToUpload2(file) { + const attId = file + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, handleTransfer() { this.drawerModal = true }, diff --git a/src/pages/processCenter/pages/creatProcess/bzdy/step9.vue b/src/pages/processCenter/pages/creatProcess/bzdy/step9.vue index aaaab8fb0..5b0432e08 100644 --- a/src/pages/processCenter/pages/creatProcess/bzdy/step9.vue +++ b/src/pages/processCenter/pages/creatProcess/bzdy/step9.vue @@ -42,8 +42,14 @@ -
- {{ form.hzfileName }} +
+ {{ form.hzfileName }} +
- - @@ -92,8 +98,14 @@ label="文件" align="center"> @@ -217,7 +229,7 @@ import ProcessHeader from '../../components/ProcessHeader' import ProcessFooter from '../../components/ProcessFooter' import ProcessTitle from '../../components/ProcessTitle' - import {inboundLiaisonDetail,changeAssigneeNew} from 'api/process' + import {inboundLiaisonDetail,changeAssigneeNew,getBusStandFileByAttId} from 'api/process' import axios from "axios"; export default { @@ -257,6 +269,42 @@ ProcessTitle }, methods: { + getBusStandFileByAttId(attId) { + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + clickButtonToUpload2(file) { + const attId = file + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, handleTransfer() { this.drawerModal = true }, diff --git a/src/pages/processCenter/pages/creatProcess/bzzqyj/step1-1.vue b/src/pages/processCenter/pages/creatProcess/bzzqyj/step1-1.vue index a9f2bbf5a..df47e84dc 100644 --- a/src/pages/processCenter/pages/creatProcess/bzzqyj/step1-1.vue +++ b/src/pages/processCenter/pages/creatProcess/bzzqyj/step1-1.vue @@ -47,12 +47,18 @@ 选择附件
-
- {{ item.fileName }} +
+ {{ item.fileName }} +
@@ -63,12 +69,18 @@ v-model="form.modelNameList" clearable > -
-
- {{ item.name }} +
+
+ {{ item.name }} +
-
+
{ + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + fileLook(file) { // 预览 + const attId = file.attId + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, beginImportFile (file) { var filename = file.name var index1 = filename.lastIndexOf('.') diff --git a/src/pages/processCenter/pages/creatProcess/bzzqyj/step1.vue b/src/pages/processCenter/pages/creatProcess/bzzqyj/step1.vue index d1ae55826..a7f8eb4a7 100644 --- a/src/pages/processCenter/pages/creatProcess/bzzqyj/step1.vue +++ b/src/pages/processCenter/pages/creatProcess/bzzqyj/step1.vue @@ -51,17 +51,17 @@ style="display: none;" >
-
- {{ item.fileName }} +
+ {{ item.fileName }} +
- - - - - - -
-
- {{ item.name }} +
+
+ {{ item.name }} +
-
+
{ + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + fileLook(file) { // 预览 + const attId = file.attId + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, beginImportFile (file) { var filename = file.name var index1 = filename.lastIndexOf('.') diff --git a/src/pages/processCenter/pages/creatProcess/bzzqyj/step2.vue b/src/pages/processCenter/pages/creatProcess/bzzqyj/step2.vue index 028661cc1..9394e1669 100644 --- a/src/pages/processCenter/pages/creatProcess/bzzqyj/step2.vue +++ b/src/pages/processCenter/pages/creatProcess/bzzqyj/step2.vue @@ -46,13 +46,30 @@ style="display: none;" >
-
{{ item.fileName }}
+
+ {{ item.fileName }} + +
-
-
- {{ item.name }} +
+
+ {{ item.name }} +
@@ -174,7 +191,7 @@ import ProcessHeader from "../../components/ProcessHeader"; import ProcessFooter from "../../components/ProcessFooter"; import ProcessTitle from "../../components/ProcessTitle"; -import { inboundLiaisonDetail, processCreateStand, saveTaskForPub, changeAssigneeNew} from "api/process"; +import { inboundLiaisonDetail, processCreateStand, saveTaskForPub, changeAssigneeNew,getBusStandFileByAttId} from "api/process"; import axios from "axios"; export default { @@ -221,6 +238,50 @@ export default { ProcessTitle }, methods: { + filesUpload (file) { // 下载 + const attId = file.attId + if (attId) { + window.location.href = '/api/att/attFile/downloadFileForSar?fileId=' + attId + } else { + this.$message.warning('文件不存在,下载失败') + } + }, + getBusStandFileByAttId(attId) { // 预览 + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + fileLook(file) { // 预览 + const attId = file.attId + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, handleTransfer() { this.drawerModal = true }, diff --git a/src/pages/processCenter/pages/creatProcess/bzzqyj/step3.vue b/src/pages/processCenter/pages/creatProcess/bzzqyj/step3.vue index e0062beed..9def032ea 100644 --- a/src/pages/processCenter/pages/creatProcess/bzzqyj/step3.vue +++ b/src/pages/processCenter/pages/creatProcess/bzzqyj/step3.vue @@ -46,16 +46,30 @@ style="display: none;" >
-
- {{ item.fileName }} - 下载 +
+ {{ item.fileName }} +
-
-
- {{ item.name }} +
+
+ {{ item.name }} +
@@ -318,7 +332,7 @@ import ProcessHeader from '../../components/ProcessHeader' import ProcessFooter from '../../components/ProcessFooter' import ProcessTitle from '../../components/ProcessTitle' - import {inboundLiaisonDetail, processCreateStand, saveTaskForPub,changeAssigneeNew,execTask} from 'api/process' + import {inboundLiaisonDetail, processCreateStand, saveTaskForPub,changeAssigneeNew,execTask,getBusStandFileByAttId} from 'api/process' import axios from "axios"; export default { @@ -386,6 +400,50 @@ ProcessTitle }, methods: { + filesUpload (file) { // 下载 + const attId = file.attId + if (attId) { + window.location.href = '/api/att/attFile/downloadFileForSar?fileId=' + attId + } else { + this.$message.warning('文件不存在,下载失败') + } + }, + getBusStandFileByAttId(attId) { // 预览 + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + fileLook(file) { // 预览 + const attId = file.attId + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, itermsConditionsClose () { this.itermsConditionsFlag = false }, diff --git a/src/pages/processCenter/pages/creatProcess/bzzqyj/step4-1.vue b/src/pages/processCenter/pages/creatProcess/bzzqyj/step4-1.vue index 7bbca524c..24ba96755 100644 --- a/src/pages/processCenter/pages/creatProcess/bzzqyj/step4-1.vue +++ b/src/pages/processCenter/pages/creatProcess/bzzqyj/step4-1.vue @@ -46,16 +46,30 @@ style="display: none;" >
-
- {{ item.fileName }} - 下载 +
+ {{ item.fileName }} +
-
-
- {{ item.name }} +
+
+ {{ item.name }} +
@@ -256,7 +270,7 @@ import ProcessHeader from '../../components/ProcessHeader' import ProcessFooter from '../../components/ProcessFooter' import ProcessTitle from '../../components/ProcessTitle' - import {inboundLiaisonDetail, processCreateStand,changeAssigneeNew} from 'api/process' + import {inboundLiaisonDetail, processCreateStand,changeAssigneeNew,getBusStandFileByAttId} from 'api/process' import axios from "axios"; export default { @@ -312,6 +326,50 @@ ProcessTitle }, methods: { + filesUpload (file) { // 下载 + const attId = file.attId + if (attId) { + window.location.href = '/api/att/attFile/downloadFileForSar?fileId=' + attId + } else { + this.$message.warning('文件不存在,下载失败') + } + }, + getBusStandFileByAttId(attId) { // 预览 + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + fileLook(file) { // 预览 + const attId = file.attId + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, checkedRole2(data) { this.form.bzfgId = data[0].id this.form.bzfgName = data[0].name diff --git a/src/pages/processCenter/pages/creatProcess/bzzqyj/step4-2.vue b/src/pages/processCenter/pages/creatProcess/bzzqyj/step4-2.vue index 7eaad4088..9bbcc251c 100644 --- a/src/pages/processCenter/pages/creatProcess/bzzqyj/step4-2.vue +++ b/src/pages/processCenter/pages/creatProcess/bzzqyj/step4-2.vue @@ -46,16 +46,30 @@ style="display: none;" >
-
- {{ item.fileName }} - 下载 +
+ {{ item.fileName }} +
-
-
- {{ item.name }} +
+
+ {{ item.name }} +
@@ -248,7 +262,7 @@ import ProcessHeader from '../../components/ProcessHeader' import ProcessFooter from '../../components/ProcessFooter' import ProcessTitle from '../../components/ProcessTitle' - import {inboundLiaisonDetail, processCreateStand,changeAssigneeNew} from 'api/process' + import {inboundLiaisonDetail, processCreateStand,changeAssigneeNew,getBusStandFileByAttId} from 'api/process' import axios from "axios"; export default { @@ -304,6 +318,50 @@ ProcessTitle }, methods: { + filesUpload (file) { // 下载 + const attId = file.attId + if (attId) { + window.location.href = '/api/att/attFile/downloadFileForSar?fileId=' + attId + } else { + this.$message.warning('文件不存在,下载失败') + } + }, + getBusStandFileByAttId(attId) { // 预览 + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + fileLook(file) { // 预览 + const attId = file.attId + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, checkedRole2(data) { this.form.bzfgId = data[0].id this.form.bzfgName = data[0].name diff --git a/src/pages/processCenter/pages/creatProcess/bzzqyj/step4.vue b/src/pages/processCenter/pages/creatProcess/bzzqyj/step4.vue index 0ccf0ae82..f6513b873 100644 --- a/src/pages/processCenter/pages/creatProcess/bzzqyj/step4.vue +++ b/src/pages/processCenter/pages/creatProcess/bzzqyj/step4.vue @@ -42,20 +42,34 @@
-
- {{ item.fileName }} - 下载 +
+ {{ item.fileName }} +
-
-
- {{ item.name }} +
+
+ {{ item.name }} +
@@ -328,7 +342,7 @@ import ProcessHeader from '../../components/ProcessHeader' import ProcessFooter from '../../components/ProcessFooter' import ProcessTitle from '../../components/ProcessTitle' -import {inboundLiaisonDetail, processCreateStand,changeAssigneeNew} from 'api/process' +import {inboundLiaisonDetail, processCreateStand,changeAssigneeNew,getBusStandFileByAttId} from 'api/process' import axios from "axios"; export default { @@ -396,6 +410,50 @@ export default { ProcessTitle }, methods: { + filesUpload (file) { // 下载 + const attId = file.attId + if (attId) { + window.location.href = '/api/att/attFile/downloadFileForSar?fileId=' + attId + } else { + this.$message.warning('文件不存在,下载失败') + } + }, + getBusStandFileByAttId(attId) { // 预览 + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + fileLook(file) { // 预览 + const attId = file.attId + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, handleSelectionChange(val) { this.idList = [] val.forEach(item => { diff --git a/src/pages/processCenter/pages/creatProcess/bzzqyj/step5.vue b/src/pages/processCenter/pages/creatProcess/bzzqyj/step5.vue index 7ad660242..dc18ccf8b 100644 --- a/src/pages/processCenter/pages/creatProcess/bzzqyj/step5.vue +++ b/src/pages/processCenter/pages/creatProcess/bzzqyj/step5.vue @@ -46,16 +46,30 @@ style="display: none;" >
-
- {{ item.fileName }} - 下载 +
+ {{ item.fileName }} +
-
-
- {{ item.name }} +
+
+ {{ item.name }} +
@@ -317,7 +331,7 @@ import ProcessHeader from "../../components/ProcessHeader"; import ProcessFooter from "../../components/ProcessFooter"; import ProcessTitle from "../../components/ProcessTitle"; - import { inboundLiaisonDetail, processCreateStand, saveTaskForPub, changeAssigneeNew } from "api/process"; + import { inboundLiaisonDetail, processCreateStand, saveTaskForPub, changeAssigneeNew,getBusStandFileByAttId } from "api/process"; import axios from "axios"; export default { @@ -382,6 +396,50 @@ ProcessTitle }, methods: { + filesUpload (file) { // 下载 + const attId = file.attId + if (attId) { + window.location.href = '/api/att/attFile/downloadFileForSar?fileId=' + attId + } else { + this.$message.warning('文件不存在,下载失败') + } + }, + getBusStandFileByAttId(attId) { // 预览 + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + fileLook(file) { // 预览 + const attId = file.attId + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, getItemList (standId, fileType) { // 查询分解单条款数据 this.$http.get('SarStandItems/sar-stand-items/querySarItemAndInterpretation', { standId: standId, diff --git a/src/pages/processCenter/pages/creatProcess/bzzqyj/step6.vue b/src/pages/processCenter/pages/creatProcess/bzzqyj/step6.vue index 884d04912..b89f1b7f6 100644 --- a/src/pages/processCenter/pages/creatProcess/bzzqyj/step6.vue +++ b/src/pages/processCenter/pages/creatProcess/bzzqyj/step6.vue @@ -42,20 +42,34 @@
-
- {{ item.fileName }} - 下载 +
+ {{ item.fileName }} +
-
-
- {{ item.name }} +
+
+ {{ item.name }} +
@@ -262,7 +276,7 @@ import ProcessHeader from "../../components/ProcessHeader"; import ProcessFooter from "../../components/ProcessFooter"; import ProcessTitle from "../../components/ProcessTitle"; -import { inboundLiaisonDetail, processCreateStand, changeAssigneeNew } from "api/process"; +import { inboundLiaisonDetail, processCreateStand, changeAssigneeNew,getBusStandFileByAttId } from "api/process"; import axios from "axios"; export default { @@ -320,6 +334,50 @@ export default { ProcessTitle }, methods: { + filesUpload (file) { // 下载 + const attId = file.attId + if (attId) { + window.location.href = '/api/att/attFile/downloadFileForSar?fileId=' + attId + } else { + this.$message.warning('文件不存在,下载失败') + } + }, + getBusStandFileByAttId(attId) { // 预览 + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + fileLook(file) { // 预览 + const attId = file.attId + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, itermsConditionsClose () { this.itermsConditionsFlag = false }, @@ -382,8 +440,6 @@ export default { } }, upload(row, title) { - console.log(row); - return var params = { columnName: { chapterNumber: "章条编号", @@ -394,10 +450,12 @@ export default { reason: "修改理由", department: "提出部门", responUserName: "提出人", - stateText: "处理意见" }, dataList: [] }; + if (title === '上报意见.xls') { + params.columnName.stateText = "处理意见" + } params.dataList = JSON.parse(JSON.stringify(row)); params.dataList.forEach(item => { if (item.state === "1") { diff --git a/src/pages/processCenter/pages/creatProcess/bzzqyj/step7.vue b/src/pages/processCenter/pages/creatProcess/bzzqyj/step7.vue index 3fe206cb5..4d0bb709f 100644 --- a/src/pages/processCenter/pages/creatProcess/bzzqyj/step7.vue +++ b/src/pages/processCenter/pages/creatProcess/bzzqyj/step7.vue @@ -42,20 +42,34 @@
-
- {{ item.fileName }} - 下载 +
+ {{ item.fileName }} +
-
-
- {{ item.name }} +
+
+ {{ item.name }} +
@@ -262,7 +276,7 @@ import ProcessHeader from '../../components/ProcessHeader' import ProcessFooter from '../../components/ProcessFooter' import ProcessTitle from '../../components/ProcessTitle' -import {inboundLiaisonDetail, processCreateStand,changeAssigneeNew} from 'api/process' +import {inboundLiaisonDetail, processCreateStand,changeAssigneeNew,getBusStandFileByAttId} from 'api/process' import axios from "axios"; export default { @@ -317,6 +331,50 @@ export default { ProcessTitle }, methods: { + filesUpload (file) { // 下载 + const attId = file.attId + if (attId) { + window.location.href = '/api/att/attFile/downloadFileForSar?fileId=' + attId + } else { + this.$message.warning('文件不存在,下载失败') + } + }, + getBusStandFileByAttId(attId) { // 预览 + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + fileLook(file) { // 预览 + const attId = file.attId + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, itermsConditionsClose () { this.itermsConditionsFlag = false }, @@ -382,10 +440,12 @@ export default { reason: "修改理由", department: "提出部门", responUserName: "提出人", - stateText: "处理意见" }, dataList: [] } + if (title === '上报意见.xls') { + params.columnName.stateText = "处理意见" + } params.dataList = JSON.parse(JSON.stringify(row)) params.dataList.forEach(item => { if (item.state === '1') { diff --git a/src/pages/processCenter/pages/creatProcess/bzzqyj/step8.vue b/src/pages/processCenter/pages/creatProcess/bzzqyj/step8.vue index b3d4a40f9..d8ebf13aa 100644 --- a/src/pages/processCenter/pages/creatProcess/bzzqyj/step8.vue +++ b/src/pages/processCenter/pages/creatProcess/bzzqyj/step8.vue @@ -42,20 +42,34 @@
-
- {{ item.fileName }} - 下载 +
+ {{ item.fileName }} +
-
-
- {{ item.name }} +
+
+ {{ item.name }} +
@@ -262,7 +276,7 @@ import ProcessHeader from '../../components/ProcessHeader' import ProcessFooter from '../../components/ProcessFooter' import ProcessTitle from '../../components/ProcessTitle' -import {inboundLiaisonDetail, processCreateStand,changeAssigneeNew} from 'api/process' +import {inboundLiaisonDetail, processCreateStand,changeAssigneeNew,getBusStandFileByAttId} from 'api/process' import axios from "axios"; export default { @@ -317,6 +331,50 @@ export default { ProcessTitle }, methods: { + filesUpload (file) { // 下载 + const attId = file.attId + if (attId) { + window.location.href = '/api/att/attFile/downloadFileForSar?fileId=' + attId + } else { + this.$message.warning('文件不存在,下载失败') + } + }, + getBusStandFileByAttId(attId) { // 预览 + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + fileLook(file) { // 预览 + const attId = file.attId + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, itermsConditionsClose () { this.itermsConditionsFlag = false }, @@ -382,10 +440,12 @@ export default { reason: "修改理由", department: "提出部门", responUserName: "提出人", - stateText: "处理意见" }, dataList: [] } + if (title === '上报意见.xls') { + params.columnName.stateText = "处理意见" + } params.dataList = JSON.parse(JSON.stringify(row)) params.dataList.forEach(item => { if (item.state === '1') { diff --git a/src/pages/processCenter/pages/creatProcess/bzzqyj/step9.vue b/src/pages/processCenter/pages/creatProcess/bzzqyj/step9.vue index 6055e3d72..188fd08a2 100644 --- a/src/pages/processCenter/pages/creatProcess/bzzqyj/step9.vue +++ b/src/pages/processCenter/pages/creatProcess/bzzqyj/step9.vue @@ -42,20 +42,34 @@
-
- {{ item.fileName }} - 下载 +
+ {{ item.fileName }} +
-
-
- {{ item.name }} +
+
+ {{ item.name }} +
@@ -262,7 +276,7 @@ import ProcessHeader from "../../components/ProcessHeader"; import ProcessFooter from "../../components/ProcessFooter"; import ProcessTitle from "../../components/ProcessTitle"; -import { inboundLiaisonDetail, processCreateStand, changeAssigneeNew } from "api/process"; +import { inboundLiaisonDetail, processCreateStand, changeAssigneeNew,getBusStandFileByAttId } from "api/process"; import axios from "axios"; export default { @@ -317,6 +331,50 @@ export default { ProcessTitle }, methods: { + filesUpload (file) { // 下载 + const attId = file.attId + if (attId) { + window.location.href = '/api/att/attFile/downloadFileForSar?fileId=' + attId + } else { + this.$message.warning('文件不存在,下载失败') + } + }, + getBusStandFileByAttId(attId) { // 预览 + return new Promise((resolve, reject) => { + getBusStandFileByAttId({ + attId + }).then(res => { + if (res.ok) { + resolve(res.data) + } else { + reject() + } + }).catch(e => { + reject(e) + }) + }) + }, + fileLook(file) { // 预览 + const attId = file.attId + this.getBusStandFileByAttId(attId) + .then(res => { + if(res){ + const editFileInfo = res + if(editFileInfo.fileSuffix === 'pdg' || editFileInfo.fileSuffix === 'PDG'){ + window.open('book://ssreader/e0?url='+editFileInfo.downLoadUrl) + }else if(editFileInfo.fileSuffix === 'pdf' || editFileInfo.fileSuffix === 'PDF'){ + window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + }else { + const nowTime = new Date().getTime() + // window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(editFileInfo.downLoadUrl))); + window.open('/static/onlyOffice/onlinePreview.html?oldFileName=' + editFileInfo.oldFileName + '&fileType=' + editFileInfo.fileSuffix + '&attId=' + editFileInfo.id + '&fileUrl=' + editFileInfo.downLoadUrl + '&key=' + editFileInfo.id + nowTime+'&filePath='+editFileInfo.filePath+'&fileName='+editFileInfo.fileName) + } + // window.open('/static/pdf/web/viewer.html?file=' + encodeURIComponent('/api/att/attFile/getFileInfo?fileId=' + editFileInfo.id)) + } + }).catch(e => { + this.$message.warning('文件不存在,预览失败') + }) + }, itermsConditionsClose () { this.itermsConditionsFlag = false }, @@ -382,10 +440,12 @@ export default { reason: "修改理由", department: "提出部门", responUserName: "提出人", - stateText: "处理意见" }, dataList: [] }; + if (title === '上报意见.xls') { + params.columnName.stateText = "处理意见" + } params.dataList = JSON.parse(JSON.stringify(row)); params.dataList.forEach(item => { if (item.state === "1") { diff --git a/src/pages/regulatoryRepository/standardForComments/pags/consultationDetails.vue b/src/pages/regulatoryRepository/standardForComments/pags/consultationDetails.vue index 7e8329ead..55900ad98 100644 --- a/src/pages/regulatoryRepository/standardForComments/pags/consultationDetails.vue +++ b/src/pages/regulatoryRepository/standardForComments/pags/consultationDetails.vue @@ -41,6 +41,22 @@
-
+
+ +
+
+
+ {{ file.name }} + 下载 +
+
+
+ - +

{{ this.$route.query.item.startTime || '-' }} @@ -95,6 +111,7 @@ prop="oldText" align="center" label="修改前" + width="150" >