This commit is contained in:
魏啾
2024-04-30 18:07:59 +08:00
parent b72c4d7af1
commit 56863dd624
1369 changed files with 156460 additions and 0 deletions

35
pages/webview/webview.vue Normal file
View File

@@ -0,0 +1,35 @@
<template>
<web-view :src="url"></web-view>
</template>
<script>
export default {
data() {
return {
url: '', //PDF路径
};
},
onLoad(options) {
console.log(options)
if (options.tape == 1) {
this.url = options.url;
} else {
uni.request({
url: uni.conf.baseUrl + 'szzpy/downloadurl',
data: {
//参数
id: options.id
},
method: 'POST', //请求方式,必须为大写
success: res => {
let fileUrl = options.url
this.url = 'http://www.pfile.com.cn/api/profile/onlinePreview?url=' +
encodeURIComponent(res.data.data);
}
});
}
}
};
</script>