mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-09-19 18:22:23 +08:00
-
This commit is contained in:
@@ -165,7 +165,7 @@ namespace SqlSugar
|
|||||||
}
|
}
|
||||||
return "'" + date.ToString("yyyy-MM-dd HH:mm:ss.fff") + "'";
|
return "'" + date.ToString("yyyy-MM-dd HH:mm:ss.fff") + "'";
|
||||||
}
|
}
|
||||||
else if (type.GetTypeInfo().IsEnum())
|
else if (type.IsEnum())
|
||||||
{
|
{
|
||||||
return Convert.ToInt64(value);
|
return Convert.ToInt64(value);
|
||||||
}
|
}
|
||||||
|
@@ -259,7 +259,7 @@ namespace SqlSugar
|
|||||||
}
|
}
|
||||||
return "'" + date.ToString("yyyy-MM-dd HH:mm:ss.fff") + "'";
|
return "'" + date.ToString("yyyy-MM-dd HH:mm:ss.fff") + "'";
|
||||||
}
|
}
|
||||||
else if (type.GetTypeInfo().IsEnum())
|
else if (type.IsEnum())
|
||||||
{
|
{
|
||||||
return Convert.ToInt64(value);
|
return Convert.ToInt64(value);
|
||||||
}
|
}
|
||||||
|
@@ -174,7 +174,7 @@ namespace SqlSugar
|
|||||||
{
|
{
|
||||||
var appendValue = this.Context.SqlParameterKeyWord + ExpressionConst.Const + Context.ParameterIndex;
|
var appendValue = this.Context.SqlParameterKeyWord + ExpressionConst.Const + Context.ParameterIndex;
|
||||||
Context.ParameterIndex++;
|
Context.ParameterIndex++;
|
||||||
if (value != null && value.GetType().GetTypeInfo().IsEnum()) {
|
if (value != null && value.GetType().IsEnum()) {
|
||||||
value = Convert.ToInt64(value);
|
value = Convert.ToInt64(value);
|
||||||
}
|
}
|
||||||
this.Context.Parameters.Add(new SugarParameter(appendValue, value));
|
this.Context.Parameters.Add(new SugarParameter(appendValue, value));
|
||||||
|
@@ -21,7 +21,7 @@ namespace SqlSugar
|
|||||||
case ResolveExpressType.Update:
|
case ResolveExpressType.Update:
|
||||||
case ResolveExpressType.SelectSingle:
|
case ResolveExpressType.SelectSingle:
|
||||||
case ResolveExpressType.SelectMultiple:
|
case ResolveExpressType.SelectMultiple:
|
||||||
if (value != null && value.GetType().GetTypeInfo().IsEnum())
|
if (value != null && value.GetType().IsEnum())
|
||||||
{
|
{
|
||||||
value = Convert.ToInt64(value);
|
value = Convert.ToInt64(value);
|
||||||
}
|
}
|
||||||
|
@@ -52,7 +52,7 @@ namespace SqlSugar
|
|||||||
}
|
}
|
||||||
return "'" + date.ToString("yyyy-MM-dd HH:mm:ss.fff") + "'";
|
return "'" + date.ToString("yyyy-MM-dd HH:mm:ss.fff") + "'";
|
||||||
}
|
}
|
||||||
else if (type.GetTypeInfo().IsEnum())
|
else if (type.IsEnum())
|
||||||
{
|
{
|
||||||
return Convert.ToInt64(value);
|
return Convert.ToInt64(value);
|
||||||
}
|
}
|
||||||
|
@@ -29,7 +29,7 @@ namespace SqlSugar
|
|||||||
}
|
}
|
||||||
return "'" + date.ToString("yyyy-MM-dd HH:mm:ss.fff") + "'";
|
return "'" + date.ToString("yyyy-MM-dd HH:mm:ss.fff") + "'";
|
||||||
}
|
}
|
||||||
else if (type.GetTypeInfo().IsEnum())
|
else if (type.IsEnum())
|
||||||
{
|
{
|
||||||
return Convert.ToInt64(value);
|
return Convert.ToInt64(value);
|
||||||
}
|
}
|
||||||
|
Binary file not shown.
Reference in New Issue
Block a user