feat:基于furion搭建
This commit is contained in:
15
Yi.Furion.Rbac/Yi.Furion.Rbac.Application/GlobalUsings.cs
Normal file
15
Yi.Furion.Rbac/Yi.Furion.Rbac.Application/GlobalUsings.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
global using Furion;
|
||||
global using Furion.DatabaseAccessor;
|
||||
global using Furion.DataEncryption;
|
||||
global using Furion.DataValidation;
|
||||
global using Furion.DependencyInjection;
|
||||
global using Furion.DynamicApiController;
|
||||
global using Furion.Extensions;
|
||||
global using Furion.FriendlyException;
|
||||
global using Furion.Logging;
|
||||
global using Mapster;
|
||||
global using Microsoft.AspNetCore.Authorization;
|
||||
global using Microsoft.AspNetCore.Http;
|
||||
global using Microsoft.AspNetCore.Mvc;
|
||||
global using Microsoft.CodeAnalysis;
|
||||
global using System.ComponentModel.DataAnnotations;
|
||||
@@ -0,0 +1,8 @@
|
||||
namespace Yi.Furion.Rbac.Application;
|
||||
|
||||
public class Mapper : IRegister
|
||||
{
|
||||
public void Register(TypeAdapterConfig config)
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
namespace Yi.Furion.Rbac.Application;
|
||||
|
||||
public interface ISystemService
|
||||
{
|
||||
string GetDescription();
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
namespace Yi.Furion.Rbac.Application;
|
||||
|
||||
public class SystemService : ISystemService, ITransient
|
||||
{
|
||||
public string GetDescription()
|
||||
{
|
||||
return "让 .NET 开发更简单,更通用,更流行。";
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
namespace Yi.Furion.Rbac.Application;
|
||||
|
||||
/// <summary>
|
||||
/// 系统服务接口
|
||||
/// </summary>
|
||||
public class SystemAppService : IDynamicApiController
|
||||
{
|
||||
private readonly ISystemService _systemService;
|
||||
public SystemAppService(ISystemService systemService)
|
||||
{
|
||||
_systemService = systemService;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取系统描述
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public string GetDescription()
|
||||
{
|
||||
return _systemService.GetDescription();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<NoWarn>1701;1702;1591</NoWarn>
|
||||
<DocumentationFile>Yi.Furion.Rbac.Application.xml</DocumentationFile>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
</PropertyGroup>
|
||||
|
||||
|
||||
|
||||
<ItemGroup>
|
||||
<None Remove="applicationsettings.json" />
|
||||
<None Remove="Yi.Furion.Rbac.Application.xml" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Content Include="applicationsettings.json">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
</Content>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Yi.Furion.Rbac.Core\Yi.Furion.Rbac.Core.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Folder Include="System\Services\" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
@@ -0,0 +1,19 @@
|
||||
<?xml version="1.0"?>
|
||||
<doc>
|
||||
<assembly>
|
||||
<name>Yi.Furion.Rbac.Application</name>
|
||||
</assembly>
|
||||
<members>
|
||||
<member name="T:Yi.Furion.Rbac.Application.SystemAppService">
|
||||
<summary>
|
||||
系统服务接口
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:Yi.Furion.Rbac.Application.SystemAppService.GetDescription">
|
||||
<summary>
|
||||
获取系统描述
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
</members>
|
||||
</doc>
|
||||
@@ -0,0 +1,31 @@
|
||||
{
|
||||
"$schema": "https://gitee.com/dotnetchina/Furion/raw/v4/schemas/v4/furion-schema.json",
|
||||
"SpecificationDocumentSettings": {
|
||||
"DocumentTitle": "Furion | 规范化接口",
|
||||
"GroupOpenApiInfos": [
|
||||
{
|
||||
"Group": "Default",
|
||||
"Title": "规范化接口演示",
|
||||
"Description": "让 .NET 开发更简单,更通用,更流行。",
|
||||
"Version": "1.0.0",
|
||||
"TermsOfService": "https://furion.baiqian.ltd",
|
||||
"Contact": {
|
||||
"Name": "百小僧",
|
||||
"Url": "https://gitee.com/monksoul",
|
||||
"Email": "monksoul@outlook.com"
|
||||
},
|
||||
"License": {
|
||||
"Name": "Apache-2.0",
|
||||
"Url": "https://gitee.com/dotnetchina/Furion/blob/rc1/LICENSE"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"CorsAccessorSettings": {
|
||||
"WithExposedHeaders": [
|
||||
"access-token",
|
||||
"x-access-token",
|
||||
"environment"
|
||||
]
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user