From 67286e106f2af32d0dd0588e6ce65e903f0b6820 Mon Sep 17 00:00:00 2001 From: Kekskurse Date: Tue, 26 Nov 2019 17:30:03 +0100 Subject: [PATCH] YoLo --- src/components/Menu2.vue | 4 +- src/router/index.js | 23 ++++++++ src/services/Admin.js | 9 +++ src/views/admin/App.vue | 49 ++++++++++++++++ src/views/admin/AppDetail.vue | 107 ++++++++++++++++++++++++++++++++++ src/views/admin/Invite.vue | 63 ++++++++++++++++++++ 6 files changed, 253 insertions(+), 2 deletions(-) create mode 100644 src/views/admin/App.vue create mode 100644 src/views/admin/AppDetail.vue create mode 100644 src/views/admin/Invite.vue diff --git a/src/components/Menu2.vue b/src/components/Menu2.vue index fdba853f..ccfb2839 100644 --- a/src/components/Menu2.vue +++ b/src/components/Menu2.vue @@ -78,10 +78,10 @@ User - + Apps - + Invites diff --git a/src/router/index.js b/src/router/index.js index ce6bbd3e..11ee0aee 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -17,6 +17,9 @@ import Profile from '../views/Profile' import AdminSettings from '../views/admin/Settings' import AdminUserList from '../views/admin/User' import AdminUserEdit from '../views/admin/UserEdit' +import AdminAppsList from '../views/admin/App' +import AdminAppDetails from '../views/admin/AppDetail' +import AdminInvite from '../views/admin/Invite' Vue.use(Router) @@ -125,5 +128,25 @@ export default new Router({ name: 'adminUserEdit', component: AdminUserEdit }, + { + beforeEnter: admin, + path: '/admin/app', + name: 'adminListApp', + component: AdminAppsList + }, + { + beforeEnter: admin, + path: '/admin/app/:id', + name: 'adminAppDetail', + component: AdminAppDetails + }, + { + beforeEnter: admin, + path: '/admin/invite', + name: 'adminInvite', + component: AdminInvite + }, + + ] }) diff --git a/src/services/Admin.js b/src/services/Admin.js index a0d54eef..7a4963fe 100644 --- a/src/services/Admin.js +++ b/src/services/Admin.js @@ -18,5 +18,14 @@ export default { }, validateMail(id) { return Api().put("/v1/admin/mail/"+id+"/status", {"status": "valide"}); + }, + getAppList() { + return Api().get("/v1/admin/app"); + }, + saveAppProperties(id, properties) { + return Api().put("/v1/admin/app/"+id+"/properties", properties); + }, + listInvites() { + return Api().get("/v1/admin/invite"); } } diff --git a/src/views/admin/App.vue b/src/views/admin/App.vue new file mode 100644 index 00000000..366d194e --- /dev/null +++ b/src/views/admin/App.vue @@ -0,0 +1,49 @@ + + + + diff --git a/src/views/admin/AppDetail.vue b/src/views/admin/AppDetail.vue new file mode 100644 index 00000000..67c80565 --- /dev/null +++ b/src/views/admin/AppDetail.vue @@ -0,0 +1,107 @@ + + + + diff --git a/src/views/admin/Invite.vue b/src/views/admin/Invite.vue new file mode 100644 index 00000000..cf8605db --- /dev/null +++ b/src/views/admin/Invite.vue @@ -0,0 +1,63 @@ + + + +