Commit 2e310b6d authored by 郭志伟's avatar 郭志伟 Committed by 郝聪敏

fix: 电子保单优化

parent 80b60ac8
......@@ -6,6 +6,7 @@
<script>
import pdf from "vue-pdf";
import { mapActions } from "vuex";
export default {
name: "PolicyVirtualDetail",
components: {
......@@ -22,8 +23,10 @@ export default {
this.setDetail();
},
methods: {
...mapActions(["setIsLoading"]),
setDetail() {
const { url } = this.$route.query;
this.setIsLoading(true);
if (!url) this.$router.back();
this.url = url;
this.pdfTask();
......@@ -33,6 +36,7 @@ export default {
this.pdfUrl.promise
.then(pdf => {
this.pdfNumPages = pdf.numPages;
this.setIsLoading(false);
})
.catch(err => {
console.error(err);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment