Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

优化 CheckColumnsChange 方法中的列名处理逻辑 #42

Merged
merged 1 commit into from
Sep 20, 2024

Conversation

Soar360
Copy link
Member

@Soar360 Soar360 commented Sep 20, 2024

将 entitytable.Columns 的字典键从 ColumnName.ToLower() 改为 this.FormatName(e)。 在检查新增列时,判断条件从 !dbdic.ContainsKey(item.ColumnName.ToLower()) 改为 !dbdic.ContainsKey(this.FormatName(item))。 在删除列的部分,判断条件从 !etdic.ContainsKey(item.ColumnName.ToLower()) 改为 !etdic.ContainsKey(item.ColumnName)。 在遍历 entitytable.Columns 时,判断条件从 !dbdic.TryGetValue(item.ColumnName, out var dbf) 改为 !dbdic.TryGetValue(this.FormatName(item), out var dbf)。

#41

将 entitytable.Columns 的字典键从 ColumnName.ToLower() 改为 this.FormatName(e)。
在检查新增列时,判断条件从 !dbdic.ContainsKey(item.ColumnName.ToLower()) 改为 !dbdic.ContainsKey(this.FormatName(item))。
在删除列的部分,判断条件从 !etdic.ContainsKey(item.ColumnName.ToLower()) 改为 !etdic.ContainsKey(item.ColumnName)。
在遍历 entitytable.Columns 时,判断条件从 !dbdic.TryGetValue(item.ColumnName, out var dbf) 改为 !dbdic.TryGetValue(this.FormatName(item), out var dbf)。
@nnhy nnhy merged commit 15a4ac9 into NewLifeX:master Sep 20, 2024
0 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants