mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-05-05 21:27:58 +08:00
-
This commit is contained in:
parent
d3dc965a32
commit
315541bd3a
Binary file not shown.
BIN
OrmTest/bin/Debug/Newtonsoft.Json.dll
Normal file
BIN
OrmTest/bin/Debug/Newtonsoft.Json.dll
Normal file
Binary file not shown.
BIN
OrmTest/bin/Debug/OrmTest.exe
Normal file
BIN
OrmTest/bin/Debug/OrmTest.exe
Normal file
Binary file not shown.
6
OrmTest/bin/Debug/OrmTest.exe.config
Normal file
6
OrmTest/bin/Debug/OrmTest.exe.config
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8" ?>
|
||||||
|
<configuration>
|
||||||
|
<startup>
|
||||||
|
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" />
|
||||||
|
</startup>
|
||||||
|
</configuration>
|
BIN
OrmTest/bin/Debug/OrmTest.pdb
Normal file
BIN
OrmTest/bin/Debug/OrmTest.pdb
Normal file
Binary file not shown.
BIN
OrmTest/bin/Debug/SqlSugar.dll
Normal file
BIN
OrmTest/bin/Debug/SqlSugar.dll
Normal file
Binary file not shown.
BIN
OrmTest/bin/Debug/SqlSugar.pdb
Normal file
BIN
OrmTest/bin/Debug/SqlSugar.pdb
Normal file
Binary file not shown.
BIN
OrmTest/obj/Debug/OrmTest.csprojResolveAssemblyReference.cache
Normal file
BIN
OrmTest/obj/Debug/OrmTest.csprojResolveAssemblyReference.cache
Normal file
Binary file not shown.
BIN
OrmTest/obj/Debug/OrmTest.exe
Normal file
BIN
OrmTest/obj/Debug/OrmTest.exe
Normal file
Binary file not shown.
BIN
OrmTest/obj/Debug/OrmTest.pdb
Normal file
BIN
OrmTest/obj/Debug/OrmTest.pdb
Normal file
Binary file not shown.
@ -1,11 +0,0 @@
|
|||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
|
|
||||||
namespace SqlSugar
|
|
||||||
{
|
|
||||||
public class ExpInfo
|
|
||||||
{
|
|
||||||
}
|
|
||||||
}
|
|
@ -8,6 +8,7 @@ namespace SqlSugar
|
|||||||
public class BaseResolve
|
public class BaseResolve
|
||||||
{
|
{
|
||||||
protected Expression Expression { get; set; }
|
protected Expression Expression { get; set; }
|
||||||
|
protected Expression BaseExpression { get; set; }
|
||||||
public ExpressionContext Context { get; set; }
|
public ExpressionContext Context { get; set; }
|
||||||
public string SqlWhere { get; set; }
|
public string SqlWhere { get; set; }
|
||||||
public bool IsFinished { get; set; }
|
public bool IsFinished { get; set; }
|
||||||
@ -34,7 +35,7 @@ namespace SqlSugar
|
|||||||
Context = this.Context,
|
Context = this.Context,
|
||||||
Expression = exp,
|
Expression = exp,
|
||||||
IsLeft = this.IsLeft,
|
IsLeft = this.IsLeft,
|
||||||
BaseExpression=this.Expression
|
BaseExpression=this.BaseExpression
|
||||||
};
|
};
|
||||||
if (exp is LambdaExpression)
|
if (exp is LambdaExpression)
|
||||||
{
|
{
|
||||||
|
@ -10,7 +10,7 @@ namespace SqlSugar
|
|||||||
public BinaryExpressionResolve(ExpressionParameter parameter) : base(parameter)
|
public BinaryExpressionResolve(ExpressionParameter parameter) : base(parameter)
|
||||||
{
|
{
|
||||||
var expression = this.Expression as BinaryExpression;
|
var expression = this.Expression as BinaryExpression;
|
||||||
var baseExpression = parameter.Expression;
|
base.BaseExpression = expression;
|
||||||
base.IsLeft = true;
|
base.IsLeft = true;
|
||||||
base.Expression = expression.Left;
|
base.Expression = expression.Left;
|
||||||
base.Start();
|
base.Start();
|
||||||
|
@ -10,13 +10,13 @@ namespace SqlSugar
|
|||||||
public MemberExpressionResolve(ExpressionParameter parameter) : base(parameter)
|
public MemberExpressionResolve(ExpressionParameter parameter) : base(parameter)
|
||||||
{
|
{
|
||||||
var expression = base.Expression as MemberExpression;
|
var expression = base.Expression as MemberExpression;
|
||||||
var isLeft = this.IsLeft;
|
var isLeft = parameter.IsLeft;
|
||||||
this.IsLeft = null;
|
var isSingle = parameter.Context.IsSingle;
|
||||||
var isSingle = base.Context.IsSingle;
|
|
||||||
string field = string.Empty;
|
string field = string.Empty;
|
||||||
field = isSingle ? expression.Member.Name : expression.Member.ToString();
|
field = isSingle ? expression.Member.Name : expression.Member.ToString();
|
||||||
base.IsFinished = true;
|
base.IsFinished = true;
|
||||||
if (IsLeft == true)
|
base.SqlWhere += string.Format(" {0} ", field);
|
||||||
|
if (isLeft == true)
|
||||||
{
|
{
|
||||||
base.SqlWhere += ExpTool.GetOperator(parameter.BaseExpression.NodeType);
|
base.SqlWhere += ExpTool.GetOperator(parameter.BaseExpression.NodeType);
|
||||||
}
|
}
|
||||||
|
@ -109,7 +109,6 @@
|
|||||||
<Compile Include="Enum\OrderByType.cs" />
|
<Compile Include="Enum\OrderByType.cs" />
|
||||||
<Compile Include="ExpressionsToSql\ResolveExpressType.cs" />
|
<Compile Include="ExpressionsToSql\ResolveExpressType.cs" />
|
||||||
<Compile Include="ExpressionsToSql\ExpConst.cs" />
|
<Compile Include="ExpressionsToSql\ExpConst.cs" />
|
||||||
<Compile Include="ExpressionsToSql\ExpInfo.cs" />
|
|
||||||
<Compile Include="ExpressionsToSql\ExpItems\BaseResolve.cs" />
|
<Compile Include="ExpressionsToSql\ExpItems\BaseResolve.cs" />
|
||||||
<Compile Include="ExpressionsToSql\ExpItems\BinaryExpressionResolve.cs" />
|
<Compile Include="ExpressionsToSql\ExpItems\BinaryExpressionResolve.cs" />
|
||||||
<Compile Include="ExpressionsToSql\ExpItems\BlockExpressionResolve.cs" />
|
<Compile Include="ExpressionsToSql\ExpItems\BlockExpressionResolve.cs" />
|
||||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading…
Reference in New Issue
Block a user