1
0
mirror of https://github.com/hotomoe/hotomoe synced 2025-01-10 03:42:51 +09:00
hotomoe/src/client/app/desktop/views/pages/admin/admin.notes-chart.vue
syuilo 2cbd35acc4 🎨
2018-08-18 05:05:39 +09:00

40 lines
676 B
Vue

<template>
<div class="card">
<header>%i18n:@title%</header>
<div class="card">
<header>%i18n:@local%</header>
<x-chart v-if="data" :data="data" type="local"/>
</div>
<div class="card">
<header>%i18n:@remote%</header>
<x-chart v-if="data" :data="data" type="remote"/>
</div>
</div>
</template>
<script lang="ts">
import Vue from "vue";
import XChart from "./admin.notes-chart.chart.vue";
export default Vue.extend({
components: {
XChart
},
data() {
return {
data: null
};
},
created() {
(this as any).api('aggregation/notes').then(res => {
this.data = res;
});
}
});
</script>
<style lang="stylus" scoped>
@import '~const.styl'
</style>