1、根据数据表,删除表数据接口迁移至DataModel 已有接口下
2、将根据表明生成实体类,代码迁移至已有数据接口DataModel下
This commit is contained in:
@@ -1,7 +0,0 @@
|
||||
namespace Tnb.BasicData.Entitys
|
||||
{
|
||||
public class Class1
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1,26 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using JNPF.DependencyInjection;
|
||||
|
||||
namespace Tnb.BasicData.Entitys.Dto.DataModeing
|
||||
{
|
||||
/// <summary>
|
||||
/// 清除表数据输入参数
|
||||
/// </summary>
|
||||
[SuppressSniffer]
|
||||
public class CleanTableDataInput
|
||||
{
|
||||
public string LinkId { get; set; }
|
||||
/// <summary>
|
||||
/// 数据库名称
|
||||
/// </summary>
|
||||
public string DbName { get; set; }
|
||||
/// <summary>
|
||||
/// 表名称
|
||||
/// </summary>
|
||||
public string TableName { get; set; }
|
||||
}
|
||||
}
|
||||
19
Tnb.BasicData.Entitys/Mapper/Mapper.cs
Normal file
19
Tnb.BasicData.Entitys/Mapper/Mapper.cs
Normal file
@@ -0,0 +1,19 @@
|
||||
using JNPF.Systems.Entitys.System;
|
||||
using Mapster;
|
||||
using SqlSugar;
|
||||
|
||||
namespace Tnb.BasicData.Entitys.Mapper
|
||||
{
|
||||
public class Mapper : IRegister
|
||||
{
|
||||
public void Register(TypeAdapterConfig config)
|
||||
{
|
||||
config.ForType<ConnectionStringsOptions, ConnectionConfig>()
|
||||
.Map(dest => dest.ConnectionString, src => src.DefaultConnection)
|
||||
.AfterMapping((src, dest) =>
|
||||
{
|
||||
dest.ConnectionString = string.Format(src.DefaultConnection, src.Host, src.Port, src.DBName, src.UserName, src.Password);
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7,6 +7,7 @@
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\common\Tnb.Common.Core\Tnb.Common.Core.csproj" />
|
||||
<ProjectReference Include="..\common\Tnb.Common\Tnb.Common.csproj" />
|
||||
<ProjectReference Include="..\common\Tnb.SqlSugar\Tnb.SqlSugar.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
Reference in New Issue
Block a user