diff --git a/Linguard/Web/Pages/AddInterface.razor b/Linguard/Web/Pages/AddInterface.razor index 80d4100..e92e9bc 100644 --- a/Linguard/Web/Pages/AddInterface.razor +++ b/Linguard/Web/Pages/AddInterface.razor @@ -5,7 +5,6 @@ @using Linguard.Core.Services @using Linguard.Core.Managers @using Linguard.Core.Configuration -@using System.Net.NetworkInformation @using FluentValidation @using Linguard.Core.Models.Wireguard.Validators @using Linguard.Web.Services @@ -40,215 +39,15 @@

Configuration

- -
-
-
-
- -
-
-
-
- -
-
-
-
- -
-
-
-
- -
-
-
-
- -
-
-
-
- -
-
-
-
- - -
-
-
-
-
-
- -
-
-
-
- -
-
-
-
- -
-
-
-
- -
-
-
-
- -
-
-
-
-
-
- -
-
-
-
- -
-
-
-
- -
-
-
-
- -
-
-
-
- - - - - Total: @Iface.OnUp.Count - - - - - - - -
-
-
-
- @**@ - -
-
-
-
-
-
- -
-
-
-
- - - - - Total: @Iface.OnDown.Count - - - - - - - -
-
-
-
- @**@ - -
-
-
-
- -
-
- - -
-
- -
-
- -
-
+
- @code { RadzenDataGrid _onUpGrid; RadzenDataGrid _onDownGrid; - - IEnumerable InterfaceNames => NetworkInterface.GetAllNetworkInterfaces() - .Select(i => i.Name) - //.Concat(Configuration.Interfaces.Select(i => i.Name)) - //.Distinct() - .OrderBy(n => n); - - void OnGatewayChanged(object gatewayName) { - Iface!.Gateway = NetworkInterface.GetAllNetworkInterfaces() - .SingleOrDefault(i => i.Name.Equals(gatewayName))!; - } - + void Submit(Interface iface) { var result = _validator.Validate(iface); if (result.IsValid) { diff --git a/Linguard/Web/Pages/EditClient.razor b/Linguard/Web/Pages/EditClient.razor index 00bb48c..030d10e 100644 --- a/Linguard/Web/Pages/EditClient.razor +++ b/Linguard/Web/Pages/EditClient.razor @@ -3,7 +3,7 @@ @using Linguard.Core.Managers @using Linguard.Core.Models.Wireguard @using Linguard.Core.Services -@using Linguard.Core.Configuration +@using Linguard.Core.Configuration @using FluentValidation @inject IConfigurationManager _configurationManager @@ -33,7 +33,6 @@ } - diff --git a/Linguard/Web/Pages/EditInterface.razor b/Linguard/Web/Pages/EditInterface.razor index 12b60e5..91e313c 100644 --- a/Linguard/Web/Pages/EditInterface.razor +++ b/Linguard/Web/Pages/EditInterface.razor @@ -4,7 +4,6 @@ @using Linguard.Core.Services @using Linguard.Core.Managers @using Linguard.Core.Configuration -@using System.Net.NetworkInformation @using FluentValidation @using Linguard.Web.Services @@ -162,13 +161,7 @@ break; } } - - IEnumerable InterfaceNames => NetworkInterface.GetAllNetworkInterfaces() - .Select(i => i.Name) - //.Concat(Configuration.Interfaces.Select(i => i.Name)) - //.Distinct() - .OrderBy(n => n); - + RadzenDataGrid _clientsGrid; void AddClient() { diff --git a/Linguard/Web/Web.csproj b/Linguard/Web/Web.csproj index 94c53a4..314874a 100644 --- a/Linguard/Web/Web.csproj +++ b/Linguard/Web/Web.csproj @@ -36,8 +36,4 @@ <_ContentIncludedByDefault Remove="wwwroot\ts\helper.ts" /> - - - -