123456789101112131415161718192021222324252627282930313233 |
- <template>
- <view>
- <web-view :src="url" @message="onMessage"></web-view>
- </view>
- </template>
- <script>
- import config from "@/config";
- export default {
- data() {
- return {
- url: ''
- }
- },
- onLoad(body) {
- uni.$on('reloadElement', () => {
- this.url = config.baseUrl + '/webview/document/editor.html?token=' + uni.getStorageSync('token') +
- '&id=' + body.id + '&contractId=' + body.contractId + '&time=' + new Date().getTime() +
- '&userId=' + this.$store.getters.user.userId;
- })
- this.url = config.baseUrl + '/webview/document/editor.html?token=' + uni.getStorageSync('token') +
- '&id=' + body.id + '&contractId=' + body.contractId + '&time=' + new Date().getTime() + '&userId=' + this
- .$store.getters.user.userId;
- },
- methods: {
- onMessage(data) {}
- }
- }
- </script>
- <style>
- </style>
|