管道基础大数据平台系统开发-【前端】-新系統界面
123
Surpriseplus
2022-11-12 e3a8cfa1f235815519d281a2f74590c432818a26
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<template>
  <div class="databaseMonitoring_box">
    <iframe
      id="iframe"
      :src="sql_Url"
      style="height: 100%"
      width="100%"
      frameborder="0"
    ></iframe>
  </div>
</template>
 
<script>
import MyBread from '../../components/MyBread.vue';
import { getToken } from '../../utils/auth.js';
export default {
  //import引入的组件需要注入到对象中才能使用
  components: {
    MyBread,
  },
  data() {
    //这里存放数据
    return {
      sql_Url: '',
    };
  },
  //方法集合
  methods: {
    handleSelectionChange() {},
    getUrl() {
      if (this.$store.state.iframeMsg.indexOf('token=') != -1) {
        this.sql_Url = this.$store.state.iframeMsg + getToken();
      } else {
        this.sql_Url = this.$store.state.iframeMsg;
      }
    },
  },
  created() {
    this.getUrl();
  },
  mounted() {},
};
</script>
<style lang="less" scoped>
//@import url(); 引入公共css类
.databaseMonitoring_box {
  border-radius: 10px;
  height: 81%;
  width: 97%;
  position: absolute;
  box-sizing: border-box;
}
</style>