[WIFI-11542] AP Scripts

Signed-off-by: Charles <charles.bourque96@gmail.com>
This commit is contained in:
Charles
2022-12-01 16:12:30 +00:00
parent d01453ea1d
commit 21452d091f
80 changed files with 3202 additions and 937 deletions

View File

@@ -1,6 +1,6 @@
import React from 'react';
import { Icon } from '@chakra-ui/react';
import { Barcode, FloppyDisk, Info, ListBullets, UsersThree, WifiHigh } from 'phosphor-react';
import { Barcode, FloppyDisk, Info, ListBullets, TerminalWindow, UsersThree, WifiHigh } from 'phosphor-react';
import { Route } from 'models/Routes';
const DefaultConfigurationsPage = React.lazy(() => import('pages/DefaultConfigurations'));
@@ -9,6 +9,7 @@ const DevicesPage = React.lazy(() => import('pages/Devices'));
const FirmwarePage = React.lazy(() => import('pages/Firmware'));
const NotificationsPage = React.lazy(() => import('pages/Notifications'));
const ProfilePage = React.lazy(() => import('pages/Profile'));
const ScriptsPage = React.lazy(() => import('pages/Scripts'));
const SystemPage = React.lazy(() => import('pages/SystemPage'));
const UsersPage = React.lazy(() => import('pages/UsersPage'));
@@ -31,6 +32,15 @@ const routes: Route[] = [
),
component: FirmwarePage,
},
{
authorized: ['root'],
path: '/scripts/:id',
name: 'script.other',
icon: (active: boolean) => (
<Icon as={TerminalWindow} color="inherit" h={active ? '32px' : '24px'} w={active ? '32px' : '24px'} />
),
component: ScriptsPage,
},
{
authorized: ['root', 'partner', 'admin', 'csr', 'system'],
path: '/configurations',