mirror of https://github.com/doccano/doccano.git
pythonannotation-tooldatasetsactive-learningtext-annotationdatasetnatural-language-processingdata-labelingmachine-learning
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
36 lines
882 B
36 lines
882 B
<template>
|
|
<v-card>
|
|
<v-card-title>Member's Progress</v-card-title>
|
|
<v-divider />
|
|
<v-card-text>
|
|
<div v-for="(item, index) in stats.progress" :key="index" class="mb-2">
|
|
<span class="font-weight-medium">{{ item.user }}</span>
|
|
<span class="font-weight-medium">{{ item.done }} / {{ stats.total }}</span>
|
|
<v-progress-linear :value="rate(item.done, stats.total)" />
|
|
</div>
|
|
</v-card-text>
|
|
</v-card>
|
|
</template>
|
|
|
|
<script lang="ts">
|
|
import Vue from 'vue'
|
|
import { Progress } from '~/domain/models/metrics/metrics'
|
|
|
|
export default Vue.extend({
|
|
data() {
|
|
return {
|
|
stats: {} as Progress
|
|
}
|
|
},
|
|
|
|
async created() {
|
|
this.stats = await this.$repositories.metrics.fetchMemberProgress(this.$route.params.id)
|
|
},
|
|
|
|
methods: {
|
|
rate(done: number, total: number) {
|
|
return (done / total) * 100
|
|
}
|
|
}
|
|
})
|
|
</script>
|