mirror of
https://github.com/Telecominfraproject/wlan-cloud-ui.git
synced 2025-10-30 18:27:58 +00:00
added radioTypes constant
This commit is contained in:
@@ -1,7 +1,12 @@
|
|||||||
export const AUTH_TOKEN = 'tip-auth-token';
|
export const AUTH_TOKEN = 'tip-auth-token';
|
||||||
export const COMPANY = 'Telecom Infra Project';
|
export const COMPANY = 'Telecom Infra Project';
|
||||||
export const IS_RADIO_TYPE_5GHZ = 'is5GHz';
|
|
||||||
export const IS_RADIO_TYPE_2DOT4GHZ = 'is2dot4GHz';
|
export const USER_FRIENDLY_RADIOS = {
|
||||||
|
is2dot4GHz: '2.4GHz',
|
||||||
|
is5GHzL: '5GHz (L)',
|
||||||
|
is5GHzU: '5GHz (U)',
|
||||||
|
is5GHz: '5GHz',
|
||||||
|
};
|
||||||
|
|
||||||
export const ROUTES = {
|
export const ROUTES = {
|
||||||
root: '/',
|
root: '/',
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import { ThemeProvider, GenericNotFound } from '@tip-wlan/wlan-cloud-ui-library'
|
|||||||
import logo from 'images/tip-logo.png';
|
import logo from 'images/tip-logo.png';
|
||||||
import logoMobile from 'images/tip-logo-mobile.png';
|
import logoMobile from 'images/tip-logo-mobile.png';
|
||||||
|
|
||||||
import { AUTH_TOKEN, COMPANY, ROUTES } from 'constants/index';
|
import { AUTH_TOKEN, COMPANY, ROUTES, USER_FRIENDLY_RADIOS } from 'constants/index';
|
||||||
import Login from 'containers/Login';
|
import Login from 'containers/Login';
|
||||||
|
|
||||||
import Network from 'containers/Network';
|
import Network from 'containers/Network';
|
||||||
@@ -65,7 +65,13 @@ const App = () => {
|
|||||||
updateUser={updateUser}
|
updateUser={updateUser}
|
||||||
updateToken={updateToken}
|
updateToken={updateToken}
|
||||||
>
|
>
|
||||||
<ThemeProvider company={COMPANY} logo={logo} logoMobile={logoMobile} routes={ROUTES}>
|
<ThemeProvider
|
||||||
|
company={COMPANY}
|
||||||
|
logo={logo}
|
||||||
|
logoMobile={logoMobile}
|
||||||
|
routes={ROUTES}
|
||||||
|
radioTypes={USER_FRIENDLY_RADIOS}
|
||||||
|
>
|
||||||
<Helmet titleTemplate={`%s - ${COMPANY}`} defaultTitle={COMPANY}>
|
<Helmet titleTemplate={`%s - ${COMPANY}`} defaultTitle={COMPANY}>
|
||||||
<meta name="description" content={COMPANY} />
|
<meta name="description" content={COMPANY} />
|
||||||
</Helmet>
|
</Helmet>
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import { useQuery } from '@apollo/client';
|
|||||||
import { Dashboard as DashboardPage, Loading } from '@tip-wlan/wlan-cloud-ui-library';
|
import { Dashboard as DashboardPage, Loading } from '@tip-wlan/wlan-cloud-ui-library';
|
||||||
import UserContext from 'contexts/UserContext';
|
import UserContext from 'contexts/UserContext';
|
||||||
import { FILTER_SYSTEM_EVENTS, GET_ALL_STATUS } from 'graphql/queries';
|
import { FILTER_SYSTEM_EVENTS, GET_ALL_STATUS } from 'graphql/queries';
|
||||||
|
import { USER_FRIENDLY_RADIOS } from 'constants/index';
|
||||||
|
|
||||||
function formatBytes(bytes, decimals = 2) {
|
function formatBytes(bytes, decimals = 2) {
|
||||||
if (bytes === 0) return '0 Bytes';
|
if (bytes === 0) return '0 Bytes';
|
||||||
@@ -29,13 +30,6 @@ function trafficTooltipFormatter() {
|
|||||||
)}</b><br/>`;
|
)}</b><br/>`;
|
||||||
}
|
}
|
||||||
|
|
||||||
const USER_FRIENDLY_RADIOS = {
|
|
||||||
is2dot4GHz: '2.4GHz',
|
|
||||||
is5GHzL: '5GHz (L)',
|
|
||||||
is5GHzU: '5GHz (U)',
|
|
||||||
is5GHz: '5GHz',
|
|
||||||
};
|
|
||||||
|
|
||||||
const lineChartConfig = [
|
const lineChartConfig = [
|
||||||
{ key: 'inservicesAPs', title: 'Inservice APs (24 hours)' },
|
{ key: 'inservicesAPs', title: 'Inservice APs (24 hours)' },
|
||||||
{ key: 'clientDevices', title: 'Client Devices (24 hours)' },
|
{ key: 'clientDevices', title: 'Client Devices (24 hours)' },
|
||||||
|
|||||||
Reference in New Issue
Block a user