Browse Source

Storageable BUG

pull/41/MERGE
sunkaixuan 1 year ago
parent
commit
1adf9ee626
  1. 4
      Src/Asp.NetCore2/SqlSugar/Abstract/DeleteProvider/DeleteableProvider.cs

4
Src/Asp.NetCore2/SqlSugar/Abstract/DeleteProvider/DeleteableProvider.cs

@ -162,8 +162,8 @@ namespace SqlSugar
{ {
if (i != 0) if (i != 0)
andString.Append(DeleteBuilder.WhereInAndTemplate + UtilConstants.Space); andString.Append(DeleteBuilder.WhereInAndTemplate + UtilConstants.Space);
var entityPropertyName = this.Context.EntityMaintenance.GetPropertyName<T>(primaryField); //var entityPropertyName = this.EntityInfo.Columns.Single(it=>it.PropertyName.EqualCase(primaryField)||it.DbColumnName.EqualCase(primaryField)).PropertyName;
var columnInfo = EntityInfo.Columns.Single(it => it.PropertyName == entityPropertyName); var columnInfo = EntityInfo.Columns.Single(t => t.PropertyName.EqualCase(primaryField) || t.DbColumnName.EqualCase(primaryField));
var entityValue = columnInfo.PropertyInfo.GetValue(deleteObj, null); var entityValue = columnInfo.PropertyInfo.GetValue(deleteObj, null);
var tempequals = DeleteBuilder.WhereInEqualTemplate; var tempequals = DeleteBuilder.WhereInEqualTemplate;
if (this.Context.CurrentConnectionConfig.MoreSettings != null && this.Context.CurrentConnectionConfig.MoreSettings.DisableNvarchar == true) if (this.Context.CurrentConnectionConfig.MoreSettings != null && this.Context.CurrentConnectionConfig.MoreSettings.DisableNvarchar == true)

Loading…
Cancel
Save