You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
<template> <view class="pageBgImg "> <topNavbar title="我的合同"></topNavbar> <view class="pad"> <view class="card"> <image :src="pdfUrl" mode="widthFix"></image> <!-- <web-view :src="pdfUrl"></web-view> --> <!-- <mumu-previewOffce :fileUrl='pdfUrl' v-model='showPreview' @change="change"></mumu-previewOffce> --> </view> </view> </view> </template>
<script> import { selectContractPdfBase64 } from '@/config/api.js' import MumuPreviewOffce from '@/uni_modules/mumu-previewOffce/components/mumu-previewOffce/mumu-previewOffce.vue' export default { components: { MumuPreviewOffce }, data() { return { pdfUrl: '' } }, onLoad() { this.selectContractPdfBase64Fn() const obj = '123' console.log(this.getType(window))
}, methods: { async selectContractPdfBase64Fn() { const {data: res} = await selectContractPdfBase64({studentId: this.studentId}) this.pdfUrl = res console.log('this.pdfUrl') console.log(this.pdfUrl) }, change() { console.log('你关你关') }, getType(obj){ let type = typeof obj; if (type !== "object") { // typeof
return type; } // typeof object
return Object.prototype.toString.call(obj).replace(/^\[object (\S+)\]$/, '$1'); } } } </script>
<style lang="scss" scoped> .card { padding: 8rpx; margin-bottom: 40rpx; } </style>
|