| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596 |
- <template>
- <el-container>
- <el-main>
- <el-col
- v-for="(more, index) in moreList"
- :key="index"
- :md="6"
- :sm="12"
- :xs="12"
- style="padding: 5px;"
- >
- <el-card class="box-card">
- <div slot="header" class="clearfix">
- <el-row>
- <el-col :md="4">
- <router-link target="_blank" :to="more.link">
- <el-avatar>
- <el-image :src="more.coverUrl" />
- </el-avatar>
- </router-link>
- </el-col>
- <el-col :md="16">
- <el-row style="padding: 5px;">
- <span v-html="more.title" />
- </el-row>
- <el-row style="padding: 5px;">
- <span v-html="more.desc" />
- </el-row>
- </el-col>
- </el-row>
- </div>
- </el-card>
- </el-col>
- </el-main>
- </el-container>
- </template>
- <script>
- export default {
- name: 'Index',
- data() {
- return {
- moreList: []
- }
- },
- watch: {
- // 地址栏 url 发生变化时重新加载本页面
- $route() {
- this.$router.go()
- }
- },
- created() {
- document.title = 'tfapp'
- this.getData()
- },
- methods: {
- getData() {
- this.moreList.push(
- {
- title: 'vod',
- desc: '地图',
- link: '/vod',
- coverUrl: ''
- },
- {
- title: 'blog',
- desc: '地图',
- link: '/blog',
- coverUrl: ''
- },
- {
- title: 'disk',
- desc: '考试',
- link: '/disk',
- coverUrl: ''
- },
- {
- title: 'devops',
- desc: '商城',
- link: '/devops',
- coverUrl: ''
- },
- {
- title: 'bg',
- desc: '图表',
- link: '/background',
- coverUrl: ''
- }
- )
- }
- }
- }
- </script>
- <style>
- </style>
|