app.vue 626 B

123456789101112131415161718192021222324252627
  1. <template>
  2. <div style="height: 100vh">
  3. <yx-navbar :isBack="true" :title="title"></yx-navbar>
  4. <iframe class="iframe" v-if="url" :src="url" frameborder="0"></iframe>
  5. </div>
  6. </template>
  7. <script>
  8. import Cookies from 'js-cookie'
  9. import {setToken} from "@/util";
  10. export default {
  11. data() {
  12. return {
  13. title: '详情',
  14. url: '',
  15. }
  16. },
  17. onLoad(options) {
  18. this.title = options.title
  19. setToken().then(() => {
  20. let token = Cookies.get('congress')
  21. this.url = `${window._CONFIG.APP_READY}?path=miniapp&appid=${options.id}&token=${token}#/newbi/auth`
  22. })
  23. }
  24. }
  25. </script>
  26. <style>
  27. </style>