浏览代码

Add admin users page

sbkwgh 7 年之前
父节点
当前提交
6d455b3cfb
共有 3 个文件被更改,包括 31 次插入0 次删除
  1. 6 0
      frontend/src/components/routes/Admin.vue
  2. 23 0
      frontend/src/components/routes/AdminUsers.vue
  3. 2 0
      frontend/src/main.js

+ 6 - 0
frontend/src/components/routes/Admin.vue

@@ -49,6 +49,12 @@
 						description: 'View and respond to user reports',
 						icon: 'fa-exclamation-circle'
 					},
+					{
+						title: 'Users',
+						route: 'users',
+						description: 'View current user accounts',
+						icon: 'fa-user-circle'
+					}
 				]
 			}
 		},

+ 23 - 0
frontend/src/components/routes/AdminUsers.vue

@@ -0,0 +1,23 @@
+<template>
+	<div class='admin_general'>
+		<h1 class='admin_general__header'>Users</h1>
+	</div>
+</template>
+
+<script>
+	export default {
+		name: 'AdminUsers'
+	}
+</script>
+
+<style lang='scss' scoped>
+	@import '../../assets/scss/variables.scss';
+
+	.admin_general {
+		padding: 1rem 2rem;
+
+		@at-root #{&}__header {
+			margin: 0.5rem 0 1rem 0;
+		}
+	}
+</style>

+ 2 - 0
frontend/src/main.js

@@ -50,6 +50,7 @@ const AdminDashboard = () => import('./components/routes/AdminDashboard')
 const AdminModerationReports = () => import('./components/routes/AdminModerationReports')
 const AdminModerationBannedUsers = () => import('./components/routes/AdminModerationBannedUsers')
 const AdminGeneral = () => import('./components/routes/AdminGeneral')
+const AdminUsers = () => import('./components/routes/AdminUsers')
 
 import NotFound from './components/routes/NotFound'
 
@@ -79,6 +80,7 @@ const router = new VueRouter({
 		{ path: '/admin', redirect: '/admin/dashboard', component: Admin, children: [
 			{ path: 'dashboard', component: AdminDashboard },
 			{ path: 'general', component: AdminGeneral },
+			{ path: 'users', component: AdminUsers },
 			{ path: 'moderation', redirect: '/admin/moderation/reports' },
 			{ path: 'moderation/reports', component: AdminModerationReports },
 			{ path: 'moderation/bans', component: AdminModerationBannedUsers }