mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-09-20 02:29:39 +08:00
Update nav query
This commit is contained in:
@@ -53,7 +53,7 @@ namespace SqlSugar
|
|||||||
}
|
}
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
public EntityColumnable<T> OneToMany(Expression<Func<T, object>> propertyExpression, string firstName, string lastName)
|
public EntityColumnable<T> OneToMany(Expression<Func<T, object>> propertyExpression, string firstName, string lastName=null)
|
||||||
{
|
{
|
||||||
var name = ExpressionTool.GetMemberName(propertyExpression);
|
var name = ExpressionTool.GetMemberName(propertyExpression);
|
||||||
if (entityColumnInfo.PropertyName == name && IsTable)
|
if (entityColumnInfo.PropertyName == name && IsTable)
|
||||||
@@ -63,6 +63,16 @@ namespace SqlSugar
|
|||||||
}
|
}
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
public EntityColumnable<T> OneToManyByArrayList(Expression<Func<T, object>> propertyExpression, string firstName, string lastName=null)
|
||||||
|
{
|
||||||
|
var name = ExpressionTool.GetMemberName(propertyExpression);
|
||||||
|
if (entityColumnInfo.PropertyName == name && IsTable)
|
||||||
|
{
|
||||||
|
entityColumnInfo.Navigat = new Navigate(NavigateType.OneToManyByArrayList, firstName, lastName);
|
||||||
|
entityColumnInfo.IsIgnore = true;
|
||||||
|
}
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
public EntityColumnable<T> ManyToMany(Expression<Func<T, object>> propertyExpression,Type mapppingType, string mapppingTypeAid, string mapppingTypeBid)
|
public EntityColumnable<T> ManyToMany(Expression<Func<T, object>> propertyExpression,Type mapppingType, string mapppingTypeAid, string mapppingTypeBid)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user