Allow admins to view account websites.

This commit is contained in:
Mike Cao 2020-09-10 23:55:29 -07:00
parent cb14b8bbda
commit 5a22be5efa
19 changed files with 57 additions and 35 deletions

View file

@ -0,0 +1,22 @@
import React from 'react';
import { useRouter } from 'next/router';
import Layout from 'components/layout/Layout';
import WebsiteList from 'components/WebsiteList';
import useRequireLogin from 'hooks/useRequireLogin';
export default function DashboardPage() {
const { loading } = useRequireLogin();
const router = useRouter();
const { id } = router.query;
const userId = id?.[0];
if (loading) {
return null;
}
return (
<Layout>
<WebsiteList userId={userId} />
</Layout>
);
}