Skip to content
Snippets Groups Projects
Commit 29e40281 authored by Mohammad Torkashvand's avatar Mohammad Torkashvand
Browse files

fix rendering issue

parent 384d5794
No related branches found
No related tags found
1 merge request!28added maps to the menu
Pipeline #87030 passed
...@@ -40,11 +40,11 @@ interface Iptrunk { ...@@ -40,11 +40,11 @@ interface Iptrunk {
iptrunk_sides: Array<{ iptrunk_side_node: IptrunkSideNode }>; iptrunk_sides: Array<{ iptrunk_side_node: IptrunkSideNode }>;
} }
export interface NetworkTopologyData { interface NetworkTopologyData {
iptrunks: Array<{ iptrunk: Iptrunk; insync: boolean }>; iptrunks: Array<{ iptrunk: Iptrunk; insync: boolean }>;
} }
export interface NetworkMapProps { interface NetworkMapProps {
data: NetworkTopologyData | null; data: NetworkTopologyData | null;
} }
......
import NetworkMap, { import NetworkMap from '@/components/NetworkMap/NetworkMap';
NetworkMapProps,
NetworkTopologyData,
} from '@/components/NetworkMap/NetworkMap';
import axios from 'axios'; import axios from 'axios';
import { NextPage, GetServerSideProps } from 'next'; import { NextPage, GetServerSideProps } from 'next';
import Head from 'next/head'; import Head from 'next/head';
import React from 'react'; import React from 'react';
const Maps: NextPage<NetworkMapProps> = ({ data }) => { interface IptrunkSideNode {
subscription_instance_id: string;
router_fqdn: string;
router_access_via_ts: boolean;
router_lo_ipv4_address: string;
router_lo_ipv6_address: string;
router_lo_iso_address: string;
router_role: string;
vendor: string;
router_site: {
site_internal_id: string;
site_name: string;
site_city: string;
site_country: string;
site_latitude: number;
site_longitude: number;
};
}
interface Iptrunk {
subscription_instance_id: string;
iptrunk_isis_metric: string;
iptrunk_capacity: string;
iptrunk_type: string;
iptrunk_ipv4_network: string;
iptrunk_ipv6_network: string;
iptrunk_sides: Array<{ iptrunk_side_node: IptrunkSideNode }>;
}
interface NetworkTopologyData {
iptrunks: Array<{ iptrunk: Iptrunk; insync: boolean }>;
}
interface MapsProps {
networkTopologyData: NetworkTopologyData;
}
const Maps: NextPage<MapsProps> = ({ networkTopologyData }) => {
return ( return (
<> <>
<Head> <Head>
<title>Maps</title> <title>Maps</title>
</Head> </Head>
<div> <div>
<NetworkMap data={data} /> <NetworkMap data={networkTopologyData} />
</div> </div>
</> </>
); );
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment