invoicePreview.vue
665 Bytes
<template>
<view>
<!--<image style="width: 100%" mode="scaleToFill" :src="src"-->
<!--@error="imageError"></image>-->
<web-view :src="invoiceUrl"></web-view>
</view>
</template>
<script>
export default {
data() {
return {
src: '',
invoiceUrl:'',
index:0,
};
},
onLoad(params) {
var pages = getCurrentPages();//当前页
var beforePage = pages[pages.length - 3];//上二个页面
console.log(beforePage.$vm.list)
console.log(params)
this.index = params.index
this.invoiceUrl = beforePage.$vm.list[this.index].invoiceUrl
console.log(this.invoiceUrl)
},
}
</script>
<style lang="scss">
</style>