remove unnecessary assosiation. add /index.html route to main page

This commit is contained in:
Dmitriynj
2020-12-03 23:57:45 +03:00
committed by Daniel Hutzel
parent 1dd1863266
commit 09dd526f22
2 changed files with 5 additions and 16 deletions

View File

@@ -12,15 +12,6 @@ import Login from './Login';
import { withRestrictions } from '../hocs/withRestrictions'; import { withRestrictions } from '../hocs/withRestrictions';
import { requireEmployee } from '../util/constants'; import { requireEmployee } from '../util/constants';
// const TracksContainer = React.lazy(() => import('./TracksPage'));
// const Header = React.lazy(() => import('./Header'));
// const PersonPage = React.lazy(() => import('./PersonPage'));
// const ErrorPage = React.lazy(() => import('./ErrorPage'));
// const InvoicePage = React.lazy(() => import('./InvoicePage'));
// const ManageStore = React.lazy(() => import('./ManageStore'));
// const MyInvoicesPage = React.lazy(() => import('./MyInvoicesPage'));
// const Login = React.lazy(() => import('./Login'));
const RestrictedLogin = withRestrictions(Login, ({ user }) => !user); const RestrictedLogin = withRestrictions(Login, ({ user }) => !user);
const RestrictedInvoicePage = withRestrictions( const RestrictedInvoicePage = withRestrictions(
InvoicePage, InvoicePage,
@@ -36,7 +27,7 @@ const MyRouter = () => {
<div style={{ padding: '2em 20vh' }}> <div style={{ padding: '2em 20vh' }}>
<React.Suspense fallback={<div>Loading...</div>}> <React.Suspense fallback={<div>Loading...</div>}>
<Switch> <Switch>
<Route exact path={['/', '/tracks']}> <Route exact path={['/index.html', '/tracks', '/']}>
<TracksContainer /> <TracksContainer />
</Route> </Route>
<Route exact path="/person"> <Route exact path="/person">

View File

@@ -42,12 +42,10 @@ entity Albums {
} }
entity Employees : Person { entity Employees : Person {
reportsTo : Association to Employees; reportsTo : Association to Employees;
title : String(20); title : String(20);
birthDate : DateTime; birthDate : DateTime;
hireDate : DateTime; hireDate : DateTime;
subordinates : Association to many Employees
on subordinates.reportsTo = $self;
} }
entity Customers : Person { entity Customers : Person {