提交 12c49d97 authored 作者: lihuihui's avatar lihuihui

修改提示

上级 baaad94d
......@@ -4,7 +4,7 @@
<el-select @change="changes" v-model="value" size="small" clearable>
<el-option v-for="item in options" :key="item.id" :label="item.english_name" :value="item.id"> </el-option>
</el-select>
<div class="down-btn" @click="$refs.html2Pdf.generatePdf()">{{ $t('shmsLang.downloadBtn') }}</div>
<div class="down-btn" @click="downPdf">{{ $t('shmsLang.downloadBtn') }}</div>
</div>
<template v-if="imgUrl">
<vue-html2pdf
......@@ -119,6 +119,16 @@ export default {
window.open(this.pdfUrl)
}
},
downPdf() {
if (this.pdfUrl) {
this.$refs.html2Pdf.generatePdf()
} else {
this.$message({
message: 'No certificate, unable to download',
type: 'warning'
})
}
},
changes() {
this.imgUrl = ''
this.pdfUrl = ''
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论