From 811111f486a56c44fac41b3d7ff3c8e2700c5b40 Mon Sep 17 00:00:00 2001 From: Gregor Date: Tue, 10 Mar 2020 00:32:06 +0100 Subject: [PATCH] add active members count and fixing style for small screens resolve tickets #220 and ticket #221 https://groeger-clan.duckdns.org/redmine/issues/220 https://groeger-clan.duckdns.org/redmine/issues/221 --- src/components/user/Config.vue | 24 ++++++++++++---- src/components/vorstand/UserManager.vue | 38 +++++++++++++++++++++++-- 2 files changed, 54 insertions(+), 8 deletions(-) diff --git a/src/components/user/Config.vue b/src/components/user/Config.vue index eb34dfe..2933ed9 100644 --- a/src/components/user/Config.vue +++ b/src/components/user/Config.vue @@ -107,7 +107,7 @@ - + - + - + - Save + Speicherns {{ error }} @@ -172,6 +172,7 @@ export default { lastname: null, password: null, controlPassword: null, + isFulllineText: false, equal_password: value => this.password === value || 'Passwörter sind nicht identisch.', email: value => { @@ -183,11 +184,21 @@ export default { } } }, + mounted() { + this.$nextTick(function() { + window.addEventListener('resize', this.getWindowWidth); + this.getWindowWidth() + + }) + }, methods: { ...mapActions({ saveConfig: 'user/saveConfig', getStatus: 'user/getStatus' }), + getWindowWidth() { + this.isFulllineText = document.documentElement.clientWidth <= 600; + }, save() { let user = {} if (this.firstname) user.firstname = this.firstname @@ -237,4 +248,7 @@ export default { } - + diff --git a/src/components/vorstand/UserManager.vue b/src/components/vorstand/UserManager.vue index 72f9491..bbb66ff 100644 --- a/src/components/vorstand/UserManager.vue +++ b/src/components/vorstand/UserManager.vue @@ -85,7 +85,7 @@ - + - + + + + { @@ -228,9 +249,16 @@ export default { } }, allVotings() { + console.log(this.users); return this.users.filter(a => { return a.voting }).length + }, + + allActiveUsers(){ + return this.users.filter(a => { + return a.statusgroup === 1 + }).length } }, created() { @@ -240,4 +268,8 @@ export default { } - +