- 增加 Pgsql JToken/JObject/JArray 索引访问的表达式解析;

- 增加 object.Equals 表达式解析;
This commit is contained in:
28810
2020-03-19 22:46:40 +08:00
parent 5f166c08aa
commit a5e6573851
5 changed files with 50 additions and 49 deletions

View File

@ -675,8 +675,11 @@ namespace FreeSql.Internal
case "System.Convert": other3Exp = ExpressionLambdaToSqlCallConvert(exp3, tsc); break;
}
if (string.IsNullOrEmpty(other3Exp) == false) return other3Exp;
if (exp3.Method.Name == "Equals" && exp3.Object != null && exp3.Arguments.Count > 0)
return ExpressionBinary("=", exp3.Object, exp3.Arguments[0], tsc);
if (exp3.Method.Name == "Equals")
{
if (exp3.Arguments.Count > 0 && exp3.Object != null) return ExpressionBinary("=", exp3.Object, exp3.Arguments[0], tsc);
if (exp3.Arguments.Count > 1 && exp3.Method.DeclaringType == typeof(object)) return ExpressionBinary("=", exp3.Arguments[0], exp3.Arguments[1], tsc);
}
if (callType.FullName.StartsWith("FreeSql.ISelectGroupingAggregate`"))
{
//if (exp3.Type == typeof(string) && exp3.Arguments.Any() && exp3.Arguments[0].NodeType == ExpressionType.Constant) {