summaryrefslogtreecommitdiffstats
path: root/luci-app-bmx6/files/usr/lib/lua/luci/view/bmx6/neighbours.htm
blob: 64741164aada8dd3eb9bfc56b637d44064f7b209 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
<%+header%>
<style type="text/css">

    table {
       width:90%;
       border-top:1px solid #e5eaf8;
       border-right:1px solid #e5eaf8;
       margin:1em auto;
       border-collapse:collapse;
     }

    td {
       color:#678197;
       border-bottom:1px solid #e6eff8;
       border-left:1px solid #e6eff8;
       padding:.3em 1em;
       text-align:center;
     }
    th {
       background:#f4f9fe;
       text-align:center;
       font:bold 1.2em/2em "Century Gothic","Trebuchet MS",Arial,Helvetica,sans-serif;
       color:#66a3d3;
     }


#neighbour {
	position:relative;
	margin:5px;
}

#orig_id {
	background-color: black;
	color: white;
	text-ident:10px;
}
</style>

<h2><a id="content" name="content"><%:Neighbours%></a></h2>
<table>
 <tr>
  <th scope="col">Name</th>
  <th scope="col">IPv4</th>
  <th scope="col">IPv6</th>
  <th scope="col">Via Dev</th>
  <th scope="col">Via IP</th>
  <th scope="col">Routes</th>
  <th scope="col">Metric</th>
  <th scope="col">Last Desc</th>
  <th scope="col">Last Ref</th>
 </tr>

<% for i,o in ipairs(originators) do %>
		<tr>
		<td><%=o.name%></td>
		<td><a href="http://<%=o.ipv4%>"><%=o.ipv4%></a></td>
		<td><a href="http://[<%=o.orig.primaryIp%>]"><%=o.orig.primaryIp%></a></td>
		<td><%=o.orig.viaDev%></td>
		<td><%=o.orig.viaIp%></td>
		<td><%=o.orig.routes%></td>
		<td><%=o.orig.metric%></td>
		<td><%=o.orig.lastDesc%></td>
		<td><%=o.orig.lastRef%></td>
		</tr>
<%end%>
</table>

<table>
 <tr>
 <th scope="col">Node</th>
 <th scope="col">Announced networks</th>
 </tr>

<% for i,o in ipairs(originators) do %>
	<tr>
	 <td><%=o.name%></td>
	 <td style="text-align:left;">
	<% if o.desc.DESC_ADV ~= nil then %>
	<% for j,h in ipairs(o.desc.DESC_ADV.extensions[2].HNA6_EXTENSION) do %>
	  <%=h.address%>&nbsp;&nbsp;&nbsp;&nbsp;
	<% end %>
	<% end %>
	 </td>
	</tr>
<% end %>
</table>

<br />
<%+footer%>