Browse Source

查询转驼峰增加开关

master v1.7.6
loshiqi 6 hours ago
parent
commit
90742be412
1 changed files with 8 additions and 0 deletions
  1. +8
    -0
      db.go

+ 8
- 0
db.go View File

@ -557,6 +557,8 @@ func GetRow(dbName, table_name, alias string, titles string, with, join [][]stri
if col != nil {
if !close_hump {
index = helper.StrFirstToUpper(strings.ToLower(columns[i]))
} else {
index = strings.ToLower(columns[i])
}
info[index] = DmFormatDecimal(col)
}
@ -580,6 +582,8 @@ func GetRow(dbName, table_name, alias string, titles string, with, join [][]stri
if col != nil {
if !close_hump {
index = helper.StrFirstToUpper(columns[i])
} else {
index = columns[i]
}
info[index] = helper.ToString(col)
}
@ -806,6 +810,8 @@ func FetchRows(dbName, table_name, alias string, titles string, with, join [][]s
if col != nil {
if !close_hump {
index = helper.StrFirstToUpper(strings.ToLower(columns[i]))
} else {
index = strings.ToLower(columns[i])
}
info[index] = DmFormatDecimal(col)
}
@ -834,6 +840,8 @@ func FetchRows(dbName, table_name, alias string, titles string, with, join [][]s
if col != nil {
if !close_hump {
index = helper.StrFirstToUpper(columns[i])
} else {
index = columns[i]
}
info[index] = helper.ToString(col)
}


Loading…
Cancel
Save