chore: 构建稳定版本

This commit is contained in:
陈淳
2023-12-11 09:55:12 +08:00
parent 098d4bc85f
commit 769a6a9c63
756 changed files with 10431 additions and 19867 deletions

View File

@@ -0,0 +1,24 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Mapster;
using Volo.Abp.ObjectMapping;
namespace Yi.Framework.Mapster
{
public class MapsterAutoObjectMappingProvider : IAutoObjectMappingProvider
{
public TDestination Map<TSource, TDestination>(object source)
{
var sss = typeof(TDestination).Name;
return source.Adapt<TDestination>();
}
public TDestination Map<TSource, TDestination>(TSource source, TDestination destination)
{
return source.Adapt<TSource, TDestination>(destination);
}
}
}

View File

@@ -0,0 +1,24 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Volo.Abp.ObjectMapping;
namespace Yi.Framework.Mapster
{
public class MapsterObjectMapper : IObjectMapper
{
public IAutoObjectMappingProvider AutoObjectMappingProvider => throw new NotImplementedException();
public TDestination Map<TSource, TDestination>(TSource source)
{
throw new NotImplementedException();
}
public TDestination Map<TSource, TDestination>(TSource source, TDestination destination)
{
throw new NotImplementedException();
}
}
}

View File

@@ -0,0 +1,18 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\..\common.props" />
<PropertyGroup>
<TargetFramework>net7.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Mapster" Version="7.4.0" />
<PackageReference Include="Volo.Abp.ObjectMapping" Version="7.4.2" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Yi.Framework.Core\Yi.Framework.Core.csproj" />
</ItemGroup>
</Project>

View File

@@ -0,0 +1,8 @@
<?xml version="1.0"?>
<doc>
<assembly>
<name>Yi.Framework.Mapster</name>
</assembly>
<members>
</members>
</doc>

View File

@@ -0,0 +1,21 @@
using MapsterMapper;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.DependencyInjection.Extensions;
using Volo.Abp.Modularity;
using Volo.Abp.ObjectMapping;
using Yi.Framework.Core;
namespace Yi.Framework.Mapster
{
[DependsOn(typeof(YiFrameworkCoreModule),
typeof(AbpObjectMappingModule)
)]
public class YiFrameworkMapsterModule : AbpModule
{
public override void ConfigureServices(ServiceConfigurationContext context)
{
context.Services.AddTransient<IAutoObjectMappingProvider, MapsterAutoObjectMappingProvider>();
}
}
}