mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-09-21 02:58:05 +08:00
Add user test case
This commit is contained in:
@@ -3,6 +3,7 @@ using System.Collections.Generic;
|
|||||||
using System.Text;
|
using System.Text;
|
||||||
using SqlSugar;
|
using SqlSugar;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
using System.Net.Http.Headers;
|
||||||
namespace OrmTest
|
namespace OrmTest
|
||||||
{
|
{
|
||||||
public class CrossDatabase02
|
public class CrossDatabase02
|
||||||
@@ -45,7 +46,28 @@ namespace OrmTest
|
|||||||
|
|
||||||
|
|
||||||
db.DbMaintenance.DropTable<UnitPkadfa2>();
|
db.DbMaintenance.DropTable<UnitPkadfa2>();
|
||||||
|
db.CodeFirst.InitTables<UnitIndexaa>();
|
||||||
|
db.Aop.DataExecuting = (x, y) =>
|
||||||
|
{
|
||||||
|
|
||||||
|
};
|
||||||
|
db.Insertable(new UnitIndexaa() { id = 1 }).ExecuteCommand();
|
||||||
|
db.Updateable(new UnitIndexaa() { id = 1 }).ExecuteCommand();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public class UnitIndexaa
|
||||||
|
{
|
||||||
|
string[] ids = new string[] { };
|
||||||
|
[SugarColumn(IsIgnore =true)]
|
||||||
|
public object this[int i]
|
||||||
|
{
|
||||||
|
get {
|
||||||
|
return ids[i];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public int id { get; set; }
|
||||||
|
}
|
||||||
|
|
||||||
[SugarTable("UnitPkadfa")]
|
[SugarTable("UnitPkadfa")]
|
||||||
public class UnitPkadfa1
|
public class UnitPkadfa1
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user