mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-04-05 17:37:58 +08:00
Add user test case
This commit is contained in:
parent
ffec21f6fc
commit
efda3d11f8
@ -33,6 +33,7 @@ namespace OrmTest
|
|||||||
}
|
}
|
||||||
public static void Init()
|
public static void Init()
|
||||||
{
|
{
|
||||||
|
Unitadf1yaadfa.Init();
|
||||||
CrossDatabase03.Init();
|
CrossDatabase03.Init();
|
||||||
CrossDatabase02.Init();
|
CrossDatabase02.Init();
|
||||||
UnitDynamicCoread12321.Init();
|
UnitDynamicCoread12321.Init();
|
||||||
|
@ -0,0 +1,42 @@
|
|||||||
|
using SqlSugar;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace OrmTest
|
||||||
|
{
|
||||||
|
internal class Unitadf1yaadfa
|
||||||
|
{
|
||||||
|
public static void Init()
|
||||||
|
{
|
||||||
|
var db = NewUnitTest.Db;
|
||||||
|
}
|
||||||
|
|
||||||
|
public class UnitOrderfafaadfa
|
||||||
|
{
|
||||||
|
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||||
|
public int Id { get; set; }
|
||||||
|
|
||||||
|
public string Name { get; set; }
|
||||||
|
public decimal Price { get; set; }
|
||||||
|
[SugarColumn(IsNullable = true)]
|
||||||
|
public DateTime? CreateTime { get; set; }
|
||||||
|
[SugarColumn(IsNullable = true)]
|
||||||
|
public int CustomId { get; set; }
|
||||||
|
}
|
||||||
|
|
||||||
|
public class UnitOrderItemafdaa
|
||||||
|
{
|
||||||
|
[SqlSugar.SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
|
||||||
|
public int ItemId { get; set; }
|
||||||
|
public int OrderId { get; set; }
|
||||||
|
public decimal? Price { get; set; }
|
||||||
|
[SqlSugar.SugarColumn(IsNullable = true)]
|
||||||
|
public DateTime? CreateTime { get; set; }
|
||||||
|
[Navigate(NavigateType.OneToOne, nameof(OrderId))]
|
||||||
|
public UnitOrderfafaadfa Order { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user