mirror of
https://github.com/nsnail/FreeSql.git
synced 2025-06-20 04:48:16 +08:00
Merge pull request #1130 from hd2y/issues@1113
DynamicFilterCustom 增加支持 Expression 返回值
This commit is contained in:
@ -832,8 +832,8 @@ namespace FreeSql.Internal.CommonProvider
|
||||
var fiValue0MethodReturn = fiValue0Method?.Invoke(null, fiValue0Method.GetParameters()
|
||||
.Select(a => a.ParameterType == typeof(object) ? (object)this :
|
||||
(a.ParameterType == typeof(string) ? (object)(fi.Value?.ToString()) : (object)null))
|
||||
.ToArray())?.ToString();
|
||||
exp = Expression.Call(typeof(SqlExt).GetMethod("InternalRawSql", BindingFlags.NonPublic | BindingFlags.Static), Expression.Constant(fiValue0MethodReturn, typeof(string)));
|
||||
.ToArray());
|
||||
exp = fiValue0MethodReturn is Expression expression ? expression : Expression.Call(typeof(SqlExt).GetMethod("InternalRawSql", BindingFlags.NonPublic | BindingFlags.Static), Expression.Constant(fiValue0MethodReturn?.ToString(), typeof(string)));
|
||||
break;
|
||||
|
||||
case DynamicFilterOperator.Contains:
|
||||
|
Reference in New Issue
Block a user