refactor(db): 移除 Row 方法中的列名小写转换
- 在 Row 方法中删除对列名的统一小写转换,保持原始列名格式 - 简化代码逻辑,提升可读性
This commit is contained in:
+1
-2
@@ -557,8 +557,7 @@ func (that *HoTimeDB) Row(resl *sql.Rows) []Map {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
for j := 0; j < colCount; j++ {
|
for j := 0; j < colCount; j++ {
|
||||||
// 统一转小写,兼容DM8等返回大写列名的数据库驱动
|
colKey := strs[j]
|
||||||
colKey := strings.ToLower(strs[j])
|
|
||||||
val := a[j]
|
val := a[j]
|
||||||
if val == nil {
|
if val == nil {
|
||||||
lis[colKey] = nil
|
lis[colKey] = nil
|
||||||
|
|||||||
Reference in New Issue
Block a user