From 8409038b3baa4a0dac80dac858d779dd144fea4a Mon Sep 17 00:00:00 2001 From: yuanzhao <2206582181@qq.com> Date: Wed, 13 Mar 2024 11:30:20 +0800 Subject: [PATCH] =?UTF-8?q?add:=20=E6=94=AF=E6=8C=81=E7=9B=B4=E6=8E=A5?= =?UTF-8?q?=E6=A0=B9=E6=8D=AE=20sqlite=20=E6=B3=A8=E9=87=8A=E7=94=9F?= =?UTF-8?q?=E6=88=90=20orm?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- console/commands/orm/sqlite.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/console/commands/orm/sqlite.go b/console/commands/orm/sqlite.go index ee0321a..aa02bcc 100644 --- a/console/commands/orm/sqlite.go +++ b/console/commands/orm/sqlite.go @@ -57,7 +57,7 @@ func GenSqlite(table string, goType parser.GoType, out string) { var baseFunStr string baseFunStr = strings.ReplaceAll(baseMysqlFuncStr, "tx = providers.GetBean(\"mysql, {db}\").(*gorm.DB).Model(&MysqlTableName{})", - "tx = DB()") + "tx = DB().Model(&MysqlTableName{})") for old, newStr := range map[string]string{ "MysqlTableName": parser.StringToHump(table), "{table_name}": table,