mirror of
https://github.com/Luzifer/go-latestver.git
synced 2024-12-29 23:01:19 +00:00
37 lines
504 B
Vue
37 lines
504 B
Vue
<template>
|
|
<b-row>
|
|
<b-col>
|
|
<log-table :logs="logs" />
|
|
</b-col>
|
|
</b-row>
|
|
</template>
|
|
|
|
<script>
|
|
import LogTable from './logtable.vue'
|
|
|
|
export default {
|
|
components: { LogTable },
|
|
|
|
data() {
|
|
return {
|
|
logs: [],
|
|
}
|
|
},
|
|
|
|
methods: {
|
|
fetchLog() {
|
|
return fetch('/v1/log?num=50')
|
|
.then(resp => resp.json())
|
|
.then(data => {
|
|
this.logs = data
|
|
})
|
|
},
|
|
},
|
|
|
|
mounted() {
|
|
this.fetchLog()
|
|
},
|
|
|
|
name: 'GoLatestVerLog',
|
|
}
|
|
</script>
|