diff --git a/src/DotNetCore.CAP/Dashboard/Pages/NodePage.cs b/src/DotNetCore.CAP/Dashboard/Pages/NodePage.cs index 5f0bd7d..ec5fb01 100644 --- a/src/DotNetCore.CAP/Dashboard/Pages/NodePage.cs +++ b/src/DotNetCore.CAP/Dashboard/Pages/NodePage.cs @@ -15,13 +15,12 @@ namespace DotNetCore.CAP.Dashboard.Pages { if (_nodes == null) { - var configOptions = RequestServices.GetService(); - var discoveryServer = configOptions.Discovery; - if (discoveryServer == null) - return null; + var configOptions = RequestServices.GetService(); var factory = RequestServices.GetService(); - var discoryProvider = factory.Get(discoveryServer); + + var discoryProvider = factory.Create(configOptions); + _nodes = discoryProvider.GetNodes().GetAwaiter().GetResult(); } return _nodes; diff --git a/src/DotNetCore.CAP/Dashboard/Pages/NodePage.cshtml b/src/DotNetCore.CAP/Dashboard/Pages/NodePage.cshtml index d9bdb80..182f30f 100644 --- a/src/DotNetCore.CAP/Dashboard/Pages/NodePage.cshtml +++ b/src/DotNetCore.CAP/Dashboard/Pages/NodePage.cshtml @@ -24,6 +24,7 @@ 节点名称 IP地址 + 端口号 Tags 操作 @@ -34,8 +35,9 @@ @node.Name @node.Address - - 切换到 + @node.Port + @node.Tags + 切换到 } diff --git a/src/DotNetCore.CAP/Dashboard/Pages/NodePage.generated.cs b/src/DotNetCore.CAP/Dashboard/Pages/NodePage1.generated.cs similarity index 77% rename from src/DotNetCore.CAP/Dashboard/Pages/NodePage.generated.cs rename to src/DotNetCore.CAP/Dashboard/Pages/NodePage1.generated.cs index f765830..e292000 100644 --- a/src/DotNetCore.CAP/Dashboard/Pages/NodePage.generated.cs +++ b/src/DotNetCore.CAP/Dashboard/Pages/NodePage1.generated.cs @@ -106,8 +106,11 @@ WriteLiteral(@"
- - + + + + + @@ -115,7 +118,7 @@ WriteLiteral(@"
- #line 30 "..\..\Dashboard\Pages\NodePage.cshtml" + #line 33 "..\..\Dashboard\Pages\NodePage.cshtml" foreach (var node in Nodes) { @@ -126,7 +129,7 @@ WriteLiteral("
\r\n - #line 33 "..\..\Dashboard\Pages\NodePage.cshtml" + #line 36 "..\..\Dashboard\Pages\NodePage.cshtml" Write(node.Name); @@ -136,17 +139,38 @@ WriteLiteral("\r\n \r\n \r\n"); +WriteLiteral("\r\n \r\n \r\n \r\n " + +" \r\n"); + + + + #line 42 "..\..\Dashboard\Pages\NodePage.cshtml" } @@ -156,7 +180,7 @@ WriteLiteral(" \r\n
节点名称IP地址节点名称IP地址端口号Tags操作
"); - #line 34 "..\..\Dashboard\Pages\NodePage.cshtml" + #line 37 "..\..\Dashboard\Pages\NodePage.cshtml" Write(node.Address); #line default #line hidden -WriteLiteral("
"); - #line 36 "..\..\Dashboard\Pages\NodePage.cshtml" + #line 38 "..\..\Dashboard\Pages\NodePage.cshtml" + Write(node.Port); + + + #line default + #line hidden +WriteLiteral(""); + + + + #line 39 "..\..\Dashboard\Pages\NodePage.cshtml" + Write(node.Tags); + + + #line default + #line hidden +WriteLiteral("切换到
\r\n - #line 40 "..\..\Dashboard\Pages\NodePage.cshtml" + #line 46 "..\..\Dashboard\Pages\NodePage.cshtml" } diff --git a/src/DotNetCore.CAP/Dashboard/Pages/SubscriberPage.cshtml b/src/DotNetCore.CAP/Dashboard/Pages/SubscriberPage.cshtml index b5ae287..beffd68 100644 --- a/src/DotNetCore.CAP/Dashboard/Pages/SubscriberPage.cshtml +++ b/src/DotNetCore.CAP/Dashboard/Pages/SubscriberPage.cshtml @@ -38,12 +38,13 @@ @foreach (var subscriber in subscribers) { var i = 0; + var rowCount = subscriber.Value.Count; @foreach (var column in subscriber.Value) { @if (i == 0) { - @subscriber.Key + @subscriber.Key } @column.Attribute.Name diff --git a/src/DotNetCore.CAP/Dashboard/Pages/SubscriberPage.generated.cs b/src/DotNetCore.CAP/Dashboard/Pages/SubscriberPage.generated.cs index 2936e76..9e1aa78 100644 --- a/src/DotNetCore.CAP/Dashboard/Pages/SubscriberPage.generated.cs +++ b/src/DotNetCore.CAP/Dashboard/Pages/SubscriberPage.generated.cs @@ -155,12 +155,13 @@ WriteLiteral("\r\n \r\n \r\n"); - #line 44 "..\..\Dashboard\Pages\SubscriberPage.cshtml" + #line 45 "..\..\Dashboard\Pages\SubscriberPage.cshtml" if (i == 0) { @@ -182,8 +183,8 @@ WriteLiteral(" "); - #line 46 "..\..\Dashboard\Pages\SubscriberPage.cshtml" - Write(subscriber.Key); + #line 47 "..\..\Dashboard\Pages\SubscriberPage.cshtml" + Write(subscriber.Key); #line default @@ -202,7 +203,7 @@ WriteLiteral("\r\n"); - #line 47 "..\..\Dashboard\Pages\SubscriberPage.cshtml" + #line 48 "..\..\Dashboard\Pages\SubscriberPage.cshtml" } @@ -212,7 +213,7 @@ WriteLiteral(" "); - #line 48 "..\..\Dashboard\Pages\SubscriberPage.cshtml" + #line 49 "..\..\Dashboard\Pages\SubscriberPage.cshtml" Write(column.Attribute.Name); @@ -223,7 +224,7 @@ WriteLiteral("\r\n \r\n - #line 50 "..\..\Dashboard\Pages\SubscriberPage.cshtml" + #line 51 "..\..\Dashboard\Pages\SubscriberPage.cshtml" Write(column.ImplTypeInfo.Name); @@ -235,7 +236,7 @@ WriteLiteral(":\r\n
\r\n \r\n - #line 58 "..\..\Dashboard\Pages\SubscriberPage.cshtml" + #line 59 "..\..\Dashboard\Pages\SubscriberPage.cshtml" i++; } } @@ -260,7 +261,7 @@ WriteLiteral(" \r\n \r\n - #line 64 "..\..\Dashboard\Pages\SubscriberPage.cshtml" + #line 65 "..\..\Dashboard\Pages\SubscriberPage.cshtml" }