feature model fix (#296)

* add raw stirng quote for sql field

* remove unused code
This commit is contained in:
anqiansong
2020-12-21 09:43:32 +08:00
committed by GitHub
parent 097f6886f2
commit a3b525b50d
21 changed files with 1127 additions and 59 deletions

View File

@@ -39,7 +39,7 @@ func genFindOneByField(table Table, withCache bool) (*findOneCode, error) {
"lowerStartCamelObject": stringx.From(camelTableName).Untitle(),
"lowerStartCamelField": stringx.From(camelFieldName).Untitle(),
"upperStartCamelPrimaryKey": table.PrimaryKey.Name.ToCamel(),
"originalField": field.Name.Source(),
"originalField": wrapWithRawString(field.Name.Source()),
})
if err != nil {
return nil, err
@@ -82,7 +82,7 @@ func genFindOneByField(table Table, withCache bool) (*findOneCode, error) {
"upperStartCamelObject": camelTableName,
"primaryKeyLeft": table.CacheKey[table.PrimaryKey.Name.Source()].Left,
"lowerStartCamelObject": stringx.From(camelTableName).Untitle(),
"originalPrimaryField": table.PrimaryKey.Name.Source(),
"originalPrimaryField": wrapWithRawString(table.PrimaryKey.Name.Source()),
})
if err != nil {
return nil, err