Browse Source

-

pull/12/MERGE
sunkaixuan 7 years ago
parent
commit
cf71763d53
  1. 4
      Src/Asp.Net/SqlSugar/Abstract/DbBindProvider/IDataReaderEntityBuilder.cs
  2. 1
      Src/Asp.Net/SqlSugar/ExpressionsToSql/Method/IDbMethods.cs
  3. 7
      Src/Asp.Net/SqlSugar/ExpressionsToSql/Method/SqlFunc.cs

4
Src/Asp.Net/SqlSugar/Abstract/DbBindProvider/IDataReaderEntityBuilder.cs

@ -222,6 +222,10 @@ namespace SqlSugar
method = isNullableType ? getConvertInt32 : getInt32; method = isNullableType ? getConvertInt32 : getInt32;
if (bindProperyTypeName.IsContainsIn("int64")) if (bindProperyTypeName.IsContainsIn("int64"))
method = isNullableType ? getConvertInt64 : getInt64; method = isNullableType ? getConvertInt64 : getInt64;
if (bindProperyTypeName.IsContainsIn("byte"))
method = isNullableType ? getConvertByte : getByte;
if (bindProperyTypeName.IsContainsIn("int16"))
method = isNullableType ? getConvertInt16 : getInt16;
break; break;
case CSharpDataType.@bool: case CSharpDataType.@bool:
if (bindProperyTypeName == "bool" || bindProperyTypeName == "boolean") if (bindProperyTypeName == "bool" || bindProperyTypeName == "boolean")

1
Src/Asp.Net/SqlSugar/ExpressionsToSql/Method/IDbMethods.cs

@ -47,6 +47,7 @@ namespace SqlSugar
string AggregateMax(MethodCallExpressionModel model); string AggregateMax(MethodCallExpressionModel model);
string AggregateCount(MethodCallExpressionModel model); string AggregateCount(MethodCallExpressionModel model);
string MappingColumn(MethodCallExpressionModel model); string MappingColumn(MethodCallExpressionModel model);
string GetSelfAndAutoFill(MethodCallExpressionModel model);
string True(); string True();
string False(); string False();
string GuidNew(); string GuidNew();

7
Src/Asp.Net/SqlSugar/ExpressionsToSql/Method/SqlFunc.cs

@ -95,5 +95,12 @@ namespace SqlSugar
public static TResult AggregateMax<TResult>(TResult thisValue) { throw new NotSupportedException("This method is not supported by the current parameter"); } public static TResult AggregateMax<TResult>(TResult thisValue) { throw new NotSupportedException("This method is not supported by the current parameter"); }
public static TResult AggregateCount<TResult>(TResult thisValue) { throw new NotSupportedException("This method is not supported by the current parameter"); } public static TResult AggregateCount<TResult>(TResult thisValue) { throw new NotSupportedException("This method is not supported by the current parameter"); }
public static TResult MappingColumn<TResult>(TResult oldColumnName,string newColumnName) { throw new NotSupportedException("This method is not supported by the current parameter"); } public static TResult MappingColumn<TResult>(TResult oldColumnName,string newColumnName) { throw new NotSupportedException("This method is not supported by the current parameter"); }
/// <summary>
///Example: new NewT(){name=SqlFunc.GetSelfAndAutoFill(it)} Generated SQL it.*
/// </summary>
/// <typeparam name="TResult"></typeparam>
/// <param name="value"></param>
/// <returns></returns>
public static TResult GetSelfAndAutoFill<TResult>(object value) { throw new NotSupportedException("This method is not supported by the current parameter"); }
} }
} }

Loading…
Cancel
Save