mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-10-15 18:55:07 +08:00
-
This commit is contained in:
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -14,6 +14,7 @@ namespace SqlSugar
|
||||
public Expression BaseExpression { get; set; }
|
||||
public int Index { get; set; }
|
||||
public List<KeyValuePair<string, BinaryExpressionInfo>> BinaryExpressionInfoList { get; set; }
|
||||
public object TempDate { get; set; }
|
||||
public ExpressionParameter BaseParameter { get; set; }
|
||||
}
|
||||
}
|
||||
|
@@ -15,10 +15,12 @@ namespace SqlSugar
|
||||
object value = expression.Value;
|
||||
switch (parameter.Context.ResolveType)
|
||||
{
|
||||
case ResolveExpressType.WhereSingle:
|
||||
case ResolveExpressType.WhereMultiple:
|
||||
case ResolveExpressType.SelectSingle:
|
||||
case ResolveExpressType.SelectMultiple:
|
||||
parameter.BaseParameter.TempDate = value;
|
||||
break;
|
||||
case ResolveExpressType.WhereSingle:
|
||||
case ResolveExpressType.WhereMultiple:
|
||||
case ResolveExpressType.FieldSingle:
|
||||
case ResolveExpressType.FieldMultiple:
|
||||
default:
|
||||
|
@@ -46,10 +46,11 @@ namespace SqlSugar
|
||||
MemberAssignment memberAssignment = (MemberAssignment)binding;
|
||||
if (memberAssignment.Expression.NodeType == ExpressionType.Constant)
|
||||
{
|
||||
var value = ((ConstantExpression)memberAssignment.Expression).Value;
|
||||
base.Expression = memberAssignment.Expression;
|
||||
base.Start();
|
||||
string parameterName = this.Context.SqlParameterKeyWord + "constant" + i;
|
||||
parameter.Context.Result.Append(parameterName);
|
||||
this.Context.Parameters.Add(new SugarParameter(parameterName, value));
|
||||
this.Context.Parameters.Add(new SugarParameter(parameterName, parameter.TempDate));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user