链接管理
This commit is contained in:
@@ -5,6 +5,9 @@
|
||||
<li v-for="(link, index) in linkList" :key="index">
|
||||
<a @click="openLinkUrl(link.newWebSite)" v-html="link.webName"></a>
|
||||
</li>
|
||||
<li>
|
||||
<router-link to="/linkManage">更多链接></router-link>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</template>
|
||||
@@ -41,16 +44,18 @@ export default {
|
||||
newWebSite: 'http://www.mee.gov.cn/',
|
||||
webName: '中华人民共和国生态环境部'
|
||||
},
|
||||
{
|
||||
newWebSite: '',
|
||||
webName: '更多链接>'
|
||||
}
|
||||
// {
|
||||
// newWebSite: '',
|
||||
// webName: '更多链接>'
|
||||
// }
|
||||
]
|
||||
}
|
||||
},
|
||||
computed: {},
|
||||
watch: {},
|
||||
mounted() {},
|
||||
mounted() {
|
||||
this.getLink();
|
||||
},
|
||||
methods: {
|
||||
// 跳转链接
|
||||
openLinkUrl (linkUri) {
|
||||
@@ -62,7 +67,17 @@ export default {
|
||||
window.open('https://' + linkUri)
|
||||
}
|
||||
},
|
||||
getLink () {
|
||||
this.$http.get('sarUrl/tsUrl', {}, {
|
||||
_this: this,
|
||||
loading: 'Loading'
|
||||
}, res=> {
|
||||
this.data = res.data
|
||||
console.log(data);
|
||||
})
|
||||
}
|
||||
},
|
||||
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user