diff --git a/Oqtane.Client/Modules/Admin/Users/Index.razor b/Oqtane.Client/Modules/Admin/Users/Index.razor
index a9d4366f..cf180d73 100644
--- a/Oqtane.Client/Modules/Admin/Users/Index.razor
+++ b/Oqtane.Client/Modules/Admin/Users/Index.razor
@@ -9,7 +9,11 @@
}
else
{
-
+
+
+
+
+
@@ -28,16 +32,32 @@ else
}
@code {
+ private List allroles;
private List userroles;
+ private string search;
public override SecurityAccessLevel SecurityAccessLevel => SecurityAccessLevel.Admin;
protected override async Task OnInitializedAsync()
{
- userroles = await UserRoleService.GetUserRolesAsync(PageState.Site.SiteId);
- userroles = userroles.Where(item => item.Role.Name == Constants.RegisteredRole).ToList();
+ allroles = await UserRoleService.GetUserRolesAsync(PageState.Site.SiteId);
+ userroles = allroles.Where(item => item.Role.Name == Constants.RegisteredRole).ToList();
}
+ private void OnSearch()
+ {
+ userroles = allroles
+ .Where(item => item.Role.Name == Constants.RegisteredRole &&
+ (
+ item.User.Username.Contains(search, StringComparison.OrdinalIgnoreCase) ||
+ item.User.Email.Contains(search, StringComparison.OrdinalIgnoreCase) ||
+ item.User.DisplayName.Contains(search, StringComparison.OrdinalIgnoreCase)
+ )
+ )
+ .ToList();
+ }
+
+
private async Task DeleteUser(UserRole UserRole)
{
try
@@ -56,4 +76,4 @@ else
AddModuleMessage(ex.Message, MessageType.Error);
}
}
-}
\ No newline at end of file
+}
diff --git a/Oqtane.Client/Oqtane.Client.csproj b/Oqtane.Client/Oqtane.Client.csproj
index a551efc9..a712520f 100644
--- a/Oqtane.Client/Oqtane.Client.csproj
+++ b/Oqtane.Client/Oqtane.Client.csproj
@@ -17,6 +17,7 @@
Git
Not for production use.
Oqtane
+ true
@@ -37,5 +38,4 @@
-
diff --git a/Oqtane.Package/release.cmd b/Oqtane.Package/release.cmd
index fef9bc80..34df2891 100644
--- a/Oqtane.Package/release.cmd
+++ b/Oqtane.Package/release.cmd
@@ -1,6 +1,5 @@
DEL "*.nupkg"
-nuget.exe pack Oqtane.Framework.nuspec
-nuget.exe pack Oqtane.Client.nuspec
-nuget.exe pack Oqtane.Server.nuspec
-nuget.exe pack Oqtane.Shared.nuspec
-
\ No newline at end of file
+dotnet clean -c Release ..\Oqtane.sln
+dotnet build -c Release ..\Oqtane.sln
+dotnet pack -o .\ -c Release ..\Oqtane.sln
+nuget.exe pack Oqtane.Framework.nuspec
diff --git a/Oqtane.Server/Controllers/AliasController.cs b/Oqtane.Server/Controllers/AliasController.cs
index 0bbdde97..c4422587 100644
--- a/Oqtane.Server/Controllers/AliasController.cs
+++ b/Oqtane.Server/Controllers/AliasController.cs
@@ -47,7 +47,7 @@ namespace Oqtane.Controllers
}
// GET api//name/xxx?sync=yyyyMMddHHmmssfff
- [HttpGet("name/{name}")]
+ [HttpGet("name/{**name}")]
public Alias Get(string name, string sync)
{
List aliases = _aliases.GetAliases().ToList(); // cached
diff --git a/Oqtane.Server/Oqtane.Server.csproj b/Oqtane.Server/Oqtane.Server.csproj
index a26ff88e..ccc27cd2 100644
--- a/Oqtane.Server/Oqtane.Server.csproj
+++ b/Oqtane.Server/Oqtane.Server.csproj
@@ -15,6 +15,7 @@
Git
Not for production use.
Oqtane
+ true
@@ -43,4 +44,4 @@
-
\ No newline at end of file
+
diff --git a/Oqtane.Shared/Shared/Utilities.cs b/Oqtane.Shared/Shared/Utilities.cs
index de81561b..04f3ea1e 100644
--- a/Oqtane.Shared/Shared/Utilities.cs
+++ b/Oqtane.Shared/Shared/Utilities.cs
@@ -1,5 +1,6 @@
using Oqtane.Models;
using System;
+using System.Collections.Generic;
using System.Globalization;
using System.IO;
using System.Linq;
@@ -15,7 +16,7 @@ namespace Oqtane.Shared
{
if (type == null) return null;
var assemblyFullName = type.Assembly.FullName;
- var assemblyName = assemblyFullName.Substring(0, assemblyFullName.IndexOf(",", StringComparison.Ordinal));
+ var assemblyName = assemblyFullName.Substring(0, assemblyFullName.IndexOf(",", StringComparison.Ordinal));
return $"{type.Namespace}, {assemblyName}";
}
@@ -24,10 +25,10 @@ namespace Oqtane.Shared
var uriBuilder = new UriBuilder
{
Path = !string.IsNullOrEmpty(alias)
- ? (!string.IsNullOrEmpty(path))
- ? $"{alias}/{path}"
- : $"{alias}"
- : $"{path}",
+ ? (!string.IsNullOrEmpty(path))
+ ? $"{alias}/{path}"
+ : $"{alias}"
+ : $"{path}",
Query = parameters
};
@@ -44,6 +45,7 @@ namespace Oqtane.Shared
path += $"/{action}";
}
}
+
return NavigateUrl(alias, path, parameters);
}
@@ -98,6 +100,7 @@ namespace Oqtane.Shared
// remove assembly if fully qualified type
typename = typename.Substring(0, typename.IndexOf(","));
}
+
// segment 0 is the last segment, segment 1 is the second to last segment, etc...
string[] segments = typename.Split('.');
string name = "";
@@ -105,6 +108,7 @@ namespace Oqtane.Shared
{
name = segments[segments.Length - (segment + 1)];
}
+
return name;
}
@@ -142,11 +146,14 @@ namespace Oqtane.Shared
stringBuilder.Append('-');
prevdash = true;
}
+
break;
}
}
+
result = stringBuilder.ToString().Trim('-');
}
+
return result;
}
@@ -236,25 +243,28 @@ namespace Oqtane.Shared
if (string.IsNullOrEmpty(email)) return false;
return Regex.IsMatch(email,
- @"^(?("")("".+?(? ParseQueryString(string query)
+ {
+ Dictionary dictionary = new Dictionary();
+ if (!string.IsNullOrEmpty(query))
+ {
+ query = query.Substring(1);
+ string str = query;
+ char[] separator = new char[1] {'&'};
+ foreach (string key in str.Split(separator, StringSplitOptions.RemoveEmptyEntries))
+ {
+ if (key != "")
+ {
+ if (key.Contains("="))
+ {
+ string[] strArray = key.Split('=', StringSplitOptions.None);
+ dictionary.Add(strArray[0], strArray[1]);
+ }
+ else
+ dictionary.Add(key, "true");
+ }
+ }
+ }
+
+ return dictionary;
+ }
}
}
diff --git a/Oqtane.Upgrade/Oqtane.Upgrade.csproj b/Oqtane.Upgrade/Oqtane.Upgrade.csproj
index b4d55166..587d5a9d 100644
--- a/Oqtane.Upgrade/Oqtane.Upgrade.csproj
+++ b/Oqtane.Upgrade/Oqtane.Upgrade.csproj
@@ -15,6 +15,7 @@
Git
Not for production use.
Oqtane
+ false