作者 雷海东
... ... @@ -187,7 +187,7 @@
@pagination="getList"
/>
<el-dialog title="合同预览" :visible.sync="dialogVisibleContract" width="50%" center :before-close="handleClose">
<vue-pdf :src="pdfUrl" type="application/pdf" width="100%" height="800px" />
<embed :src="pdfUrl" type="application/pdf" width="100%" height="800px" />
</el-dialog>
<!-- 添加或修改合规审查对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
... ...
... ... @@ -267,10 +267,10 @@ export default {
// 假设后端返回的数据结构中有一个字段 url 表示文件地址
const fileUrl = response.data.fileNames;
// 将文件地址或文件名赋值给表单的字段
this.form.templatefile =fileUrl;
this.form.attachments =fileUrl;
},
handleRemove(file, fileList) {
this.form.templatefile=''
this.form.attachments=''
console.log(file, fileList);
},
handlePreview(file) {
... ... @@ -295,7 +295,6 @@ export default {
// console.log(this.formData)
if (valid) {
console.log("===", this.form);
this.form.attachments = this.fileList[0].name;
// return
addAndStart(this.form).then((response) => {
this.$modal.msgSuccess("流程启动成功");
... ...
... ... @@ -101,7 +101,8 @@
@pagination="getList"
/>
<el-dialog title="合同预览" :visible.sync="dialogVisibleContract" width="50%" center :before-close="handleClose" >
<pdf :src="pdfUrl" type="application/pdf" width="100%" height="800px" v-if="pdfUrl" />
<embed :src="pdfUrl" type="application/pdf" width="100%" height="800px" v-if="pdfUrl"
/>
</el-dialog>
<!-- 添加或修改【请填写功能名称】对话框 -->
<el-dialog :title="title" :visible.sync="open" width="700px" append-to-body>
... ... @@ -193,6 +194,8 @@ export default {
},
data() {
return {
currentPage: 0, // 页码
pageCount: 0, // 总页数
headers: {
Authorization: "Bearer " + getToken(),
},
... ... @@ -321,6 +324,15 @@ export default {
this.getList();
},
methods: {
setNumPages(numPages) {
this.numPages = numPages;
for (let i = 1; i <= numPages; i++) {
this.pages.push(i);
}
},
onPageLoaded(page) {
console.log(`Page ${page} loaded`);
},
handleUploadSealContract(row){
this.contractnoTemp = row.contractno
... ...
... ... @@ -402,8 +402,8 @@ export default {
this.$refs["elForm"].validate((valid) => {
// console.log(this.formData)
if (valid) {
console.log("===", this.formData);
this.formData.attachments = this.fileList[0].name;
console.log("===", this.formData);
// return
addAndStart(this.formData).then((response) => {
this.$modal.msgSuccess("流程启动成功");
... ...
... ... @@ -85,7 +85,7 @@
/>
<!-- 合同预览 -->
<el-dialog title="合同预览" :visible.sync="dialogVisibleContract" width="50%" center :before-close="handleClose" >
<pdf :src="pdfUrl" type="application/pdf" width="100%" height="800px" v-if="pdfUrl" />
<embed :src="pdfUrl" type="application/pdf" width="100%" height="800px" v-if="pdfUrl" />
</el-dialog>
<!-- 合同变更 -->
<el-dialog :title="title" :visible.sync="open" width="700px" append-to-body>
... ...
... ... @@ -157,7 +157,7 @@
/>
<el-dialog :visible.sync="dialogVisible" title="合同预览" width="50%">
<vue-pdf :src="currentFile" />
<embed :src="currentFile" />
<span slot="footer" class="dialog-footer">
<el-button @click="dialogVisible = false">关闭</el-button>
</span>
... ...
... ... @@ -119,7 +119,7 @@
center
:before-close="handleClose"
>
<vue-pdf
<embed
:src="pdfUrl"
type="application/pdf"
width="100%"
... ...