Очистка от старой таблицы

This commit is contained in:
iriska-gri committed 2024-02-06 12:49:17 +03:00
1 parent 40b686182b
commit db38c3767f
7 files changed
+192 -43

No files matched your search

+3 -3
View File
@@ -22919,9 +22919,9 @@
}
},
"node_modules/vuetify": {
"version": "3.4.10",
"resolved": "https://registry.npmjs.org/vuetify/-/vuetify-3.4.10.tgz",
"integrity": "sha512-tObGoumCJxuK26OpS/CLZZIJAgDtN2cnd31vJscVhpuf6jeMD7wh8IsgfZownAOXU1FcKWVQwn1RSDsoXk5cJA==",
"version": "3.5.2",
"resolved": "https://registry.npmjs.org/vuetify/-/vuetify-3.5.2.tgz",
"integrity": "sha512-H/g9+8Loykt50qe9mruHkwWsAIgfQ8gO+SPTAV2uaCFmfYPSFRfu0aGcZ42iWu4bZ9ZkgswIIDaVsfnKINd8yg==",
"engines": {
"node": "^12.20 || >=14.13"
},
+1 -3
View File
@@ -45,9 +45,7 @@ import {useAccountStore} from '@/store/AccountStore'
background: rgb(var(--v-theme-scrollbar))
}
.pointer {
cursor:pointer
}
.bggrad {
background: linear-gradient(to top right, rgba(19,84,122,.8), rgba(128,208,199,.8));
@@ -12,19 +12,18 @@
</v-col>
<v-col class="ml-n7 pt-2">
Рейтинг посещаемости страниц портала
<!-- <v-icon size="small" icon="mdi-menu-down" class="pa-0"/> -->
</v-col>
</v-row>
</v-card-title>
<v-divider/>
<v-row class="overflow-auto h-0">
<v-col class="d-flex flex-column">
<v-table
fixed-header
height="0"
hover
class="pointer"
hover
class="cursor-default"
>
<thead>
<tr>
@@ -41,16 +40,16 @@
<td>{{key}}</td>
<td>
<tooltip-text
v-if="val.now.unique.length>0"
:text="modelrating?val.now.unique.length:val.now.countall"
>
<template v-slot:tooltip >
<template v-slot:tooltip>
<v-row
no-gutters v-for="n in val.now.unique"
:key="n"
>
<v-col >
<v-col>
{{n}}
</v-col>
</v-row>
@@ -60,29 +59,26 @@
0
</span>
</td>
<td>
<td >
<tooltip-text
v-if="val.year.unique.length>0"
:text="modelrating?val.year.unique.length:val.year.countall"
>
<template v-slot:tooltip>
<v-row
no-gutters v-for="n in val.year.unique"
:key="n"
>
<v-col>
{{n}}
</v-col>
</v-row>
</template>
<template v-slot:tooltip>
<v-row
no-gutters
v-for="n in val.year.unique"
:key="n"
>
<v-col>
{{n}}
</v-col>
</v-row>
</template>
</tooltip-text>
<span v-else>
0
</span>
0
</span>
<!-- <tooltip-number
:number = modelrating?val.year.unique.length:val.year.countall
:tooltip = val.year.unique
@@ -1,19 +1,83 @@
<template>
<v-card class="text-center h-100 d-flex flex-column" >
<v-card class="text-center h-100 d-flex flex-column pa-1" >
<my-helper :pretext="activusers"/>
<v-row no-gutters class="overflow-auto h-0">
<v-col>
<v-table hover>
<v-col class="d-flex flex-column">
<v-data-table
v-model:expanded="expanded"
:headers="dessertHeaders"
:items="desserts"
item-value="user.fio"
show-expand
>
<template v-slot:top>
<v-toolbar flat>
<v-toolbar-title>Самые активные пользователи</v-toolbar-title>
</v-toolbar>
</template>
<!-- <template v-slot:item.user.fio="{ item }">
{{item.user.fio}}
</template> -->
<template v-slot:expanded-row="{ columns, item }">
<tr>
<td :colspan="columns.length">
<v-chip
prepend-icon="mdi-script"
size="small"
class="font-italic my-2"
text="Количество посещенных страниц за выбранный период (всего/уникальные)"
variant="text"
color="grey"
/>
<v-table
density="compact"
>
<tbody>
<tr
v-for="(n, key) in item.tooltip.namepages"
:key="key"
class="text-center"
>
<td class="text-left">{{key}}</td>
<td>
{{n.count}}
</td>
<td>
{{n.unic}}
</td>
</tr>
</tbody>
</v-table>
</td>
</tr>
</template>
</v-data-table>
<!-- <v-table hover fixed-header height="0"
class="cursor-default">
<thead>
<tr>
<th></th>
<th v-for="(n, key) in th_text" :key="key">
<tooltip-text
:text="key"
>
<template v-slot:tooltip>
{{n}}
{{n}}
</template>
</tooltip-text>
</th>
</tr>
</thead>
@@ -53,10 +117,11 @@
<tr
v-for="(n, key) in user.tooltip.namepages"
:key="key"
class="text-center"
>
<td>{{key}}</td>
<td class="text-left">{{key}}</td>
<td>
{{n.count}}
{{n.count}}
</td>
<td>
{{n.unic}}
@@ -69,14 +134,14 @@
</td>
</tr>
</tbody>
</v-table>
</v-table> -->
</v-col>
</v-row>
</v-card>
</template>
<script>
import { ref } from 'vue'
import { spravURL } from '@/utils/axios-api'
import {checkremote} from '@/utils/universal_functions'
import listUser from '@/components/UI//fiousercard/listUser.vue'
@@ -97,6 +162,91 @@ export default {
setup() {
const expanded = ref([])
const dessertHeaders = [
{
title: '',
align: 'start',
sortable: false,
key: 'user.fio',
},
{ title: 'Просмотры', key: 'info.count' },
{ title: 'Сессии', key: 'info.session' },
{ title: 'Страницы', key: 'info.pages' },
]
const desserts = [
// {
// name: 'Frozen Yogurt',
// count: 5999,
// session: 21,
// pages: 56
// },
// {
// name: 'Ice cream sandwich',
// count: 2,
// session: 45,
// pages: 22
// },
// {
// name: 'Ice cream sandwich',
// count: 2,
// session: 45,
// pages: 22
// },
{
id:1,
user: {
login: "9966-00-001",
post: "Начальник инспекции",
fio: "Толоко Б.Б."
},
info: {
count: 253,
session: 4,
pages: 5
},
tooltip: {
namepages: {
"О портале": {
count: 241,
unic: 3
},
}
}
},
{ id:2,
user: {
login: "9966-00-107",
post: "Старший специалист 1 разряда",
fio: "Гришина И.С."
},
info: {
count: 6010,
session: 21,
pages: 56
},
tooltip: {
namepages: {
"О портале": {
count: 71,
unic: 90
},
"Портал МИ ФНС России по ЦОД №2": {
count: 120,
unic: 27
}
}
}
},
]
const th_text = {
"Просмотры": "Сколько было открыто страниц за период",
"Сессии": "Сколько дней за период был посещен Портал",
@@ -106,7 +256,10 @@ export default {
return {
checkremote,
spravURL,
th_text
th_text,
expanded,
dessertHeaders,
desserts
}
}
}
+1 -1
View File
@@ -3,7 +3,7 @@
location="bottom"
>
<template v-slot:activator="{ props }">
<span v-bind="props">
<span v-bind="props" class="cursor-help">
{{text}}
</span>
</template>
+1 -1
View File
@@ -166,7 +166,7 @@
<v-img
cover
class=" pointer"
class=" cursor-pointer"
:src="`${burl}${e.img}`"
@click="openImg(e.id)"
/>
+4 -2
View File
@@ -1,7 +1,7 @@
<template>
<v-row no-gutters class="flex-column gap ma-1">
<toolbar-filter/>
<v-col lg=3 class="w100 ">
<v-col lg=3 class="w100">
<v-row no-gutters class="h-100 gap">
<v-col lg=2 class="bg-blue">
{{format1(previous.start)}} - {{format1(previous.end)}}
@@ -16,7 +16,7 @@
<v-col lg=2 class="bg-green">
visiting- (все данные)
<my-helper :pretext="visiting"/>
<!-- <my-helper :pretext="visiting"/> -->
</v-col>
<v-col lg=4 class="d-flex flex-column">
<rating-page :pages_count=pages_count />
@@ -235,6 +235,7 @@ setup(){
const dataLineChart = ref({})
const dataActivusers = ref({})
const dataTopUser = ref({})
const dataTopUsers = ref([])
const previous = ref({start: new Date(), end: new Date()})
const selected_days = ref({today: 'сегодня', year: {start: new Date(), end: new Date()}})
@@ -277,6 +278,7 @@ setup(){
let lineCharts = {}
let activusers = {}
let top_user = {}
let top_users = []
// let portal_traffic = {
// now: {
// title: '',