This commit is contained in:
2248356998 qq.com
2025-07-13 22:47:14 +08:00
parent 9bb9cd7419
commit f11b7f7ab4
281 changed files with 427 additions and 1630 deletions

View File

@@ -20,7 +20,6 @@ using System.Collections.Concurrent;
using ThingsGateway.Extension;
using ThingsGateway.FriendlyException;
using ThingsGateway.NewLife.Json.Extension;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;

View File

@@ -8,12 +8,8 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using System.ComponentModel.DataAnnotations;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;
[SugarTable("sys_dict", TableDescription = "字典表")]

View File

@@ -8,10 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,12 +8,8 @@
// QQ群605534569
// ------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using System.ComponentModel.DataAnnotations;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,11 +8,9 @@
// QQ群605534569
// ------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using System.ComponentModel.DataAnnotations;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,16 +8,12 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using Microsoft.AspNetCore.Components.Routing;
using Newtonsoft.Json;
using System.ComponentModel.DataAnnotations;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,12 +8,8 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using System.ComponentModel.DataAnnotations;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,14 +8,9 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using Riok.Mapperly.Abstractions;
using System.ComponentModel.DataAnnotations;
using System.Diagnostics.CodeAnalysis;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;

View File

@@ -8,10 +8,7 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.List;
using ThingsGateway.SqlSugar;
using ThingsGateway.Common.List;
namespace ThingsGateway.Admin.Application;

View File

@@ -79,7 +79,7 @@ public class RequestAuditFilter : IAsyncActionFilter, IOrderedFilter
logData.TimeOperationElapsedMilliseconds = timeOperation.ElapsedMilliseconds;
var resultHttpContext = (resultContext as FilterContext).HttpContext;
var resultHttpContext = (resultContext as Microsoft.AspNetCore.Mvc.Filters.FilterContext).HttpContext;
// 获取 HttpContext 和 HttpRequest 对象
var httpContext = context.HttpContext;

View File

@@ -8,4 +8,15 @@
// QQ群605534569
//------------------------------------------------------------------------------
global using ThingsGateway.NewLife.Extension;
global using BootstrapBlazor.Components;
global using Microsoft.Extensions.Localization;
global using Microsoft.Extensions.Options;
global using System.Diagnostics.CodeAnalysis;
global using System.Globalization;
global using ThingsGateway.Common;
global using ThingsGateway.DB;
global using ThingsGateway.NewLife.Extension;
global using ThingsGateway.SqlSugar;

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.NewLife;
namespace ThingsGateway.Admin.Application;

View File

@@ -9,9 +9,7 @@
// ------------------------------------------------------------------------------
using Microsoft.Extensions.Hosting;
using Microsoft.Extensions.Localization;
using Microsoft.Extensions.Logging;
using Microsoft.Extensions.Options;
using System.Runtime.InteropServices;
@@ -20,7 +18,6 @@ using ThingsGateway.NewLife;
using ThingsGateway.NewLife.Caching;
using ThingsGateway.NewLife.Threading;
using ThingsGateway.Schedule;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;
/// <inheritdoc/>

View File

@@ -15,8 +15,6 @@ using ThingsGateway.Extension;
using ThingsGateway.FriendlyException;
using ThingsGateway.Logging;
using ThingsGateway.NewLife.Json.Extension;
using ThingsGateway.Razor;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using Riok.Mapperly.Abstractions;
namespace ThingsGateway.Admin.Application;

View File

@@ -4,7 +4,6 @@ using Microsoft.AspNetCore.Http;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using Microsoft.Extensions.Logging;
using Microsoft.Extensions.Options;
using System.Collections.Concurrent;
using System.Security.Claims;

View File

@@ -10,7 +10,6 @@
using Microsoft.AspNetCore.Authentication;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Components;
using Microsoft.AspNetCore.Http;
using System.Security.Claims;
@@ -116,7 +115,7 @@ public class BlazorAuthenticationHandler : AppAuthorizeHandler
{
// 路由名称
var routeName = routeData.PageType.CustomAttributes.FirstOrDefault(x =>
x.AttributeType == typeof(RouteAttribute))?.ConstructorArguments?[0].Value as string;
x.AttributeType == typeof(Microsoft.AspNetCore.Components.RouteAttribute))?.ConstructorArguments?[0].Value as string;
if (routeName == null) return true;
if ((!user.PermissionCodeList.Contains(routeName.CutStart("/")) && !user.PermissionCodeList.Contains(routeName))) //如果当前路由信息不包含在角色授权路由列表中则认证失败

View File

@@ -11,11 +11,9 @@
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Filters;
using Microsoft.Extensions.Localization;
using ThingsGateway.DataValidation;
using ThingsGateway.FriendlyException;
using ThingsGateway.Razor;
using ThingsGateway.UnifyResult;
namespace ThingsGateway.Admin.Application;

View File

@@ -9,19 +9,15 @@
// ------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc.ApiExplorer;
using Microsoft.AspNetCore.Mvc.Controllers;
using Microsoft.Extensions.Options;
using Swashbuckle.AspNetCore.SwaggerGen;
using System.Globalization;
using System.Reflection;
using ThingsGateway.Extension;
using ThingsGateway.Common.Extension;
namespace ThingsGateway.Admin.Application;

View File

@@ -10,7 +10,6 @@
using Microsoft.AspNetCore.Authentication.Cookies;
using Microsoft.AspNetCore.Http;
using Microsoft.Extensions.Localization;
using System.Security.Claims;

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,11 +8,8 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.FriendlyException;
using ThingsGateway.NewLife.Json.Extension;
using ThingsGateway.Razor;
namespace ThingsGateway.Admin.Application;

View File

@@ -10,7 +10,6 @@
using Microsoft.AspNetCore.Components.Forms;
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Localization;
using System.Text;
using System.Web;

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.Extension.Generic;
namespace ThingsGateway.Admin.Application;

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,12 +8,8 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using System.Data;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;
internal sealed class SysOperateLogService : BaseService<SysOperateLog>, ISysOperateLogService

View File

@@ -8,10 +8,6 @@
// QQ群605534569
// ------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,11 +8,8 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.Extension.Generic;
using ThingsGateway.FriendlyException;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;

View File

@@ -8,10 +8,6 @@
// QQ群605534569
// ------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,10 +8,7 @@
// QQ群605534569
// ------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.FriendlyException;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using System.ComponentModel.DataAnnotations;
using ThingsGateway.Extension.Generic;

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,12 +8,9 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using Microsoft.Extensions.DependencyInjection;
using ThingsGateway.FriendlyException;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;

View File

@@ -8,10 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,11 +8,8 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.FriendlyException;
using ThingsGateway.NewLife.Json.Extension;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
namespace ThingsGateway.Admin.Application;
public interface ISessionService

View File

@@ -8,10 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;
internal sealed class SessionService : BaseService<SysUser>, ISessionService

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,14 +8,12 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.Common.Extension;
using ThingsGateway.Common.Extension.Generic;
using ThingsGateway.DataEncryption;
using ThingsGateway.Extension;
using ThingsGateway.Extension.Generic;
using ThingsGateway.FriendlyException;
using ThingsGateway.NewLife.Json.Extension;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;

View File

@@ -8,16 +8,13 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using System.Text.RegularExpressions;
using ThingsGateway.Common.Extension;
using ThingsGateway.DataEncryption;
using ThingsGateway.Extension;
using ThingsGateway.Extension.Generic;
using ThingsGateway.FriendlyException;
using ThingsGateway.NewLife.Json.Extension;
using ThingsGateway.Razor;
namespace ThingsGateway.Admin.Application;

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;
/// <summary>

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
@@ -43,7 +41,6 @@ public class Startup : AppStartup
services.AddSingleton<IVerificatInfoService, VerificatInfoService>();
services.AddScoped<IAuthRazorService, AuthRazorService>();
services.AddSingleton<IApiPermissionService, ApiPermissionService>();
services.AddSingleton<IFileService, FileService>();
services.AddSingleton<IImportExportService, ImportExportService>();

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.NewLife;
namespace ThingsGateway.Admin.Application;

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
namespace ThingsGateway.Admin.Application;
/// <inheritdoc/>

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
namespace ThingsGateway.Admin.Application;
/// <inheritdoc/>

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
namespace ThingsGateway.Admin.Application;
/// <inheritdoc/>

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
namespace ThingsGateway.Admin.Application;
/// <inheritdoc/>

View File

@@ -8,8 +8,6 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
namespace ThingsGateway.Admin.Application;
/// <inheritdoc/>

View File

@@ -9,7 +9,6 @@
//------------------------------------------------------------------------------
using ThingsGateway.Extension.Generic;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Application;

View File

@@ -9,7 +9,6 @@
//------------------------------------------------------------------------------
using ThingsGateway.Admin.Application;
using ThingsGateway.NewLife.Extension;
namespace ThingsGateway.Admin.Razor;

View File

@@ -10,7 +10,6 @@
using ThingsGateway.Admin.Application;
using ThingsGateway.NewLife;
using ThingsGateway.NewLife.Extension;
namespace ThingsGateway.Admin.Razor;

View File

@@ -16,7 +16,10 @@ global using Microsoft.Extensions.Options;
global using System.Diagnostics.CodeAnalysis;
global using ThingsGateway.Common;
global using ThingsGateway.DB;
global using ThingsGateway.NewLife.Extension;
global using ThingsGateway.Razor;
global using ThingsGateway.SqlSugar;
[assembly: SuppressMessage("Reliability", "CA2007", Justification = "<挂起>", Scope = "module")]
[assembly: GlobalGenerateSetParametersAsync(true)]

View File

@@ -12,7 +12,6 @@ using Microsoft.AspNetCore.Components.Forms;
using ThingsGateway.Admin.Application;
using ThingsGateway.Extension.Generic;
using ThingsGateway.NewLife.Extension;
namespace ThingsGateway.Admin.Razor;

View File

@@ -9,8 +9,6 @@
//------------------------------------------------------------------------------
using ThingsGateway.Admin.Application;
using ThingsGateway.NewLife.Extension;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Razor;

View File

@@ -9,7 +9,6 @@
//------------------------------------------------------------------------------
using ThingsGateway.Admin.Application;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Razor;

View File

@@ -9,8 +9,6 @@
//------------------------------------------------------------------------------
using ThingsGateway.Admin.Application;
using ThingsGateway.NewLife.Extension;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Razor;

View File

@@ -9,8 +9,6 @@
//------------------------------------------------------------------------------
using ThingsGateway.Admin.Application;
using ThingsGateway.NewLife.Extension;
using ThingsGateway.SqlSugar;
namespace ThingsGateway.Admin.Razor;

View File

@@ -10,7 +10,6 @@
using ThingsGateway.Admin.Application;
using ThingsGateway.Extension.Generic;
using ThingsGateway.NewLife.Extension;
namespace ThingsGateway.Admin.Razor;

View File

@@ -9,7 +9,6 @@
//------------------------------------------------------------------------------
using ThingsGateway.Admin.Application;
using ThingsGateway.NewLife.Extension;
namespace ThingsGateway.Admin.Razor;

View File

@@ -11,7 +11,6 @@
using Microsoft.AspNetCore.Components.Forms;
using ThingsGateway.Admin.Application;
using ThingsGateway.NewLife.Extension;
namespace ThingsGateway.Admin.Razor;

View File

@@ -9,7 +9,6 @@
//------------------------------------------------------------------------------
using ThingsGateway.Admin.Application;
using ThingsGateway.NewLife.Extension;
namespace ThingsGateway.Admin.Razor;

View File

@@ -8,13 +8,11 @@
// QQ群605534569
//------------------------------------------------------------------------------
using BootstrapBlazor.Components;
using ThingsGateway.Admin.Application;
using ThingsGateway.NewLife.Json.Extension;
using ThingsGateway.Razor;
namespace ThingsGateway.Admin.Application;
namespace ThingsGateway.Admin.Razor;
internal sealed class AuthRazorService : IAuthRazorService
{

View File

@@ -8,9 +8,9 @@
// QQ群605534569
//------------------------------------------------------------------------------
using ThingsGateway.Razor;
using ThingsGateway.Admin.Application;
namespace ThingsGateway.Admin.Application;
namespace ThingsGateway.Admin.Razor;
public class HybridAuthRazorService : IAuthRazorService

View File

@@ -8,9 +8,9 @@
// QQ群605534569
//------------------------------------------------------------------------------
using ThingsGateway.Razor;
using ThingsGateway.Admin.Application;
namespace ThingsGateway.Admin.Application;
namespace ThingsGateway.Admin.Razor;
public interface IAuthRazorService
{

View File

@@ -18,6 +18,7 @@ public class Startup : AppStartup
public void Configure(IServiceCollection services)
{
services.AddScoped<IMenuService, MenuService>();
services.AddScoped<IAuthRazorService, AuthRazorService>();
services.AddBootstrapBlazorTableExportService();
}
}

View File

@@ -37,6 +37,7 @@
<ItemGroup>
<ProjectReference Include="..\BlazorSetParametersAsyncGenerator\BlazorSetParametersAsyncGenerator.csproj" PrivateAssets="all" OutputItemType="Analyzer" />
<ProjectReference Include="..\ThingsGateway.Razor\ThingsGateway.Razor.csproj" />
</ItemGroup>
</Project>

View File

@@ -15,5 +15,5 @@
@using BootstrapBlazor.Components
@using ThingsGateway.Common.Extension;
@using ThingsGateway.Razor;

View File

@@ -14,6 +14,7 @@
"ThingsGateway.SqlSugar",
"ThingsGateway.Admin.Application",
"ThingsGateway.Admin.Razor",
"ThingsGateway.Common",
"ThingsGateway.DB",
"ThingsGateway.Razor"
]

View File

@@ -14,6 +14,7 @@
"ThingsGateway.SqlSugar",
"ThingsGateway.Admin.Application",
"ThingsGateway.Admin.Razor",
"ThingsGateway.Common",
"ThingsGateway.DB",
"ThingsGateway.Razor"
]

View File

@@ -6,6 +6,7 @@
@using ThingsGateway.Admin.Razor
@using ThingsGateway.Extension;
@using ThingsGateway.Razor
@using ThingsGateway.Common.Extension;
<div class="login h-100">
@* 左侧说明 *@

View File

@@ -19,6 +19,8 @@ using Microsoft.Extensions.Options;
using System.Diagnostics.CodeAnalysis;
using ThingsGateway.Admin.Application;
using ThingsGateway.Admin.Razor;
using ThingsGateway.Common;
using ThingsGateway.DataEncryption;
using ThingsGateway.NewLife.Extension;
using ThingsGateway.Razor;

View File

@@ -17,9 +17,11 @@
@using Microsoft.AspNetCore.Authorization
@using Microsoft.AspNetCore.Components.Authorization
@using Microsoft.Extensions.Localization
@using ThingsGateway.Common.Extension;
@using System.ComponentModel
@using System.ComponentModel.DataAnnotations
@using ThingsGateway.DB;
@inject NavigationManager NavigationManager

View File

@@ -19,6 +19,7 @@ using System.Diagnostics.CodeAnalysis;
using ThingsGateway.Admin.Application;
using ThingsGateway.Admin.Razor;
using ThingsGateway.Common;
using ThingsGateway.Razor;
namespace ThingsGateway.AdminServer;

View File

@@ -14,6 +14,7 @@ using System.Runtime.InteropServices;
using System.Text;
using ThingsGateway.Admin.Application;
using ThingsGateway.DB;
using ThingsGateway.NewLife.Log;
namespace ThingsGateway.AdminServer;
@@ -30,7 +31,7 @@ public class Program
// 增加中文编码支持
Encoding.RegisterProvider(CodePagesEncodingProvider.Instance);
ThingsGateway.Admin.Application.ClaimConst.Scheme = $"{typeof(Program).Assembly.GetName().Name}{SchemeHelper.GetOrCreate()}";
ClaimConst.Scheme = $"{typeof(Program).Assembly.GetName().Name}{SchemeHelper.GetOrCreate()}";
#region Logo

View File

@@ -40,6 +40,7 @@ public class SingleFilePublish : ISingleFilePublish
"ThingsGateway.NewLife.X",
"ThingsGateway.Razor",
"ThingsGateway.Admin.Razor" ,
"ThingsGateway.Common",
"ThingsGateway.DB",
"ThingsGateway.Admin.Application",
"ThingsGateway.SqlSugar",

View File

@@ -26,6 +26,7 @@ using System.Text.Unicode;
using ThingsGateway.Admin.Application;
using ThingsGateway.Admin.Razor;
using ThingsGateway.DB;
using ThingsGateway.VirtualFileServer;
namespace ThingsGateway.AdminServer;

View File

@@ -7,7 +7,7 @@
<TargetFrameworks>net8.0;net9.0;</TargetFrameworks>
</PropertyGroup>
<Import Project="Admin.targets" Condition=" '$(Configuration)' != 'Debug' " />
<!--<Import Project="Admin.targets" Condition=" '$(Configuration)' != 'Debug' " />-->
<PropertyGroup>
<OpenApiGenerateDocuments>false</OpenApiGenerateDocuments>
<SatelliteResourceLanguages>zh-Hans;en-US</SatelliteResourceLanguages>
@@ -26,7 +26,7 @@
<!--<PlatformTarget>x86</PlatformTarget>-->
</PropertyGroup>
<ItemGroup Condition=" '$(Configuration)' == 'Debug' ">
<ItemGroup>
<ProjectReference Include="..\ThingsGateway.Admin.Razor\ThingsGateway.Admin.Razor.csproj" />
</ItemGroup>

View File

@@ -8,7 +8,7 @@
// QQ群605534569
//------------------------------------------------------------------------------
namespace ThingsGateway.Admin.Application;
namespace ThingsGateway.Common;
/// <summary>
/// 忽略Excel导入导出

View File

@@ -8,7 +8,7 @@
// QQ群605534569
//------------------------------------------------------------------------------
namespace ThingsGateway.Admin.Application;
namespace ThingsGateway.Common;
/// <summary>
/// 种子数据忽略新增

View File

@@ -10,13 +10,12 @@
using System.Collections;
namespace ThingsGateway.List;
namespace ThingsGateway.Common.List;
/// <summary>
/// 线程安全的List其基本操作和List一致。
/// </summary>
/// <typeparam name="T"></typeparam>
[ThingsGateway.DependencyInjection.SuppressSniffer]
public class ConcurrentList<T> : IList<T>, IReadOnlyList<T>
{
private readonly List<T> m_list;

View File

@@ -12,7 +12,7 @@
//using System.Text;
//namespace ThingsGateway.Razor;
//namespace ThingsGateway.Common;
///// <summary>
///// <see cref="Encoding"/> Master规则

View File

@@ -8,7 +8,7 @@
// QQ群605534569
//------------------------------------------------------------------------------
namespace ThingsGateway.Razor;
namespace ThingsGateway.Common;
public interface IDriverUIBase
{

View File

@@ -8,9 +8,9 @@
// QQ群605534569
//------------------------------------------------------------------------------
using ThingsGateway.List;
using ThingsGateway.Common.List;
namespace ThingsGateway;
namespace ThingsGateway.Common;
/// <summary>
/// 文件导入通用输出

View File

@@ -8,7 +8,7 @@
// QQ群605534569
//------------------------------------------------------------------------------
namespace ThingsGateway.Razor;
namespace ThingsGateway.Common;
public class ModelValueValidateForm
{

View File

@@ -8,7 +8,7 @@
// QQ群605534569
//------------------------------------------------------------------------------
namespace ThingsGateway;
namespace ThingsGateway.Common;
using System;
using System.Text;
@@ -16,7 +16,6 @@ using System.Text;
/// <summary>
/// 随机数
/// </summary>
[ThingsGateway.DependencyInjection.SuppressSniffer]
public static class RandomHelper
{
/// <summary>

View File

@@ -8,7 +8,7 @@
// QQ群605534569
//------------------------------------------------------------------------------
namespace ThingsGateway;
namespace ThingsGateway.Common;
/// <summary>
/// 全局分页查询输入参数

View File

@@ -8,7 +8,7 @@
// QQ群605534569
//------------------------------------------------------------------------------
namespace ThingsGateway;
namespace ThingsGateway.Common;
/// <summary>
/// 全局分页查询输入参数

View File

@@ -8,7 +8,7 @@
// QQ群605534569
//------------------------------------------------------------------------------
namespace ThingsGateway;
namespace ThingsGateway.Common;
/// <summary>
/// 主键id基类

View File

@@ -8,7 +8,7 @@
// QQ群605534569
//------------------------------------------------------------------------------
namespace ThingsGateway;
namespace ThingsGateway.Common;
/// <summary>
/// SqlSugar 分页泛型集合

View File

@@ -8,7 +8,7 @@
// QQ群605534569
//------------------------------------------------------------------------------
namespace ThingsGateway.Razor;
namespace ThingsGateway.Common;
/// <inheritdoc/>
[ThingsGateway.DependencyInjection.SuppressSniffer]

View File

@@ -10,7 +10,7 @@
using System.Reflection;
namespace ThingsGateway.Extension.Generic;
namespace ThingsGateway.Common.Extension.Generic;
/// <inheritdoc/>
[ThingsGateway.DependencyInjection.SuppressSniffer]

View File

@@ -10,7 +10,7 @@
using Microsoft.JSInterop;
namespace ThingsGateway.Razor;
namespace ThingsGateway.Common.Extension;
/// <summary>
/// JSRuntime扩展方法
@@ -26,7 +26,7 @@ public static class JSRuntimeExtensions
{
try
{
return await jsRuntime.InvokeAsync<string>("getCultureLocalStorage");
return await jsRuntime.InvokeAsync<string>("getCultureLocalStorage").ConfigureAwait(false);
}
catch
{
@@ -44,7 +44,7 @@ public static class JSRuntimeExtensions
{
try
{
await jsRuntime.InvokeVoidAsync("setCultureLocalStorage", cultureName);
await jsRuntime.InvokeVoidAsync("setCultureLocalStorage", cultureName).ConfigureAwait(false);
}
catch
{

View File

@@ -15,7 +15,7 @@ using System.ComponentModel.DataAnnotations;
using System.Linq.Expressions;
using System.Reflection;
namespace ThingsGateway;
namespace ThingsGateway.Common.Extension;
/// <inheritdoc/>
[ThingsGateway.DependencyInjection.SuppressSniffer]

View File

@@ -7,6 +7,7 @@
// 使用文档https://thingsgateway.cn/
// QQ群605534569
//------------------------------------------------------------------------------
#if NET6_0_OR_GREATER
using System.Collections.Concurrent;
using System.ComponentModel;
@@ -15,12 +16,10 @@ using System.Runtime.CompilerServices;
using System.Text.Json;
using System.Text.RegularExpressions;
namespace ThingsGateway;
namespace ThingsGateway.Common.Extension;
/// <summary>
/// 对象拓展类
/// </summary>
[ThingsGateway.DependencyInjection.SuppressSniffer]
public static class ObjectExtensions
{
/// <summary>
@@ -614,3 +613,4 @@ public static class ObjectExtensions
return string.Concat(str.First().ToString().ToUpper(), str.AsSpan(1));
}
}
#endif

View File

@@ -7,15 +7,15 @@
// 使用文档https://thingsgateway.cn/
// QQ群605534569
//------------------------------------------------------------------------------
#if NET6_0_OR_GREATER
using System.Collections.Concurrent;
namespace ThingsGateway;
namespace ThingsGateway.Common.Extension;
/// <summary>
/// 提供对 IEnumerable 的并行操作扩展方法
/// </summary>
[ThingsGateway.DependencyInjection.SuppressSniffer]
public static class ParallelExtensions
{
/// <summary>
@@ -145,3 +145,6 @@ public static class ParallelExtensions
}
#endif

View File

@@ -7,13 +7,13 @@
// 使用文档https://thingsgateway.cn/
// QQ群605534569
//------------------------------------------------------------------------------
#if NET6_0_OR_GREATER
using System.Text.RegularExpressions;
namespace ThingsGateway.Extension;
namespace ThingsGateway.Common.Extension;
/// <inheritdoc/>
[ThingsGateway.DependencyInjection.SuppressSniffer]
public static class StringExtensions
{
/// <summary>
@@ -195,3 +195,4 @@ public static class StringExtensions
/// <returns>真:是汉字;假:不是</returns>
private static bool IsChinese(string text) => Regex.IsMatch(text, @"[\u4e00-\u9fbb]");
}
#endif

Some files were not shown because too many files have changed in this diff Show More