Сводная статистика посещений

This commit is contained in:
iriska-gri committed 2023-10-13 14:19:04 +03:00
1 parent 360aafe6d6
commit e3e2576347
17 files changed
+164 -30

No files matched your search

+68 -3
View File
@@ -5,10 +5,55 @@
<!-- </div> -->
<v-row>
<v-col
class="text-h6 text-grey text-center align-self-center text--lighten-1 font-weight-light"
class="ma-3"
>
О портале
{{visiting}}
<v-table density="compact">
<thead>
<tr>
<th class="text-left">
Страница
</th>
<th class="text-left">
Количество посещений
</th>
</tr>
</thead>
<tbody>
<tr
v-for="item in visiting.pages"
:key="item.name"
>
<td>{{ item.page }}</td>
<td>{{ item.count__sum }}</td>
</tr>
</tbody>
</v-table>
<v-table density="compact" class="mt-3">
<thead>
<tr>
<th class="text-left">
Страница
</th>
<th class="text-left">
Количество посещений
</th>
</tr>
</thead>
<tbody>
<tr
v-for="item in visiting.users"
:key="item.name"
>
<td>{{ item.user__username }}</td>
<td>{{ item.page }}</td>
<td>{{ item.count__sum }}</td>
</tr>
</tbody>
</v-table>
</v-col>
@@ -17,9 +62,29 @@
</template>
<script>
import { ref } from 'vue'
import {pagecounter} from '@/utils/universal_functions'
import {getfromserver} from '@/utils/universal_functions'
export default {
setup(){
pagecounter()
const visiting = ref({})
const desserts = [
{
name: 'Frozen Yogurt',
calories: 159,
},]
getfromserver(`api/watcher/counter/`, visiting)
return {desserts,
visiting
}
}
}
</script>
<style>