diff --git a/public/json-example/admin_card_statistic.json b/public/json-example/admin_card_statistic.json new file mode 100644 index 000000000..bacdccb5a --- /dev/null +++ b/public/json-example/admin_card_statistic.json @@ -0,0 +1,36 @@ +{"state":"success", "statisticdata": + [ + { + "i_creation_sum": 29288278.4653, + "i_creation_mon": 68278.4653, + "i_creation_365d": 19288278.4653, + "i_creation_30d": 288278.4653, + "i_creation_14d": 88278.4653, + "i_creation_7d": 3278.4653 + }, + { + "i_transience_sum": 8278.4653, + "i_transience_mon": 8278.4653, + "i_transience_365d": 8278.4653, + "i_transience_30d": 178.4653, + "i_transience_14d": 78.4653, + "i_transience_7d": 8.4653 + }, + { + "i_exchange_sum": 23345.2324, + "i_exchange_mon": 2, + "i_exchange_365d": 2, + "i_exchange_30d": 2, + "i_exchange_14d": 2, + "i_exchange_7d": 2 + }, + { + "i_members_sum": 5398, + "i_members_mon": 234, + "i_members_365d": 2356, + "i_members_30d": 123, + "i_members_14d": 23, + "i_members_7d": 24 + } + ] +} \ No newline at end of file diff --git a/public/json-example/admin_charts_statistic.json b/public/json-example/admin_charts_statistic.json new file mode 100644 index 000000000..8c7e6667b --- /dev/null +++ b/public/json-example/admin_charts_statistic.json @@ -0,0 +1,64 @@ +{"state":"success", "statisticdata": + [ + { + "charts_creation_0_mon": 5635, + "charts_creation_1_mon": 5635, + "charts_creation_2_mon": 5635, + "charts_creation_3_mon": 5635, + "charts_creation_4_mon": 5635, + "charts_creation_5_mon": 5635, + "charts_creation_6_mon": 5635, + "charts_creation_7_mon": 5635, + "charts_creation_8_mon": 5635, + "charts_creation_9_mon": 5635, + "charts_creation_10_mon": 5635, + "charts_creation_11_mon": 5635, + "charts_creation_12_mon": 5635 + }, + { + "charts_transience_0_mon": 5635, + "charts_transience_1_mon": 5635, + "charts_transience_2_mon": 5635, + "charts_transience_3_mon": 5635, + "charts_transience_4_mon": 5635, + "charts_transience_5_mon": 5635, + "charts_transience_6_mon": 5635, + "charts_transience_7_mon": 5635, + "charts_transience_8_mon": 5635, + "charts_transience_9_mon": 5635, + "charts_transience_10_mon": 5635, + "charts_transience_11_mon": 5635, + "charts_transience_12_mon": 5635 + }, + { + "charts_exchange_0_mon": 5635, + "charts_exchange_1_mon": 5635, + "charts_exchange_2_mon": 5635, + "charts_exchange_3_mon": 5635, + "charts_exchange_4_mon": 5635, + "charts_exchange_5_mon": 5635, + "charts_exchange_6_mon": 5635, + "charts_exchange_7_mon": 5635, + "charts_exchange_8_mon": 5635, + "charts_exchange_9_mon": 5635, + "charts_exchange_10_mon": 5635, + "charts_exchange_11_mon": 5635, + "charts_exchange_12_mon": 5635 + }, + { + "charts_members_0_mon": 5635, + "charts_members_1_mon": 5635, + "charts_members_2_mon": 5635, + "charts_members_3_mon": 5635, + "charts_members_4_mon": 5635, + "charts_members_5_mon": 5635, + "charts_members_6_mon": 5635, + "charts_members_7_mon": 5635, + "charts_members_8_mon": 5635, + "charts_members_9_mon": 5635, + "charts_members_10_mon": 5635, + "charts_members_11_mon": 5635, + "charts_members_12_mon": 5635 + } + ] +} \ No newline at end of file diff --git a/public/json-example/admin_community_statistic.json b/public/json-example/admin_community_statistic.json new file mode 100644 index 000000000..f083991aa --- /dev/null +++ b/public/json-example/admin_community_statistic.json @@ -0,0 +1,19 @@ +{"state":"success", "statisticdata": + [ + { + "community_entries1_mon": 5635, + "community_entries2_mon": 5635, + "community_entries3_mon": 5635, + "community_entries4_mon": 5635, + "community_entries5_mon": 5635, + "community_entries6_mon": 5635, + "community_entries7_mon": 5635, + "community_entries8_mon": 5635, + "community_entries9_mon": 5635, + "community_entries0_mon": 5635, + "community_entries10_mon": 5635, + "community_entries11_mon": 5635, + "community_entries12_mon": 5635 + } + ] +} \ No newline at end of file diff --git a/public/json-example/admin_transaction_list.json b/public/json-example/admin_transaction_list.json new file mode 100644 index 000000000..a1af47db8 --- /dev/null +++ b/public/json-example/admin_transaction_list.json @@ -0,0 +1,61 @@ +{"state":"success", "transactions": + [ + { + "name": "Jon Tester", + "email": "jon@example.de", + "type": "send", + "transaction_id": 12, + "date": "29-11-2020", + "balance": 7000, + "memo": "Reperatur Waschbecken", + "pubkey": "abcdefghi123456789" + + }, + { + "name": "Gradido Community", + "email": "gradido@example.de", + "type": "creation", + "transaction_id": 11, + "date": "1-11-2020", + "balance": 10000, + "memo": "Müll gesammelt im Wald", + "pubkey": "abcdefghi123456789" + + }, + { + "name": "Maria Tester", + "email": "maria@example.de", + "type": "receive", + "transaction_id": 7, + "date": "23-10-2020", + "balance": 5000, + "memo": "Spende an Alice ", + "pubkey": "abcdefghi123456789" + + }, + { + "name": "Alice Tester", + "email": "alice@example.de", + "type": "receive", + "transaction_id": 5, + "date": "2-8-2020", + "balance": 1000, + "memo": "Bob hat meinen Müll getrennt", + "pubkey": "abcdefghi123456789" + + }, + { + "name": "Gradido Community", + "email": "gradido@example.de", + "type": "creation", + "transaction_id": 1, + "date": "11-7-2020", + "balance": 10000, + "memo": "Bob hat meinen Müll getrennt", + "pubkey": "abcdefghi123456789" + + } + ], + "transactionExecutingCount": 8750, + "count": 5 +} \ No newline at end of file diff --git a/public/json-example/admin_transience_list.json b/public/json-example/admin_transience_list.json new file mode 100644 index 000000000..0cbacfbd8 --- /dev/null +++ b/public/json-example/admin_transience_list.json @@ -0,0 +1,49 @@ +{"state":"success", "participation": + [ + { + "name": "", + "type": "submitted", + "participation_id": 412, + "date_submitted": "9-12-2020", + "titel": "Lorem Ipsum panta lore es Tastina sero was. ", + "text": "Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. ", + "date_participation": "8-12-2020", + "plz_participation": "01099", + "pubkey": "abcdefghi123456789" + }, + { + "name": "", + "type": "in progress", + "participation_id": 312, + "date_submitted": "2-11-2020", + "titel": "Lorem Ipsum panta lore es Tastina sero was. ", + "text": "Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. ", + "date_participation": "2-11-2020", + "plz_participation": "01099", + "pubkey": "abcdefghi123456789" + }, + { + "name": "", + "type": "confirmed", + "participation_id": 212, + "date_submitted": "20-10-2020", + "titel": "Lorem Ipsum panta lore es Tastina sero was. ", + "text": "Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. ", + "date_participation": "20-10-2020", + "plz_participation": "01099", + "pubkey": "abcdefghi123456789" + }, + { + "name": "", + "type": "rejected", + "participation_id": 142, + "date_submitted": "17-9-2020", + "titel": "Lorem Ipsum panta lore es Tastina sero was. ", + "text": "Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. ", + "date_participation": "17-9-2020", + "plz_participation": "01099", + "pubkey": "abcdefghi123456789" + } + ], + "count": 4 +} \ No newline at end of file diff --git a/public/json-example/admin_userlist.json b/public/json-example/admin_userlist.json new file mode 100644 index 000000000..a8550716f --- /dev/null +++ b/public/json-example/admin_userlist.json @@ -0,0 +1,52 @@ +{"state":"success", "admin0userlist": + [ + { + "created": 1578688666, + "disabled": false, + "email": "dervommond@gmail.com", + "email_checked": true, + "first_name": "Max", + "group_alias": "gdd1", + "ident_hash": 2928827813, + "last_name": "Miau", + "public_hex": "2ed28a1cf5e116d83615406bc577152221c2f774a5656f66a0e7540f7576d71b", + "role": "admin", + "username": "", + "balance_gdd": 174500, + "balance_gdt": 4500, + "errorCount": 0 + }, + { + "created": 1578685678, + "disabled": false, + "email": "ttwer@gmail.com", + "email_checked": true, + "first_name": "John", + "group_alias": "gdd1", + "ident_hash": 2928827813, + "last_name": "Doe", + "public_hex": "2ed28a1cf5e116d83615406bc577152221c2f774a5656f66a0e7540f7576d71x", + "role": "user", + "username": "", + "balance_gdd": 144500, + "balance_gdt": 0, + "errorCount": 0 + }, + { + "created": 1578635671, + "disabled": false, + "email": "test@gmail.com", + "email_checked": true, + "first_name": "Alice", + "group_alias": "gdd1", + "ident_hash": 4928827813, + "last_name": "Seer", + "public_hex": "2ed28a1cf5e116d83615406bc577152221c2f774a5656f66a0e7540f7576d71a", + "role": "user", + "username": "", + "balance_gdd": 444500, + "balance_gdt": 4500, + "errorCount": 0 + } + ] +} \ No newline at end of file diff --git a/public/json-example/example.json b/public/json-example/example.json new file mode 100644 index 000000000..e69de29bb diff --git a/public/json-example/userdata.json b/public/json-example/userdata.json new file mode 100644 index 000000000..69f5a8041 --- /dev/null +++ b/public/json-example/userdata.json @@ -0,0 +1,19 @@ +{"state":"success", "userdata": + [ + { + "created": 1578688666, + "disabled": false, + "email": "dervommond@gmail.com", + "email_checked": true, + "first_name": "Max", + "group_alias": "gdd1", + "ident_hash": 2928827813, + "last_name": "Miau", + "public_hex": "2ed28a1cf5e116d83615406bc577152221c2f774a5656f66a0e7540f7576d71b", + "role": "admin", + "username": "", + "balance": 174500, + "errorCount": 0 + } + ] +} \ No newline at end of file diff --git a/public/json-example/userparticipation.json b/public/json-example/userparticipation.json new file mode 100644 index 000000000..4e29f117b --- /dev/null +++ b/public/json-example/userparticipation.json @@ -0,0 +1,45 @@ +{"state":"success", "participation": + [ + { + "type": "submitted", + "participation_id": 412, + "date_submitted": "9-12-2020", + "titel": "Lorem Ipsum panta lore es Tastina sero was. ", + "text": "Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. ", + "date_participation": "8-12-2020", + "plz_participation": "01099", + "pubkey": "abcdefghi123456789" + }, + { + "type": "in progress", + "participation_id": 312, + "date_submitted": "2-11-2020", + "titel": "Lorem Ipsum panta lore es Tastina sero was. ", + "text": "Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. ", + "date_participation": "2-11-2020", + "plz_participation": "01099", + "pubkey": "abcdefghi123456789" + }, + { + "type": "confirmed", + "participation_id": 212, + "date_submitted": "20-10-2020", + "titel": "Lorem Ipsum panta lore es Tastina sero was. ", + "text": "Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. ", + "date_participation": "20-10-2020", + "plz_participation": "01099", + "pubkey": "abcdefghi123456789" + }, + { + "type": "rejected", + "participation_id": 142, + "date_submitted": "17-9-2020", + "titel": "Lorem Ipsum panta lore es Tastina sero was. ", + "text": "Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. Lorem Ipsum panta lore es Tastina sero was. ", + "date_participation": "17-9-2020", + "plz_participation": "01099", + "pubkey": "abcdefghi123456789" + } + ], + "count": 4 +} \ No newline at end of file diff --git a/public/json-example/usertransactions.json b/public/json-example/usertransactions.json new file mode 100644 index 000000000..a1af47db8 --- /dev/null +++ b/public/json-example/usertransactions.json @@ -0,0 +1,61 @@ +{"state":"success", "transactions": + [ + { + "name": "Jon Tester", + "email": "jon@example.de", + "type": "send", + "transaction_id": 12, + "date": "29-11-2020", + "balance": 7000, + "memo": "Reperatur Waschbecken", + "pubkey": "abcdefghi123456789" + + }, + { + "name": "Gradido Community", + "email": "gradido@example.de", + "type": "creation", + "transaction_id": 11, + "date": "1-11-2020", + "balance": 10000, + "memo": "Müll gesammelt im Wald", + "pubkey": "abcdefghi123456789" + + }, + { + "name": "Maria Tester", + "email": "maria@example.de", + "type": "receive", + "transaction_id": 7, + "date": "23-10-2020", + "balance": 5000, + "memo": "Spende an Alice ", + "pubkey": "abcdefghi123456789" + + }, + { + "name": "Alice Tester", + "email": "alice@example.de", + "type": "receive", + "transaction_id": 5, + "date": "2-8-2020", + "balance": 1000, + "memo": "Bob hat meinen Müll getrennt", + "pubkey": "abcdefghi123456789" + + }, + { + "name": "Gradido Community", + "email": "gradido@example.de", + "type": "creation", + "transaction_id": 1, + "date": "11-7-2020", + "balance": 10000, + "memo": "Bob hat meinen Müll getrennt", + "pubkey": "abcdefghi123456789" + + } + ], + "transactionExecutingCount": 8750, + "count": 5 +} \ No newline at end of file diff --git a/src/views/AdminOverview.vue b/src/views/AdminOverview.vue index fa6337341..854b95be9 100644 --- a/src/views/AdminOverview.vue +++ b/src/views/AdminOverview.vue @@ -150,6 +150,60 @@ + + + + + + Admin Participation List + /public/json-example/admin_card_statistic.json + + {{cardstatistic}} + + + + + + Admin Charts Statistic + /public/json-example/admin_charts_statistic.json + + {{chartsstatistic}} + + + + + + Admin Community Statistic + /public/json-example/admin_community_statistic.json + + {{communitystatistic}} + + + + + Admin User List + /public/json-example/admin_userlist.json + + {{userlist}} + + + + + Admin Transaction List + /public/json-example/admin_transaction_list.json + + {{transactionlist}} + + + + + + Admin Transience List + /public/json-example/admin_transience_list.json + + {{transiencelist}} + + @@ -171,6 +225,7 @@ import PageVisitsTable from './Dashboard/PageVisitsTable'; import AdminUserSearch from './AdminOverview/AdminUserSearch'; import AdminUserCreation from './AdminOverview/AdminUserCreation'; + import axios from 'axios'; export default { @@ -186,14 +241,21 @@ }, data() { return { + statisticdata: [], + cardstatistic:[], + chartsstatistic: [], + communitystatistic: [], + userlist: [], + transactionlist: [], + transiencelist: [], filter: '', - items: [ - { id: 1, first_name: "Mikkel", last_name: "Hansen", age: 54 }, - { id: 2, first_name: "Kasper", last_name: "Hvidt", age: 42 }, - { id: 3, first_name: "Lasse", last_name: "Boesen", age: 39 }, - { id: 4, first_name: "Kasper", last_name: "Hansen", age: 62 }, - { id: 5, first_name: "Mads", last_name: "Mikkelsen", age: 31 }, - ], + items: [ + { id: 1, first_name: "Mikkel", last_name: "Hansen", age: 54 }, + { id: 2, first_name: "Kasper", last_name: "Hvidt", age: 42 }, + { id: 3, first_name: "Lasse", last_name: "Boesen", age: 39 }, + { id: 4, first_name: "Kasper", last_name: "Hansen", age: 62 }, + { id: 5, first_name: "Mads", last_name: "Mikkelsen", age: 31 }, + ], bigLineChart: { allData: [ [0, 20, 10, 30, 15, 40, 20, 60, 60], @@ -226,6 +288,69 @@ }; }, methods: { + TransienceList() { + axios.get("/json-example/admin_transience_list.json").then((d) => { + console.log(d); + this.transiencelist = d.data; + + }, (error) => { + console.log(error); + }); + }, + TransactionList() { + axios.get("/json-example/admin_transaction_list.json").then((d) => { + console.log(d); + this.transactionlist = d.data; + + }, (error) => { + console.log(error); + }); + }, + UserList() { + axios.get("/json-example/admin_userlist.json").then((d) => { + console.log(d); + this.userlist = d.data; + + }, (error) => { + console.log(error); + }); + }, + CommunityStatistic() { + axios.get("/json-example/admin_community_statistic.json").then((d) => { + console.log(d); + this.communitystatistic = d.data; + + }, (error) => { + console.log(error); + }); + }, + ChartsStatistic() { + axios.get("/json-example/admin_charts_statistic.json").then((d) => { + console.log(d); + this.chartsstatistic = d.data; + + }, (error) => { + console.log(error); + }); + }, + CardStatistic() { + axios.get("/json-example/admin_card_statistic.json").then((d) => { + console.log(d); + this.cardstatistic = d.data; + + }, (error) => { + console.log(error); + }); + }, + StatisticDatas() { + axios.get("/json-example/admin_statisticdatas.json").then((d) => { + console.log(d); + this.userdata = d.data; + + }, (error) => { + console.log(error); + }); + }, initBigChart(index) { let chartData = { datasets: [ @@ -242,6 +367,12 @@ }, mounted() { this.initBigChart(0); + this.TransienceList(); + this.TransactionList(); + this.UserList(); + this.CommunityStatistic(); + this.ChartsStatistic(); + this.CardStatistic(); } } diff --git a/src/views/AdminOverview/AdminUserSearch.vue b/src/views/AdminOverview/AdminUserSearch.vue index d71ff0d61..cb3b5b9d8 100644 --- a/src/views/AdminOverview/AdminUserSearch.vue +++ b/src/views/AdminOverview/AdminUserSearch.vue @@ -81,7 +81,10 @@ - + + + + Name diff --git a/src/views/KontoOverview.vue b/src/views/KontoOverview.vue index 2b68f27d1..b568bf8f0 100644 --- a/src/views/KontoOverview.vue +++ b/src/views/KontoOverview.vue @@ -3,7 +3,7 @@ - + @@ -30,6 +30,29 @@ + + User Data + /public/json-example/userdata.json + + {{userdata}} + + + + User Transactions List + /public/json-example/usertransactions.json + + {{usertransactions}} + + + + + User Participation List + /public/json-example/userparticipation.json + + {{userparticipation}} + + + @@ -40,15 +63,69 @@ import GddTable from './KontoOverview/GddTable.vue'; import GddAddWork from './KontoOverview/GddAddWork.vue'; import GddWorkTable from './KontoOverview/GddWorkTable.vue'; + import axios from 'axios'; export default { + data(){ + return { + usertransactions: {}, + userdata: {}, + userparticipation: {} + } + }, components: { GddStatus, GddSent, GddTable, GddAddWork, - GddWorkTable - } + GddWorkTable, + axios + }, + methods: { + UserData() { + axios.get("/json-example/userdata.json").then((d) => { + console.log(d); + this.userdata = d.data; + + }, (error) => { + console.log(error); + }); + }, + UserTransactions() { + axios.get("/json-example/usertransactions.json").then((transactions) => { + console.log(transactions); + this.usertransactions = transactions.data; + + }, (error) => { + console.log(error); + }); + }, + UserParticitions() { + axios.get("/json-example/userparticipation.json").then((participation) => { + console.log(participation); + this.userparticipation = participation.data; + + }, (error) => { + console.log(error); + }); + } + }, + created() { + // Simple GET request using axios + // axios.get("https://api.npms.io/v2/search?q=vue").then((response) => { + // console.log(response); + // this.totalVuePackages = response.data.total; + // this.dataVuePackages = response.data; + // }, (error) => { + // console.log(error); + // }); + ///////////////////////// + }, + mounted() { + this.UserData(); + this.UserTransactions(); + this.UserParticitions(); + }, };
+ {{cardstatistic}} +
+ {{chartsstatistic}} +
+ {{communitystatistic}} +
+ {{userlist}} +
+ {{transactionlist}} +
+ {{transiencelist}} +
+ {{userdata}} +
+ {{usertransactions}} +
+ {{userparticipation}} +