mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-05-03 04:13:48 +08:00
Update exp to sql
This commit is contained in:
parent
2d214c3d52
commit
5576c68142
@ -127,7 +127,11 @@ namespace SqlSugar
|
||||
case ResolveExpressType.FieldMultiple:
|
||||
if (express.Method.Name == "ToString" && express.Object != null && express.Object?.Type == UtilConstants.DateType)
|
||||
{
|
||||
var format = (args[0] as ConstantExpression).Value + "";
|
||||
var format = (args[0] as ConstantExpression)?.Value + "";
|
||||
if (format == ""&& args[0] is MemberExpression)
|
||||
{
|
||||
format = ExpressionTool.GetExpressionValue(args[0]) + "";
|
||||
}
|
||||
var value = GetNewExpressionValue(express.Object);
|
||||
var dateString2 = this.Context.DbMehtods.GetDateString(value, format);
|
||||
if (dateString2 == null)
|
||||
|
Loading…
Reference in New Issue
Block a user