Rename projects to FileShare

This commit is contained in:
luoqian 2026-05-22 14:29:22 +08:00
parent 8270cf198b
commit 9f8da2c063
154 changed files with 394 additions and 398 deletions

52
.gitignore vendored
View File

@ -2,34 +2,30 @@
# 此 .gitignore 文件已由 Microsoft(R) Visual Studio 自动创建。
################################################################################
/Avalonia-PC/bin
/Avalonia-PC/.vs
/Avalonia-PC/obj
/Avalonia-API/bin
/Avalonia-API/obj
/Avalonia-Services/bin
/Avalonia-Services/obj
/Avalonia-Web-VUE/.vscode
/Avalonia-Web-VUE/obj
/Avalonia-Web-VUE/node_modules
/Avalonia-Web-VUE/dist
/Avalonia-Web-VUE/.vscode
/avalonia-web-react/obj
/avalonia-web-react/obj
/avalonia-web-react/node_modules
/avalonia-web-react/dist
/Avalonia-EFCore/bin
/Avalonia-EFCore/obj
/Avalonia-Common/bin
/Avalonia-Common/obj
/Avalonia-API/logs
/Avalonia-API/avalonia-api.db
/Avalonia-API/avalonia-api.db-shm
/Avalonia-API/avalonia-api.db-wal
/Avalonia-API/app.db
/Avalonia-API/app.db-shm
/Avalonia-API/app.db-wal
/Avalonia-API/wwwroot
/FileShare-PC/bin
/FileShare-PC/.vs
/FileShare-PC/obj
/FileShare-API/bin
/FileShare-API/obj
/FileShare-Services/bin
/FileShare-Services/obj
/FileShare-Web-VUE/.vscode
/FileShare-Web-VUE/obj
/FileShare-Web-VUE/node_modules
/FileShare-Web-VUE/dist
/FileShare-Web-VUE/.vscode
/FileShare-EFCore/bin
/FileShare-EFCore/obj
/FileShare-Common/bin
/FileShare-Common/obj
/FileShare-API/logs
/FileShare-API/fileshare-api.db
/FileShare-API/fileshare-api.db-shm
/FileShare-API/fileshare-api.db-wal
/FileShare-API/app.db
/FileShare-API/app.db-shm
/FileShare-API/app.db-wal
/FileShare-API/wwwroot
/package-output
/package-scripts/tools
/.vs

View File

@ -1,6 +0,0 @@
@Avalonia_API_HostAddress = http://localhost:5206
GET {{Avalonia_API_HostAddress}}/weatherforecast/
Accept: application/json
###

View File

@ -1,11 +0,0 @@
<Solution>
<Project Path="../Avalonia-API/Avalonia-API.csproj" Id="e33aba9a-a56b-4f6b-8eaa-3acbed65ebad" />
<Project Path="../Avalonia-Common/Avalonia-Common.csproj" Id="caed4118-2161-4382-90b8-35fb4efe3b5f" />
<Project Path="../Avalonia-EFCore/Avalonia-EFCore.csproj" Id="64557501-62a7-4863-b2bf-1570b8c6fecb" />
<Project Path="../Avalonia-Services/Avalonia-Services.csproj" Id="b8757cf9-5422-4c67-acae-3c967c95f866" />
<Project Path="../Avalonia-Web-VUE/avalonia-web-vue.esproj">
<Build />
<Deploy />
</Project>
<Project Path="Avalonia-PC.csproj" />
</Solution>

View File

@ -1,11 +1,11 @@
using Avalonia_Common.Core;
using Avalonia_EFCore.Database;
using Avalonia_EFCore.Models;
using Avalonia_Services.Core;
using Avalonia_Services.Services.AuthService;
using FileShare_Common.Core;
using FileShare_EFCore.Database;
using FileShare_EFCore.Models;
using FileShare_Services.Core;
using FileShare_Services.Services.AuthService;
using Microsoft.EntityFrameworkCore;
namespace Avalonia_API.Authentication
namespace FileShare_API.Authentication
{
/// <summary>
/// API 鉴权端点服务,实现 <see cref="IApiAuthEndpointService"/>

View File

@ -1,4 +1,4 @@
namespace Avalonia_API.Authentication
namespace FileShare_API.Authentication
{
/// <summary>
/// JWT 鉴权配置选项,从 appsettings.json 的 Jwt 节绑定。
@ -8,12 +8,12 @@ namespace Avalonia_API.Authentication
/// <summary>
/// 获取或设置 Token 签发者。
/// </summary>
public string Issuer { get; set; } = "Avalonia-API";
public string Issuer { get; set; } = "FileShare-API";
/// <summary>
/// 获取或设置 Token 受众。
/// </summary>
public string Audience { get; set; } = "Avalonia-Client";
public string Audience { get; set; } = "FileShare-Client";
/// <summary>
/// 获取或设置签名密钥(至少 32 字节)。

View File

@ -1,11 +1,11 @@
using Avalonia_EFCore.Models;
using FileShare_EFCore.Models;
using Microsoft.Extensions.Options;
using Microsoft.IdentityModel.Tokens;
using System.IdentityModel.Tokens.Jwt;
using System.Security.Claims;
using System.Text;
namespace Avalonia_API.Authentication
namespace FileShare_API.Authentication
{
/// <summary>
/// JWT Token 服务,负责创建包含用户声明和角色的 Access Token。

View File

@ -1,11 +1,11 @@
using Avalonia_EFCore.Database;
using Avalonia_EFCore.Models;
using FileShare_EFCore.Database;
using FileShare_EFCore.Models;
using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.Options;
using System.Security.Cryptography;
using System.Text;
namespace Avalonia_API.Authentication
namespace FileShare_API.Authentication
{
/// <summary>
/// Refresh Token 服务,负责创建、查找、撤销和轮换 Refresh Token

View File

@ -1,18 +1,18 @@
using Avalonia_API.Authentication;
using Avalonia_API.Services;
using Avalonia_EFCore.Database;
using Avalonia_Services.Core;
using Avalonia_Services.Endpoints;
using Avalonia_Services.Services;
using Avalonia_Services.Services.AuthService;
using Avalonia_Services.Services.FileLibrary;
using Avalonia_Services.Services.QrCode;
using FileShare_API.Authentication;
using FileShare_API.Services;
using FileShare_EFCore.Database;
using FileShare_Services.Core;
using FileShare_Services.Endpoints;
using FileShare_Services.Services;
using FileShare_Services.Services.AuthService;
using FileShare_Services.Services.FileLibrary;
using FileShare_Services.Services.QrCode;
using Microsoft.AspNetCore.DataProtection;
using Microsoft.AspNetCore.Authentication.JwtBearer;
using Microsoft.IdentityModel.Tokens;
using System.Text;
namespace Avalonia_API.Configuration
namespace FileShare_API.Configuration
{
/// <summary>
/// API 项目服务配置扩展类,负责注册数据库、鉴权、业务服务和统一端点。
@ -21,7 +21,7 @@ namespace Avalonia_API.Configuration
{
/// <summary>
/// 注册统一端点及其依赖的服务(含数据库)。
/// 所有业务端点定义在 Avalonia-Services/Endpoints/AppEndpoints.cs。
/// 所有业务端点定义在 FileShare-Services/Endpoints/AppEndpoints.cs。
/// </summary>
public static IServiceCollection AddUnifiedApiServices(this IServiceCollection services, IConfiguration configuration)
{

View File

@ -1,6 +1,6 @@
using Avalonia_Services.Services.FileLibrary;
using FileShare_Services.Services.FileLibrary;
namespace Avalonia_API.Extensions
namespace FileShare_API.Extensions
{
/// <summary>
/// API-only raw file stream endpoints used by browser media elements.

View File

@ -1,14 +1,14 @@
using Avalonia_Services.Core;
using FileShare_Services.Core;
using Microsoft.AspNetCore.Authorization;
using AspNetCoreFilterContext = Microsoft.AspNetCore.Http.EndpointFilterInvocationContext;
using AspNetCoreFilterDelegate = Microsoft.AspNetCore.Http.EndpointFilterDelegate;
// 解决与 ASP.NET Core 同名类型的冲突
using UnifiedFilter = Avalonia_Services.Core.IEndpointFilter;
using UnifiedFilter = FileShare_Services.Core.IEndpointFilter;
namespace Avalonia_API.Extensions
namespace FileShare_API.Extensions
{
/// <summary>
/// 将 Avalonia-Services 的统一端点映射到 ASP.NET Core Minimal API。
/// 将 FileShare-Services 的统一端点映射到 ASP.NET Core Minimal API。
/// 支持鉴权、过滤器、中间件的完整 ASP.NET Core 管道。
/// </summary>
public static class UnifiedEndpointExtensions

View File

@ -4,7 +4,7 @@
<TargetFramework>net10.0</TargetFramework>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
<RootNamespace>Avalonia_API</RootNamespace>
<RootNamespace>FileShare_API</RootNamespace>
</PropertyGroup>
<ItemGroup>
@ -19,27 +19,27 @@
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Avalonia-Services\Avalonia-Services.csproj" />
<ProjectReference Include="..\Avalonia-Common\Avalonia-Common.csproj" />
<ProjectReference Include="..\Avalonia-EFCore\Avalonia-EFCore.csproj" />
<ProjectReference Include="..\FileShare-Services\FileShare-Services.csproj" />
<ProjectReference Include="..\FileShare-Common\FileShare-Common.csproj" />
<ProjectReference Include="..\FileShare-EFCore\FileShare-EFCore.csproj" />
</ItemGroup>
<ItemGroup>
<Folder Include="Controllers\" />
</ItemGroup>
<Target Name="RestoreFrontendPackages" BeforeTargets="Build" Condition="'$(SkipFrontendBuild)' != 'true' And Exists('..\Avalonia-Web-VUE\package.json') And !Exists('..\Avalonia-Web-VUE\node_modules')">
<Message Importance="high" Text="Restoring Avalonia-Web-VUE npm packages..." />
<Exec WorkingDirectory="..\Avalonia-Web-VUE" Command="npm.cmd install" />
<Target Name="RestoreFrontendPackages" BeforeTargets="Build" Condition="'$(SkipFrontendBuild)' != 'true' And Exists('..\FileShare-Web-VUE\package.json') And !Exists('..\FileShare-Web-VUE\node_modules')">
<Message Importance="high" Text="Restoring FileShare-Web-VUE npm packages..." />
<Exec WorkingDirectory="..\FileShare-Web-VUE" Command="npm.cmd install" />
</Target>
<Target Name="BuildFrontend" BeforeTargets="Build" DependsOnTargets="RestoreFrontendPackages" Condition="'$(SkipFrontendBuild)' != 'true' And Exists('..\Avalonia-Web-VUE\package.json')">
<Message Importance="high" Text="Building Avalonia-Web-VUE into Avalonia-API/wwwroot..." />
<Exec WorkingDirectory="..\Avalonia-Web-VUE" Command="npm.cmd run build-only" />
<Target Name="BuildFrontend" BeforeTargets="Build" DependsOnTargets="RestoreFrontendPackages" Condition="'$(SkipFrontendBuild)' != 'true' And Exists('..\FileShare-Web-VUE\package.json')">
<Message Importance="high" Text="Building FileShare-Web-VUE into FileShare-API/wwwroot..." />
<Exec WorkingDirectory="..\FileShare-Web-VUE" Command="npm.cmd run build-only" />
<RemoveDir Directories="wwwroot" />
<MakeDir Directories="wwwroot" />
<ItemGroup>
<FrontendDist Include="..\Avalonia-Web-VUE\dist\**\*.*" />
<FrontendDist Include="..\FileShare-Web-VUE\dist\**\*.*" />
</ItemGroup>
<Copy SourceFiles="@(FrontendDist)" DestinationFiles="@(FrontendDist->'wwwroot\%(RecursiveDir)%(Filename)%(Extension)')" SkipUnchangedFiles="false" />
</Target>

View File

@ -0,0 +1,6 @@
@FileShare_API_HostAddress = http://localhost:5206
GET {{FileShare_API_HostAddress}}/weatherforecast/
Accept: application/json
###

View File

@ -1,13 +1,13 @@
using Avalonia_API.Configuration;
using Avalonia_API.Extensions;
using Avalonia_Common.Infrastructure;
using Avalonia_EFCore.Database;
using Avalonia_Services.Core;
using FileShare_API.Configuration;
using FileShare_API.Extensions;
using FileShare_Common.Infrastructure;
using FileShare_EFCore.Database;
using FileShare_Services.Core;
using Serilog;
// 初始化日志系统
Log.Logger = LoggingConfiguration.CreateDefaultLogger(logDir: "logs");
Log.Information("Avalonia-API 正在启动...");
Log.Information("FileShare-API 正在启动...");
try
{
@ -30,7 +30,7 @@ try
.AllowAnyMethod());
});
// 注册统一端点及业务服务(入口在 Avalonia-Services/Endpoints/AppEndpoints.cs
// 注册统一端点及业务服务(入口在 FileShare-Services/Endpoints/AppEndpoints.cs
builder.Services.AddUnifiedApiServices(builder.Configuration);
var app = builder.Build();
@ -46,7 +46,7 @@ try
app.MapOpenApi();
app.UseSwaggerUI(options =>
{
options.SwaggerEndpoint("/openapi/v1.json", "Avalonia API v1");
options.SwaggerEndpoint("/openapi/v1.json", "FileShare API v1");
options.RoutePrefix = "swagger";
});
}
@ -67,7 +67,7 @@ try
}
catch (Exception ex)
{
Log.Fatal(ex, "Avalonia-API 启动失败");
Log.Fatal(ex, "FileShare-API 启动失败");
}
finally
{

View File

@ -1,6 +1,6 @@
using Avalonia_Services.Services.FileLibrary;
using FileShare_Services.Services.FileLibrary;
namespace Avalonia_API.Services
namespace FileShare_API.Services
{
public sealed class FileLibraryScanHostedService(IServiceScopeFactory scopeFactory, ILogger<FileLibraryScanHostedService> logger)
: BackgroundService

View File

@ -7,8 +7,8 @@
},
"AllowedHosts": "*",
"Jwt": {
"Issuer": "Avalonia-API",
"Audience": "Avalonia-Client",
"Issuer": "FileShare-API",
"Audience": "FileShare-Client",
"SigningKey": "change-this-development-signing-key-at-least-32-bytes",
"AccessTokenMinutes": 60,
"RefreshTokenDays": 30

View File

@ -1,6 +1,6 @@
using System.Text.Json.Serialization;
namespace Avalonia_Common.Core
namespace FileShare_Common.Core
{
/// <summary>
/// 统一端点响应契约。

View File

@ -1,8 +1,8 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net10.0</TargetFramework>
<RootNamespace>Avalonia_Common</RootNamespace>
<RootNamespace>FileShare_Common</RootNamespace>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>

View File

@ -1,10 +1,10 @@
using Serilog;
using Serilog.Events;
namespace Avalonia_Common.Infrastructure
namespace FileShare_Common.Infrastructure
{
/// <summary>
/// Serilog 日志配置 —— 可在 Avalonia-API 和 Avalonia-PC 中共享。
/// Serilog 日志配置 —— 可在 FileShare-API 和 FileShare-PC 中共享。
/// </summary>
public static class LoggingConfiguration
{

View File

@ -1,12 +1,12 @@
using Avalonia_EFCore.Models;
using FileShare_EFCore.Models;
using Microsoft.EntityFrameworkCore;
namespace Avalonia_EFCore.Database
namespace FileShare_EFCore.Database
{
/// <summary>
/// 应用数据库上下文 —— 继承自 Avalonia-EFCore 的 AppDbContext。
/// 应用数据库上下文 —— 继承自 FileShare-EFCore 的 AppDbContext。
/// 所有业务实体在此注册 DbSet。
/// 这是 Avalonia-API 和 Avalonia-PC 共用的具体数据上下文。
/// 这是 FileShare-API 和 FileShare-PC 共用的具体数据上下文。
/// </summary>
public class AppDataContext(DatabaseConfiguration dbConfig) : AppDbContext(dbConfig)
{

View File

@ -1,6 +1,6 @@
using Microsoft.EntityFrameworkCore.Design;
namespace Avalonia_EFCore.Database
namespace FileShare_EFCore.Database
{
/// <summary>
/// 设计时 DbContext 工厂,用于 EF Core 迁移工具生成迁移代码。
@ -67,11 +67,11 @@ namespace Avalonia_EFCore.Database
var provider = GetProvider(args) ?? defaultProvider;
return provider switch
{
DatabaseProvider.SQLite => DatabaseConfiguration.ForSQLite("avalonia-api.db"),
DatabaseProvider.SqlServer => DatabaseConfiguration.ForSqlServer("(localdb)\\MSSQLLocalDB", "AvaloniaApi"),
DatabaseProvider.PostgreSQL => DatabaseConfiguration.ForPostgreSQL("localhost", "avalonia_api", "postgres", "postgres"),
DatabaseProvider.MySQL => DatabaseConfiguration.ForMySQL("localhost", "avalonia_api", "root", "root"),
_ => DatabaseConfiguration.ForSQLite("avalonia-api.db"),
DatabaseProvider.SQLite => DatabaseConfiguration.ForSQLite("fileshare-api.db"),
DatabaseProvider.SqlServer => DatabaseConfiguration.ForSqlServer("(localdb)\\MSSQLLocalDB", "FileShareApi"),
DatabaseProvider.PostgreSQL => DatabaseConfiguration.ForPostgreSQL("localhost", "fileshare_api", "postgres", "postgres"),
DatabaseProvider.MySQL => DatabaseConfiguration.ForMySQL("localhost", "fileshare_api", "root", "root"),
_ => DatabaseConfiguration.ForSQLite("fileshare-api.db"),
};
}

View File

@ -4,7 +4,7 @@ using System.Linq;
using System.Threading;
using System.Threading.Tasks;
namespace Avalonia_EFCore.Database
namespace FileShare_EFCore.Database
{
/// <summary>
/// 应用数据库上下文基类 —— 自动根据 DatabaseConfiguration 选择数据库提供程序。

View File

@ -1,4 +1,4 @@
namespace Avalonia_EFCore.Database
namespace FileShare_EFCore.Database
{
/// <summary>
/// 支持的数据库提供程序类型。

View File

@ -1,7 +1,7 @@
using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.DependencyInjection;
namespace Avalonia_EFCore.Database
namespace FileShare_EFCore.Database
{
/// <summary>
/// 数据库服务注册扩展 —— 在 Program.cs 中一行配置数据库。

View File

@ -1,4 +1,4 @@
using Avalonia_Common.Infrastructure;
using FileShare_Common.Infrastructure;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
@ -9,7 +9,7 @@ using System.Reflection;
using System.Threading;
using System.Threading.Tasks;
namespace Avalonia_EFCore.Database
namespace FileShare_EFCore.Database
{
/// <summary>
/// 数据库管理器 —— 负责连接测试、自动迁移、种子数据、版本检查。

View File

@ -1,12 +1,12 @@
using Microsoft.EntityFrameworkCore;
namespace Avalonia_EFCore.Database
namespace FileShare_EFCore.Database
{
/// <summary>
/// 数据库提供程序注册表 —— 统一注册所有支持的提供程序配置委托。
/// 具体使用哪个提供程序由各宿主项目决定:
/// Avalonia-API从 appsettings.json 的 DatabaseConfiguration 节读取;
/// Avalonia-PC :固定使用 SQLite。
/// FileShare-API从 appsettings.json 的 DatabaseConfiguration 节读取;
/// FileShare-PC :固定使用 SQLite。
/// </summary>
public static class DatabaseProviderRegistry
{
@ -37,7 +37,7 @@ namespace Avalonia_EFCore.Database
}
/// <summary>
/// 注册所有内置提供程序的默认配置(四个包均已内置在 Avalonia-EFCore 中)。
/// 注册所有内置提供程序的默认配置(四个包均已内置在 FileShare-EFCore 中)。
/// 注册完成后由调用方根据自身需求选择具体的 <see cref="DatabaseProvider"/>。
/// </summary>
public static void RegisterDefaults()

View File

@ -1,4 +1,4 @@
namespace Avalonia_EFCore.Database
namespace FileShare_EFCore.Database
{
/// <summary>
/// SQLite 专用 DbContext用于隔离 SQLite 迁移集。

View File

@ -1,8 +1,8 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net10.0</TargetFramework>
<RootNamespace>Avalonia_EFCore</RootNamespace>
<RootNamespace>FileShare_EFCore</RootNamespace>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>
@ -22,7 +22,7 @@
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Avalonia-Common\Avalonia-Common.csproj" />
<ProjectReference Include="..\FileShare-Common\FileShare-Common.csproj" />
</ItemGroup>
</Project>

View File

@ -1,6 +1,6 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
@ -8,7 +8,7 @@ using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
#nullable disable
namespace Avalonia_EFCore.Migrations.MySQL
namespace FileShare_EFCore.Migrations.MySQL
{
[DbContext(typeof(MySqlAppDataContext))]
[Migration("20260520082626_AutoMigration_20260520162543")]
@ -22,7 +22,7 @@ namespace Avalonia_EFCore.Migrations.MySQL
.HasAnnotation("ProductVersion", "10.0.7")
.HasAnnotation("Relational:MaxIdentifierLength", 64);
modelBuilder.Entity("Avalonia_EFCore.Models.ApiRefreshTokenEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ApiRefreshTokenEntity", b =>
{
b.Property<long>("Id")
.ValueGeneratedOnAdd()
@ -82,7 +82,7 @@ namespace Avalonia_EFCore.Migrations.MySQL
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -127,7 +127,7 @@ namespace Avalonia_EFCore.Migrations.MySQL
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()

View File

@ -1,10 +1,10 @@
using System;
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using MySql.EntityFrameworkCore.Metadata;
#nullable disable
namespace Avalonia_EFCore.Migrations.MySQL
namespace FileShare_EFCore.Migrations.MySQL
{
/// <inheritdoc />
public partial class AutoMigration_20260520162543 : Migration

View File

@ -1,6 +1,6 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
@ -8,7 +8,7 @@ using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
#nullable disable
namespace Avalonia_EFCore.Migrations.MySQL
namespace FileShare_EFCore.Migrations.MySQL
{
[DbContext(typeof(MySqlAppDataContext))]
[Migration("20260520083306_AutoMigration_20260520163216")]
@ -22,7 +22,7 @@ namespace Avalonia_EFCore.Migrations.MySQL
.HasAnnotation("ProductVersion", "10.0.7")
.HasAnnotation("Relational:MaxIdentifierLength", 64);
modelBuilder.Entity("Avalonia_EFCore.Models.ApiRefreshTokenEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ApiRefreshTokenEntity", b =>
{
b.Property<long>("Id")
.ValueGeneratedOnAdd()
@ -82,7 +82,7 @@ namespace Avalonia_EFCore.Migrations.MySQL
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -133,7 +133,7 @@ namespace Avalonia_EFCore.Migrations.MySQL
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()

View File

@ -1,8 +1,8 @@
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Avalonia_EFCore.Migrations.MySQL
namespace FileShare_EFCore.Migrations.MySQL
{
/// <inheritdoc />
public partial class AutoMigration_20260520163216 : Migration

View File

@ -1,13 +1,13 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
#nullable disable
namespace Avalonia_EFCore.Migrations.MySQL
namespace FileShare_EFCore.Migrations.MySQL
{
[DbContext(typeof(MySqlAppDataContext))]
partial class MySqlAppDataContextModelSnapshot : ModelSnapshot
@ -19,7 +19,7 @@ namespace Avalonia_EFCore.Migrations.MySQL
.HasAnnotation("ProductVersion", "10.0.7")
.HasAnnotation("Relational:MaxIdentifierLength", 64);
modelBuilder.Entity("Avalonia_EFCore.Models.ApiRefreshTokenEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ApiRefreshTokenEntity", b =>
{
b.Property<long>("Id")
.ValueGeneratedOnAdd()
@ -79,7 +79,7 @@ namespace Avalonia_EFCore.Migrations.MySQL
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -130,7 +130,7 @@ namespace Avalonia_EFCore.Migrations.MySQL
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()

View File

@ -1,6 +1,6 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
@ -9,7 +9,7 @@ using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable
namespace Avalonia_EFCore.Migrations.PostgreSQL
namespace FileShare_EFCore.Migrations.PostgreSQL
{
[DbContext(typeof(PostgreSqlAppDataContext))]
[Migration("20260520082617_AutoMigration_20260520162543")]
@ -25,7 +25,7 @@ namespace Avalonia_EFCore.Migrations.PostgreSQL
NpgsqlModelBuilderExtensions.UseIdentityByDefaultColumns(modelBuilder);
modelBuilder.Entity("Avalonia_EFCore.Models.ApiRefreshTokenEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ApiRefreshTokenEntity", b =>
{
b.Property<long>("Id")
.ValueGeneratedOnAdd()
@ -87,7 +87,7 @@ namespace Avalonia_EFCore.Migrations.PostgreSQL
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -134,7 +134,7 @@ namespace Avalonia_EFCore.Migrations.PostgreSQL
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()

View File

@ -1,10 +1,10 @@
using System;
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable
namespace Avalonia_EFCore.Migrations.PostgreSQL
namespace FileShare_EFCore.Migrations.PostgreSQL
{
/// <inheritdoc />
public partial class AutoMigration_20260520162543 : Migration

View File

@ -1,6 +1,6 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
@ -9,7 +9,7 @@ using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable
namespace Avalonia_EFCore.Migrations.PostgreSQL
namespace FileShare_EFCore.Migrations.PostgreSQL
{
[DbContext(typeof(PostgreSqlAppDataContext))]
[Migration("20260520083254_AutoMigration_20260520163216")]
@ -25,7 +25,7 @@ namespace Avalonia_EFCore.Migrations.PostgreSQL
NpgsqlModelBuilderExtensions.UseIdentityByDefaultColumns(modelBuilder);
modelBuilder.Entity("Avalonia_EFCore.Models.ApiRefreshTokenEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ApiRefreshTokenEntity", b =>
{
b.Property<long>("Id")
.ValueGeneratedOnAdd()
@ -87,7 +87,7 @@ namespace Avalonia_EFCore.Migrations.PostgreSQL
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -140,7 +140,7 @@ namespace Avalonia_EFCore.Migrations.PostgreSQL
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()

View File

@ -1,8 +1,8 @@
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Avalonia_EFCore.Migrations.PostgreSQL
namespace FileShare_EFCore.Migrations.PostgreSQL
{
/// <inheritdoc />
public partial class AutoMigration_20260520163216 : Migration

View File

@ -1,6 +1,6 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
@ -8,7 +8,7 @@ using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable
namespace Avalonia_EFCore.Migrations.PostgreSQL
namespace FileShare_EFCore.Migrations.PostgreSQL
{
[DbContext(typeof(PostgreSqlAppDataContext))]
partial class PostgreSqlAppDataContextModelSnapshot : ModelSnapshot
@ -22,7 +22,7 @@ namespace Avalonia_EFCore.Migrations.PostgreSQL
NpgsqlModelBuilderExtensions.UseIdentityByDefaultColumns(modelBuilder);
modelBuilder.Entity("Avalonia_EFCore.Models.ApiRefreshTokenEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ApiRefreshTokenEntity", b =>
{
b.Property<long>("Id")
.ValueGeneratedOnAdd()
@ -84,7 +84,7 @@ namespace Avalonia_EFCore.Migrations.PostgreSQL
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -137,7 +137,7 @@ namespace Avalonia_EFCore.Migrations.PostgreSQL
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()

View File

@ -1,12 +1,12 @@
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Avalonia_EFCore.Migrations.SQLite
namespace FileShare_EFCore.Migrations.SQLite
{
[DbContext(typeof(SqliteAppDataContext))]
[Migration("20260514000100_InitialCreate")]
@ -18,7 +18,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
modelBuilder
.HasAnnotation("ProductVersion", "10.0.0");
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.HasComment("用户主键")
@ -52,7 +52,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.HasComment("天气预报主键")

View File

@ -4,7 +4,7 @@ using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable
namespace Avalonia_EFCore.Migrations.SQLite
namespace FileShare_EFCore.Migrations.SQLite
{
/// <summary>
/// 初始数据库基线。后续软件版本只追加新的 Migration不修改已发布 Migration。

View File

@ -1,6 +1,6 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
@ -8,7 +8,7 @@ using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
#nullable disable
namespace Avalonia_EFCore.Migrations.SQLite
namespace FileShare_EFCore.Migrations.SQLite
{
[DbContext(typeof(SqliteAppDataContext))]
[Migration("20260515072045_AutoMigration_20260515152037")]
@ -20,7 +20,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
#pragma warning disable 612, 618
modelBuilder.HasAnnotation("ProductVersion", "10.0.0");
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -65,7 +65,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()

View File

@ -1,8 +1,8 @@
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Avalonia_EFCore.Migrations.SQLite
namespace FileShare_EFCore.Migrations.SQLite
{
/// <inheritdoc />
public partial class AutoMigration_20260515152037 : Migration

View File

@ -1,6 +1,6 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
@ -8,7 +8,7 @@ using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
#nullable disable
namespace Avalonia_EFCore.Migrations.SQLite
namespace FileShare_EFCore.Migrations.SQLite
{
[DbContext(typeof(SqliteAppDataContext))]
[Migration("20260515085847_AutoMigration_20260515165835")]
@ -20,7 +20,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
#pragma warning disable 612, 618
modelBuilder.HasAnnotation("ProductVersion", "10.0.0");
modelBuilder.Entity("Avalonia_EFCore.Models.ApiRefreshTokenEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ApiRefreshTokenEntity", b =>
{
b.Property<long>("Id")
.ValueGeneratedOnAdd()
@ -80,7 +80,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -125,7 +125,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()

View File

@ -1,9 +1,9 @@
using System;
using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Avalonia_EFCore.Migrations.SQLite
namespace FileShare_EFCore.Migrations.SQLite
{
/// <inheritdoc />
public partial class AutoMigration_20260515165835 : Migration

View File

@ -1,6 +1,6 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
@ -8,7 +8,7 @@ using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
#nullable disable
namespace Avalonia_EFCore.Migrations.SQLite
namespace FileShare_EFCore.Migrations.SQLite
{
[DbContext(typeof(SqliteAppDataContext))]
[Migration("20260520083230_AutoMigration_20260520163216")]
@ -20,7 +20,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
#pragma warning disable 612, 618
modelBuilder.HasAnnotation("ProductVersion", "10.0.7");
modelBuilder.Entity("Avalonia_EFCore.Models.ApiRefreshTokenEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ApiRefreshTokenEntity", b =>
{
b.Property<long>("Id")
.ValueGeneratedOnAdd()
@ -80,7 +80,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -131,7 +131,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()

View File

@ -1,8 +1,8 @@
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Avalonia_EFCore.Migrations.SQLite
namespace FileShare_EFCore.Migrations.SQLite
{
/// <inheritdoc />
public partial class AutoMigration_20260520163216 : Migration

View File

@ -1,6 +1,6 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
@ -8,7 +8,7 @@ using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
#nullable disable
namespace Avalonia_EFCore.Migrations.SQLite
namespace FileShare_EFCore.Migrations.SQLite
{
[DbContext(typeof(SqliteAppDataContext))]
[Migration("20260521080213_AddFileLibrary")]
@ -20,7 +20,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
#pragma warning disable 612, 618
modelBuilder.HasAnnotation("ProductVersion", "10.0.7");
modelBuilder.Entity("Avalonia_EFCore.Models.ApiRefreshTokenEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ApiRefreshTokenEntity", b =>
{
b.Property<long>("Id")
.ValueGeneratedOnAdd()
@ -80,7 +80,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.ManagedFileRecord", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ManagedFileRecord", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -170,7 +170,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.ManagedLibraryRoot", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ManagedLibraryRoot", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -237,7 +237,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -288,7 +288,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -331,9 +331,9 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.ManagedFileRecord", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ManagedFileRecord", b =>
{
b.HasOne("Avalonia_EFCore.Models.ManagedLibraryRoot", "LibraryRoot")
b.HasOne("FileShare_EFCore.Models.ManagedLibraryRoot", "LibraryRoot")
.WithMany("Files")
.HasForeignKey("LibraryRootId")
.OnDelete(DeleteBehavior.Cascade)
@ -342,7 +342,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
b.Navigation("LibraryRoot");
});
modelBuilder.Entity("Avalonia_EFCore.Models.ManagedLibraryRoot", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ManagedLibraryRoot", b =>
{
b.Navigation("Files");
});

View File

@ -1,9 +1,9 @@
using System;
using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Avalonia_EFCore.Migrations.SQLite
namespace FileShare_EFCore.Migrations.SQLite
{
/// <inheritdoc />
public partial class AddFileLibrary : Migration

View File

@ -1,13 +1,13 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
#nullable disable
namespace Avalonia_EFCore.Migrations.SQLite
namespace FileShare_EFCore.Migrations.SQLite
{
[DbContext(typeof(SqliteAppDataContext))]
partial class SqliteAppDataContextModelSnapshot : ModelSnapshot
@ -17,7 +17,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
#pragma warning disable 612, 618
modelBuilder.HasAnnotation("ProductVersion", "10.0.7");
modelBuilder.Entity("Avalonia_EFCore.Models.ApiRefreshTokenEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ApiRefreshTokenEntity", b =>
{
b.Property<long>("Id")
.ValueGeneratedOnAdd()
@ -77,7 +77,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.ManagedFileRecord", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ManagedFileRecord", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -167,7 +167,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.ManagedLibraryRoot", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ManagedLibraryRoot", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -234,7 +234,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -285,7 +285,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -328,9 +328,9 @@ namespace Avalonia_EFCore.Migrations.SQLite
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.ManagedFileRecord", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ManagedFileRecord", b =>
{
b.HasOne("Avalonia_EFCore.Models.ManagedLibraryRoot", "LibraryRoot")
b.HasOne("FileShare_EFCore.Models.ManagedLibraryRoot", "LibraryRoot")
.WithMany("Files")
.HasForeignKey("LibraryRootId")
.OnDelete(DeleteBehavior.Cascade)
@ -339,7 +339,7 @@ namespace Avalonia_EFCore.Migrations.SQLite
b.Navigation("LibraryRoot");
});
modelBuilder.Entity("Avalonia_EFCore.Models.ManagedLibraryRoot", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ManagedLibraryRoot", b =>
{
b.Navigation("Files");
});

View File

@ -1,6 +1,6 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Metadata;
@ -9,7 +9,7 @@ using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
#nullable disable
namespace Avalonia_EFCore.Migrations.SqlServer
namespace FileShare_EFCore.Migrations.SqlServer
{
[DbContext(typeof(SqlServerAppDataContext))]
[Migration("20260520082607_AutoMigration_20260520162543")]
@ -25,7 +25,7 @@ namespace Avalonia_EFCore.Migrations.SqlServer
SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
modelBuilder.Entity("Avalonia_EFCore.Models.ApiRefreshTokenEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ApiRefreshTokenEntity", b =>
{
b.Property<long>("Id")
.ValueGeneratedOnAdd()
@ -87,7 +87,7 @@ namespace Avalonia_EFCore.Migrations.SqlServer
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -134,7 +134,7 @@ namespace Avalonia_EFCore.Migrations.SqlServer
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()

View File

@ -1,9 +1,9 @@
using System;
using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Avalonia_EFCore.Migrations.SqlServer
namespace FileShare_EFCore.Migrations.SqlServer
{
/// <inheritdoc />
public partial class AutoMigration_20260520162543 : Migration

View File

@ -1,6 +1,6 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Metadata;
@ -9,7 +9,7 @@ using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
#nullable disable
namespace Avalonia_EFCore.Migrations.SqlServer
namespace FileShare_EFCore.Migrations.SqlServer
{
[DbContext(typeof(SqlServerAppDataContext))]
[Migration("20260520083242_AutoMigration_20260520163216")]
@ -25,7 +25,7 @@ namespace Avalonia_EFCore.Migrations.SqlServer
SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
modelBuilder.Entity("Avalonia_EFCore.Models.ApiRefreshTokenEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ApiRefreshTokenEntity", b =>
{
b.Property<long>("Id")
.ValueGeneratedOnAdd()
@ -87,7 +87,7 @@ namespace Avalonia_EFCore.Migrations.SqlServer
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -140,7 +140,7 @@ namespace Avalonia_EFCore.Migrations.SqlServer
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()

View File

@ -1,8 +1,8 @@
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Avalonia_EFCore.Migrations.SqlServer
namespace FileShare_EFCore.Migrations.SqlServer
{
/// <inheritdoc />
public partial class AutoMigration_20260520163216 : Migration

View File

@ -1,6 +1,6 @@
// <auto-generated />
// <auto-generated />
using System;
using Avalonia_EFCore.Database;
using FileShare_EFCore.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Metadata;
@ -8,7 +8,7 @@ using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
#nullable disable
namespace Avalonia_EFCore.Migrations.SqlServer
namespace FileShare_EFCore.Migrations.SqlServer
{
[DbContext(typeof(SqlServerAppDataContext))]
partial class SqlServerAppDataContextModelSnapshot : ModelSnapshot
@ -22,7 +22,7 @@ namespace Avalonia_EFCore.Migrations.SqlServer
SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
modelBuilder.Entity("Avalonia_EFCore.Models.ApiRefreshTokenEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.ApiRefreshTokenEntity", b =>
{
b.Property<long>("Id")
.ValueGeneratedOnAdd()
@ -84,7 +84,7 @@ namespace Avalonia_EFCore.Migrations.SqlServer
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.UserEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.UserEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
@ -137,7 +137,7 @@ namespace Avalonia_EFCore.Migrations.SqlServer
});
});
modelBuilder.Entity("Avalonia_EFCore.Models.WeatherForecastEntity", b =>
modelBuilder.Entity("FileShare_EFCore.Models.WeatherForecastEntity", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()

View File

@ -2,7 +2,7 @@ using Microsoft.EntityFrameworkCore;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace Avalonia_EFCore.Models
namespace FileShare_EFCore.Models
{
/// <summary>
/// API refresh token。只保存哈希不保存明文 token。

View File

@ -2,7 +2,7 @@ using Microsoft.EntityFrameworkCore;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace Avalonia_EFCore.Models
namespace FileShare_EFCore.Models
{
/// <summary>
/// 扫描入库的可在线查看文件。

View File

@ -2,7 +2,7 @@ using Microsoft.EntityFrameworkCore;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace Avalonia_EFCore.Models
namespace FileShare_EFCore.Models
{
/// <summary>
/// 管理端添加的文件库根目录或磁盘。

View File

@ -2,7 +2,7 @@ using Microsoft.EntityFrameworkCore;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace Avalonia_EFCore.Models
namespace FileShare_EFCore.Models
{
/// <summary>
/// 用户实体 —— 演示数据库 CRUD 操作。

View File

@ -1,4 +1,4 @@
namespace Avalonia_EFCore.Models
namespace FileShare_EFCore.Models
{
/// <summary>
/// 天气预报数据模型(内存/DTO 用,非数据库实体)。

View File

@ -2,7 +2,7 @@ using Microsoft.EntityFrameworkCore;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace Avalonia_EFCore.Models
namespace FileShare_EFCore.Models
{
/// <summary>
/// 天气预报数据实体。

View File

@ -1,7 +1,7 @@
<Application xmlns="https://github.com/avaloniaui"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
x:Class="Avalonia_PC.App"
xmlns:local="using:Avalonia_PC"
x:Class="FileShare_PC.App"
xmlns:local="using:FileShare_PC"
RequestedThemeVariant="Default">
<!-- "Default" ThemeVariant follows system theme variant. "Dark" or "Light" are other available options. -->

View File

@ -1,11 +1,11 @@
using Avalonia;
using Avalonia.Controls.ApplicationLifetimes;
using Avalonia.Markup.Xaml;
using Avalonia_PC.ViewModels;
using Avalonia_PC.Views;
using FileShare_PC.ViewModels;
using FileShare_PC.Views;
using Microsoft.Extensions.DependencyInjection;
namespace Avalonia_PC
namespace FileShare_PC
{
/// <summary>
/// Avalonia 应用程序入口类,负责初始化 XAML 资源和设置主窗口。

View File

Before

Width:  |  Height:  |  Size: 172 KiB

After

Width:  |  Height:  |  Size: 172 KiB

View File

@ -1,9 +1,9 @@
using Avalonia_Services.Services.AuthService;
using FileShare_Services.Services.AuthService;
using System;
using System.Threading;
using System.Threading.Tasks;
namespace Avalonia_PC.Authentication
namespace FileShare_PC.Authentication
{
/// <summary>
/// 第三方授权客户端占位实现。接入真实第三方接口时替换此服务即可。

View File

@ -1,11 +1,11 @@
using Authentication;
using Avalonia_Common.Core;
using Avalonia_Services.Core;
using Avalonia_Services.Services.AuthService;
using FileShare_Common.Core;
using FileShare_Services.Core;
using FileShare_Services.Services.AuthService;
using System;
using System.Threading.Tasks;
namespace Avalonia_PC.Authentication
namespace FileShare_PC.Authentication
{
/// <summary>
/// PC 端鉴权端点服务,实现 <see cref="IPcAuthEndpointService"/>

View File

@ -1,10 +1,10 @@
using Authentication;
using Avalonia_Services.Core;
using FileShare_Services.Core;
using System;
using System.Security.Claims;
using System.Threading.Tasks;
namespace Avalonia_PC.Authentication
namespace FileShare_PC.Authentication
{
/// <summary>
/// PC 端鉴权服务,基于全局 Token 验证用户身份,实现 <see cref="IAuthService"/>。

View File

@ -1,4 +1,4 @@
using Avalonia_Services.Services.AuthService;
using FileShare_Services.Services.AuthService;
using System;
using System.Security.Cryptography;
using System.Text;

View File

@ -1,4 +1,4 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>WinExe</OutputType>
<TargetFramework>net10.0</TargetFramework>
@ -41,8 +41,8 @@
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Avalonia-Services\Avalonia-Services.csproj" />
<ProjectReference Include="..\Avalonia-Common\Avalonia-Common.csproj" />
<ProjectReference Include="..\Avalonia-EFCore\Avalonia-EFCore.csproj" />
<ProjectReference Include="..\FileShare-Services\FileShare-Services.csproj" />
<ProjectReference Include="..\FileShare-Common\FileShare-Common.csproj" />
<ProjectReference Include="..\FileShare-EFCore\FileShare-EFCore.csproj" />
</ItemGroup>
</Project>

View File

@ -1,9 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<DebuggerFlavor>ProjectDebugger</DebuggerFlavor>
</PropertyGroup>
<PropertyGroup>
<ActiveDebugProfile>Avalonia-PC</ActiveDebugProfile>
<ActiveDebugProfile>FileShare-PC</ActiveDebugProfile>
</PropertyGroup>
</Project>

View File

@ -0,0 +1,11 @@
<Solution>
<Project Path="../FileShare-API/FileShare-API.csproj" Id="e33aba9a-a56b-4f6b-8eaa-3acbed65ebad" />
<Project Path="../FileShare-Common/FileShare-Common.csproj" Id="caed4118-2161-4382-90b8-35fb4efe3b5f" />
<Project Path="../FileShare-EFCore/FileShare-EFCore.csproj" Id="64557501-62a7-4863-b2bf-1570b8c6fecb" />
<Project Path="../FileShare-Services/FileShare-Services.csproj" Id="b8757cf9-5422-4c67-acae-3c967c95f866" />
<Project Path="../FileShare-Web-VUE/fileshare-web-vue.esproj">
<Build />
<Deploy />
</Project>
<Project Path="FileShare-PC.csproj" />
</Solution>

View File

@ -1,19 +1,19 @@
using Authentication;
using Authentication;
using Avalonia;
using Avalonia_Common.Infrastructure;
using Avalonia_EFCore.Database;
using Avalonia_PC.Authentication;
using Avalonia_PC.Views;
using Avalonia_Services.Core;
using Avalonia_Services.Endpoints;
using Avalonia_Services.Services;
using Avalonia_Services.Services.AuthService;
using Avalonia_Services.Services.FileLibrary;
using FileShare_Common.Infrastructure;
using FileShare_EFCore.Database;
using FileShare_PC.Authentication;
using FileShare_PC.Views;
using FileShare_Services.Core;
using FileShare_Services.Endpoints;
using FileShare_Services.Services;
using FileShare_Services.Services.AuthService;
using FileShare_Services.Services.FileLibrary;
using Microsoft.Extensions.DependencyInjection;
using Serilog;
using System;
namespace Avalonia_PC
namespace FileShare_PC
{
/// <summary>
/// 桌面应用程序入口类,负责配置 DI 容器、初始化数据库和启动 Avalonia 框架。
@ -35,7 +35,7 @@ namespace Avalonia_PC
// 初始化日志系统
AppLog.Initialize(LoggingConfiguration.CreateDefaultLogger(logDir: "logs"));
AppLog.Information("Avalonia-PC 正在启动...");
AppLog.Information("FileShare-PC 正在启动...");
ConfigureServices();

View File

@ -1,6 +1,6 @@
{
"profiles": {
"Avalonia-PC": {
"FileShare-PC": {
"commandName": "Project"
},
"WSL": {

View File

@ -1,10 +1,10 @@
using Avalonia.Controls;
using Avalonia.Controls.Templates;
using Avalonia_PC.ViewModels;
using FileShare_PC.ViewModels;
using System;
using System.Diagnostics.CodeAnalysis;
namespace Avalonia_PC
namespace FileShare_PC
{
/// <summary>
/// Given a view model, returns the corresponding view if possible.

View File

@ -1,4 +1,4 @@
namespace Avalonia_PC.ViewModels
namespace FileShare_PC.ViewModels
{
/// <summary>
/// 主窗口的 ViewModel提供问候语等绑定属性。
@ -8,6 +8,6 @@
/// <summary>
/// 获取问候语文本。
/// </summary>
public string Greeting { get; } = "Welcome to Avalonia!";
public string Greeting { get; } = "Welcome to FileShare!";
}
}

View File

@ -1,6 +1,6 @@
using CommunityToolkit.Mvvm.ComponentModel;
using CommunityToolkit.Mvvm.ComponentModel;
namespace Avalonia_PC.ViewModels
namespace FileShare_PC.ViewModels
{
/// <summary>
/// ViewModel 基类,继承自 CommunityToolkit.Mvvm 的 ObservableObject

View File

@ -1,4 +1,4 @@
namespace Avalonia_PC.Views
namespace FileShare_PC.Views
{
/// <summary>
/// MainWindow 的分部类,定义注入 WebView2 的 JavaScript Bridge 脚本。

View File

@ -1,13 +1,13 @@
using Avalonia_Services.Core;
using Avalonia_Services.Endpoints;
using Avalonia_Services.Extensions;
using Avalonia_Services.Services;
using FileShare_Services.Core;
using FileShare_Services.Endpoints;
using FileShare_Services.Extensions;
using FileShare_Services.Services;
using Microsoft.Extensions.DependencyInjection;
using System;
using System.Collections.Generic;
using System.Threading.Tasks;
namespace Avalonia_PC.Views
namespace FileShare_PC.Views
{
/// <summary>
/// MainWindow 的分部类,负责路由注册和统一端点适配。
@ -16,7 +16,7 @@ namespace Avalonia_PC.Views
{
/// <summary>
/// 统一端点适配器(替代原来的 _routes 字典)。
/// 所有端点在 Avalonia-Services/AppEndpoints.cs 中统一定义。
/// 所有端点在 FileShare-Services/AppEndpoints.cs 中统一定义。
/// </summary>
private DesktopEndpointAdapter _endpointAdapter = null!;

View File

@ -2,13 +2,13 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:vm="using:Avalonia_PC.ViewModels"
xmlns:vm="using:FileShare_PC.ViewModels"
xmlns:webview="clr-namespace:Avalonia.Controls;assembly=Avalonia.Controls.WebView"
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
x:Class="Avalonia_PC.Views.MainWindow"
x:Class="FileShare_PC.Views.MainWindow"
x:DataType="vm:MainWindowViewModel"
Icon="/Assets/avalonia-logo.ico"
Title="Avalonia_PC">
Title="FileShare_PC">
<Design.DataContext>
<!-- This only sets the DataContext for the previewer in an IDE,

View File

@ -9,10 +9,10 @@ using System.Reflection;
using System.Text.Json;
using System.Threading;
using System.Threading.Tasks;
using Avalonia_Services.Services.FileLibrary;
using FileShare_Services.Services.FileLibrary;
using Microsoft.Extensions.DependencyInjection;
namespace Avalonia_PC.Views
namespace FileShare_PC.Views
{
/// <summary>
/// 主窗口,承载 WebView2 控件并管理前后端 Bridge 通信。
@ -591,7 +591,7 @@ namespace Avalonia_PC.Views
}
/// <summary>
/// Handle media element requests using the same stream path as Avalonia-API.
/// Handle media element requests using the same stream path as FileShare-API.
/// </summary>
private async Task<bool> TryHandleLocalMediaStreamAsync(HttpListenerContext context)
{

View File

@ -1,9 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<assembly manifestVersion="1.0" xmlns="urn:schemas-microsoft-com:asm.v1">
<!-- This manifest is used on Windows only.
Don't remove it as it might cause problems with window transparency and embedded controls.
For more details visit https://learn.microsoft.com/en-us/windows/win32/sbscs/application-manifests -->
<assemblyIdentity version="1.0.0.0" name="Avalonia_PC.Desktop"/>
<assemblyIdentity version="1.0.0.0" name="FileShare_PC.Desktop"/>
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
<application>

View File

@ -1,7 +1,7 @@
using System;
using System.Linq;
namespace Avalonia_Services.Core
namespace FileShare_Services.Core
{
/// <summary>
/// 端点列表打印工具 —— 在应用启动时输出所有已注册的拦截接口。

View File

@ -1,4 +1,4 @@
namespace Avalonia_Services.Core
namespace FileShare_Services.Core
{
/// <summary>
/// 文件流响应 —— 管道检测到此类型时将返回原始文件而非 JSON。

View File

@ -1,8 +1,8 @@
using Avalonia_Common.Core;
using FileShare_Common.Core;
using System;
using System.Threading.Tasks;
namespace Avalonia_Services.Core
namespace FileShare_Services.Core
{
/// <summary>
/// 全局异常拦截过滤器 —— 自动包裹所有端点处理器,无需在每个方法中写 try-catch。

View File

@ -1,6 +1,6 @@
using System.Security.Claims;
namespace Avalonia_Services.Core
namespace FileShare_Services.Core
{
/// <summary>
/// 鉴权服务抽象 —— 各宿主按自己的方式实现JWT / Cookie / Token 等)。

View File

@ -1,6 +1,6 @@
using System.Threading.Tasks;
namespace Avalonia_Services.Core
namespace FileShare_Services.Core
{
/// <summary>
/// 端点过滤器抽象 —— 在请求处理前后执行逻辑。

View File

@ -1,10 +1,10 @@
using Avalonia_Common.Core;
using FileShare_Common.Core;
using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using Microsoft.Extensions.DependencyInjection;
namespace Avalonia_Services.Core
namespace FileShare_Services.Core
{
/// <summary>
/// 端点挂载的宿主目标。
@ -12,9 +12,9 @@ namespace Avalonia_Services.Core
[Flags]
public enum EndpointHostTarget
{
/// <summary>挂载到 Avalonia-APIASP.NET Core Web API。</summary>
/// <summary>挂载到 FileShare-APIASP.NET Core Web API。</summary>
Api = 1,
/// <summary>挂载到 Avalonia-PC桌面 WebView。</summary>
/// <summary>挂载到 FileShare-PC桌面 WebView。</summary>
Pc = 2,
/// <summary>同时挂载到 API 和 PC。</summary>
All = Api | Pc,
@ -121,7 +121,7 @@ namespace Avalonia_Services.Core
}
/// <summary>
/// 只挂载到 Avalonia-API。
/// 只挂载到 FileShare-API。
/// </summary>
public ServiceEndpoint ApiOnly()
{
@ -130,7 +130,7 @@ namespace Avalonia_Services.Core
}
/// <summary>
/// 只挂载到 Avalonia-PC。
/// 只挂载到 FileShare-PC。
/// </summary>
public ServiceEndpoint PcOnly()
{
@ -150,7 +150,7 @@ namespace Avalonia_Services.Core
}
/// <summary>
/// 端点集合 —— 所有端点的注册中心。在 Avalonia-Services 中统一配置。
/// 端点集合 —— 所有端点的注册中心。在 FileShare-Services 中统一配置。
/// </summary>
public class ServiceEndpointCollection
{

View File

@ -1,6 +1,6 @@
using System.Collections.Generic;
namespace Avalonia_Services.Core
namespace FileShare_Services.Core
{
/// <summary>
/// 抽象的请求上下文屏蔽不同宿主ASP.NET Core / Desktop WebView的差异。

View File

@ -1,4 +1,4 @@
namespace Avalonia_Services.Core
namespace FileShare_Services.Core
{
/// <summary>
/// Matches unified endpoint patterns and extracts simple route values.

View File

@ -1,7 +1,7 @@
using System.Text.Json;
using System.Text.Json.Serialization;
namespace Avalonia_Services.Core
namespace FileShare_Services.Core
{
/// <summary>
/// Binds unified endpoint request models from JSON bodies or query parameters.

View File

@ -1,13 +1,13 @@
using Avalonia_Common.Core;
using Avalonia_Services.Core;
using Avalonia_Services.Services.FileLibrary;
using Avalonia_Services.Services.QrCode;
using FileShare_Common.Core;
using FileShare_Services.Core;
using FileShare_Services.Services.FileLibrary;
using FileShare_Services.Services.QrCode;
namespace Avalonia_Services.Endpoints
namespace FileShare_Services.Endpoints
{
/// <summary>
/// 统一端点配置 —— 所有业务端点在此定义一次。
/// 这是 Avalonia-API 和 Avalonia-PC 的唯一入口。
/// 这是 FileShare-API 和 FileShare-PC 的唯一入口。
/// </summary>
public static class AppEndpoints
{

View File

@ -1,7 +1,7 @@
using Avalonia_Services.Core;
using Avalonia_Services.Services.AuthService;
using FileShare_Services.Core;
using FileShare_Services.Services.AuthService;
namespace Avalonia_Services.Endpoints
namespace FileShare_Services.Endpoints
{
/// <summary>
/// 认证端点统一入口。端点定义在这里,宿主项目只提供对应实现。

View File

@ -1,9 +1,9 @@
using Avalonia_Services.Core;
using FileShare_Services.Core;
namespace Avalonia_Services.Extensions
namespace FileShare_Services.Extensions
{
/// <summary>
/// Desktop (Avalonia-PC) 端点适配器。
/// Desktop (FileShare-PC) 端点适配器。
/// 将统一端点转换为桌面端可用的路由处理器,支持过滤器和鉴权管道。
/// </summary>
public class DesktopEndpointAdapter

View File

@ -1,8 +1,8 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net10.0</TargetFramework>
<RootNamespace>Avalonia_Services</RootNamespace>
<RootNamespace>FileShare_Services</RootNamespace>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>
@ -18,8 +18,8 @@
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Avalonia-Common\Avalonia-Common.csproj" />
<ProjectReference Include="..\Avalonia-EFCore\Avalonia-EFCore.csproj" />
<ProjectReference Include="..\FileShare-Common\FileShare-Common.csproj" />
<ProjectReference Include="..\FileShare-EFCore\FileShare-EFCore.csproj" />
</ItemGroup>
</Project>

View File

@ -1,4 +1,4 @@
namespace Avalonia_Services.Services.AuthService
namespace FileShare_Services.Services.AuthService
{
/// <summary>
/// API 登录请求。

View File

@ -1,8 +1,8 @@
using Avalonia_Common.Core;
using Avalonia_Services.Core;
using FileShare_Common.Core;
using FileShare_Services.Core;
using System.Threading.Tasks;
namespace Avalonia_Services.Services.AuthService
namespace FileShare_Services.Services.AuthService
{
/// <summary>
/// API 鉴权端点服务接口,定义登录、刷新 Token 和登出操作。

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