|
|
|
@ -371,7 +371,7 @@ func GetData(dbName, table string, title string, where map[string]string, limit |
|
|
|
* @param dbName 数据表名 |
|
|
|
* @param title 查询字段名 |
|
|
|
*/ |
|
|
|
func GetRow(dbName, table_name, alias string, titles string, with, join [][]string, where, where_or []string, valueList []interface{}, orderby, groupby, having string, debug bool) (int, map[string]string, error) { |
|
|
|
func GetRow(dbName, table_name, alias string, titles string, with, join [][]string, where, where_or []string, valueList []interface{}, orderby, groupby, having string, debug, close_hump bool) (int, map[string]string, error) { |
|
|
|
var count int = 0 |
|
|
|
info := make(map[string]string) |
|
|
|
|
|
|
|
@ -555,7 +555,9 @@ func GetRow(dbName, table_name, alias string, titles string, with, join [][]stri |
|
|
|
if rowerr == nil { |
|
|
|
for i, col := range scanArgs { |
|
|
|
if col != nil { |
|
|
|
index = helper.StrFirstToUpper(strings.ToLower(columns[i])) |
|
|
|
if !close_hump { |
|
|
|
index = helper.StrFirstToUpper(strings.ToLower(columns[i])) |
|
|
|
} |
|
|
|
info[index] = DmFormatDecimal(col) |
|
|
|
} |
|
|
|
} |
|
|
|
@ -576,7 +578,9 @@ func GetRow(dbName, table_name, alias string, titles string, with, join [][]stri |
|
|
|
if rowerr == nil { |
|
|
|
for i, col := range values { |
|
|
|
if col != nil { |
|
|
|
index = helper.StrFirstToUpper(columns[i]) |
|
|
|
if !close_hump { |
|
|
|
index = helper.StrFirstToUpper(columns[i]) |
|
|
|
} |
|
|
|
info[index] = helper.ToString(col) |
|
|
|
} |
|
|
|
} |
|
|
|
@ -601,7 +605,7 @@ func GetRow(dbName, table_name, alias string, titles string, with, join [][]stri |
|
|
|
* @param dbName 数据表名 |
|
|
|
* @param title 查询字段名 |
|
|
|
*/ |
|
|
|
func FetchRows(dbName, table_name, alias string, titles string, with, join [][]string, where, where_or []string, valueList []interface{}, orderby, groupby, having string, page int, page_size int, debug bool) (int, []map[string]string, error) { |
|
|
|
func FetchRows(dbName, table_name, alias string, titles string, with, join [][]string, where, where_or []string, valueList []interface{}, orderby, groupby, having string, page int, page_size int, debug, close_hump bool) (int, []map[string]string, error) { |
|
|
|
var count int = 0 |
|
|
|
list := make([]map[string]string, 0) |
|
|
|
|
|
|
|
@ -800,7 +804,9 @@ func FetchRows(dbName, table_name, alias string, titles string, with, join [][]s |
|
|
|
if rowerr == nil { |
|
|
|
for i, col := range scanArgs { |
|
|
|
if col != nil { |
|
|
|
index = helper.StrFirstToUpper(strings.ToLower(columns[i])) |
|
|
|
if !close_hump { |
|
|
|
index = helper.StrFirstToUpper(strings.ToLower(columns[i])) |
|
|
|
} |
|
|
|
info[index] = DmFormatDecimal(col) |
|
|
|
} |
|
|
|
} |
|
|
|
@ -826,7 +832,9 @@ func FetchRows(dbName, table_name, alias string, titles string, with, join [][]s |
|
|
|
if rowerr == nil { |
|
|
|
for i, col := range values { |
|
|
|
if col != nil { |
|
|
|
index = helper.StrFirstToUpper(columns[i]) |
|
|
|
if !close_hump { |
|
|
|
index = helper.StrFirstToUpper(columns[i]) |
|
|
|
} |
|
|
|
info[index] = helper.ToString(col) |
|
|
|
} |
|
|
|
} |
|
|
|
|