mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
improved admin dashboard
This commit is contained in:
parent
76a769f91b
commit
667122d1e7
@ -10,7 +10,9 @@
|
|||||||
size="x-large"
|
size="x-large"
|
||||||
uppercase>
|
uppercase>
|
||||||
<no-ssr slot="count">
|
<no-ssr slot="count">
|
||||||
<hc-count-to :end-val="statistics.countUsers || 0" />
|
<hc-count-to
|
||||||
|
:start-val="statisticsBefore.countUsers || 0"
|
||||||
|
:end-val="statistics.countUsers || 0" />
|
||||||
</no-ssr>
|
</no-ssr>
|
||||||
</ds-number>
|
</ds-number>
|
||||||
</ds-flex-item>
|
</ds-flex-item>
|
||||||
@ -21,7 +23,9 @@
|
|||||||
size="x-large"
|
size="x-large"
|
||||||
uppercase>
|
uppercase>
|
||||||
<no-ssr slot="count">
|
<no-ssr slot="count">
|
||||||
<hc-count-to :end-val="statistics.countPosts || 0" />
|
<hc-count-to
|
||||||
|
:start-val="statisticsBefore.countPosts || 0"
|
||||||
|
:end-val="statistics.countPosts || 0" />
|
||||||
</no-ssr>
|
</no-ssr>
|
||||||
</ds-number>
|
</ds-number>
|
||||||
</ds-flex-item>
|
</ds-flex-item>
|
||||||
@ -32,7 +36,9 @@
|
|||||||
size="x-large"
|
size="x-large"
|
||||||
uppercase>
|
uppercase>
|
||||||
<no-ssr slot="count">
|
<no-ssr slot="count">
|
||||||
<hc-count-to :end-val="statistics.countComments || 0" />
|
<hc-count-to
|
||||||
|
:start-val="statisticsBefore.countComments || 0"
|
||||||
|
:end-val="statistics.countComments || 0" />
|
||||||
</no-ssr>
|
</no-ssr>
|
||||||
</ds-number>
|
</ds-number>
|
||||||
</ds-flex-item>
|
</ds-flex-item>
|
||||||
@ -47,7 +53,9 @@
|
|||||||
size="x-large"
|
size="x-large"
|
||||||
uppercase>
|
uppercase>
|
||||||
<no-ssr slot="count">
|
<no-ssr slot="count">
|
||||||
<hc-count-to :end-val="statistics.countNotifications || 0" />
|
<hc-count-to
|
||||||
|
:start-val="statisticsBefore.countNotifications || 0"
|
||||||
|
:end-val="statistics.countNotifications || 0" />
|
||||||
</no-ssr>
|
</no-ssr>
|
||||||
</ds-number>
|
</ds-number>
|
||||||
</ds-flex-item>
|
</ds-flex-item>
|
||||||
@ -58,7 +66,9 @@
|
|||||||
size="x-large"
|
size="x-large"
|
||||||
uppercase>
|
uppercase>
|
||||||
<no-ssr slot="count">
|
<no-ssr slot="count">
|
||||||
<hc-count-to :end-val="statistics.countOrganizations || 0" />
|
<hc-count-to
|
||||||
|
:start-val="statisticsBefore.countOrganizations || 0"
|
||||||
|
:end-val="statistics.countOrganizations || 0" />
|
||||||
</no-ssr>
|
</no-ssr>
|
||||||
</ds-number>
|
</ds-number>
|
||||||
</ds-flex-item>
|
</ds-flex-item>
|
||||||
@ -69,7 +79,9 @@
|
|||||||
size="x-large"
|
size="x-large"
|
||||||
uppercase>
|
uppercase>
|
||||||
<no-ssr slot="count">
|
<no-ssr slot="count">
|
||||||
<hc-count-to :end-val="statistics.countProjects || 0" />
|
<hc-count-to
|
||||||
|
:start-val="statisticsBefore.countProjects || 0"
|
||||||
|
:end-val="statistics.countProjects || 0" />
|
||||||
</no-ssr>
|
</no-ssr>
|
||||||
</ds-number>
|
</ds-number>
|
||||||
</ds-flex-item>
|
</ds-flex-item>
|
||||||
@ -84,7 +96,9 @@
|
|||||||
size="x-large"
|
size="x-large"
|
||||||
uppercase>
|
uppercase>
|
||||||
<no-ssr slot="count">
|
<no-ssr slot="count">
|
||||||
<hc-count-to :end-val="statistics.countInvites || 0" />
|
<hc-count-to
|
||||||
|
:start-val="statisticsBefore.countInvites || 0"
|
||||||
|
:end-val="statistics.countInvites || 0" />
|
||||||
</no-ssr>
|
</no-ssr>
|
||||||
</ds-number>
|
</ds-number>
|
||||||
</ds-flex-item>
|
</ds-flex-item>
|
||||||
@ -95,7 +109,9 @@
|
|||||||
size="x-large"
|
size="x-large"
|
||||||
uppercase>
|
uppercase>
|
||||||
<no-ssr slot="count">
|
<no-ssr slot="count">
|
||||||
<hc-count-to :end-val="statistics.countFollows || 0" />
|
<hc-count-to
|
||||||
|
:start-val="statisticsBefore.countFollows || 0"
|
||||||
|
:end-val="statistics.countFollows || 0" />
|
||||||
</no-ssr>
|
</no-ssr>
|
||||||
</ds-number>
|
</ds-number>
|
||||||
</ds-flex-item>
|
</ds-flex-item>
|
||||||
@ -106,7 +122,9 @@
|
|||||||
size="x-large"
|
size="x-large"
|
||||||
uppercase>
|
uppercase>
|
||||||
<no-ssr slot="count">
|
<no-ssr slot="count">
|
||||||
<hc-count-to :end-val="statistics.countShouts || 0" />
|
<hc-count-to
|
||||||
|
:start-val="statisticsBefore.countShouts || 0"
|
||||||
|
:end-val="statistics.countShouts || 0" />
|
||||||
</no-ssr>
|
</no-ssr>
|
||||||
</ds-number>
|
</ds-number>
|
||||||
</ds-flex-item>
|
</ds-flex-item>
|
||||||
@ -126,7 +144,8 @@ export default {
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
statistics: {}
|
statistics: {},
|
||||||
|
statisticsBefore: {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@ -134,6 +153,16 @@ export default {
|
|||||||
return process.client
|
return process.client
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
watch: {
|
||||||
|
statistics(newVal) {
|
||||||
|
setTimeout(() => {
|
||||||
|
this.statisticsBefore = { ...this.statistics }
|
||||||
|
}, 3000)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
this.$apollo.queries.statistics.startPolling(5000)
|
||||||
|
},
|
||||||
apollo: {
|
apollo: {
|
||||||
statistics: {
|
statistics: {
|
||||||
query: gql(`
|
query: gql(`
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user