fix[table.TableName]: fixed table.TableName to table.TBName
This commit is contained in:
1 parent
92b0851e25
commit
5374394cfd
1 file changed
+3
-2
+3
-2
@@ -7,13 +7,14 @@ import (
|
|||||||
"text/template"
|
"text/template"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
func TestGoModelTemplate(t *testing.T) {
|
func TestGoModelTemplate(t *testing.T) {
|
||||||
t1, err := template.ParseFiles("model.go.template")
|
t1, err := template.ParseFiles("model.go.template")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Error(err)
|
t.Error(err)
|
||||||
}
|
}
|
||||||
table := tools.SysTables{}
|
table := tools.SysTables{}
|
||||||
table.TableName = "sys_tables"
|
table.TBName = "sys_tables"
|
||||||
tab, err := table.Get()
|
tab, err := table.Get()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Error(err)
|
t.Error(err)
|
||||||
@@ -34,7 +35,7 @@ func TestGoApiTemplate(t *testing.T) {
|
|||||||
t.Error(err)
|
t.Error(err)
|
||||||
}
|
}
|
||||||
table := tools.SysTables{}
|
table := tools.SysTables{}
|
||||||
table.TableName = "sys_tables"
|
table.TBName = "sys_tables"
|
||||||
tab, _ := table.Get()
|
tab, _ := table.Get()
|
||||||
file, err := os.Create("apis/" + table.PackageName + ".go")
|
file, err := os.Create("apis/" + table.PackageName + ".go")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|||||||
Reference in new issue
Block a user