Files
go-admin/common/global/adm.go
T
zhangwenjian 954ebdc9eb refactor🎨: turn common/dto into a thin alias of go-admin-core
AutoForm, ObjectById/ObjectGetReq/ObjectDeleteReq, Pagination,
GeneralDelDto/GeneralGetDto and Index/Control are now type aliases of
go-admin-core's sdk/contract/dto; OrderDest, MakeCondition and
Paginate forward to the same package (functions cannot be aliased the
way types can).

MakeCondition no longer reads common/global.Driver to choose which SQL
dialect to resolve search tags against. The lowered version reads
db.Dialector.Name() from inside the closure it returns instead, which
is always the driver the caller's own *gorm.DB is bound to - correct
even with more than one database open with different drivers, which a
single process-wide variable could never be. global.Driver is marked
Deprecated accordingly; it is still set and still readable for fork
code that reads it directly.

PRD 006 F2/F5.

Claude-Session: https://claude.ai/code/session_01HPTAw8b8tAdFNFn8rKdPYx
2026-09-05 10:15:58 +08:00

19 lines
534 B
Go

package global
const (
// Version go-admin version info
Version = "2.4.0"
)
var (
// Driver 数据库驱动
//
// Deprecated: common/dto.MakeCondition stopped reading this after PRD
// 006 F2/F5 - it now takes the dialect from the *gorm.DB passed to the
// scope it returns instead of this process-wide variable. Driver is
// still set (common/database/initialize.go) and still readable for fork
// code that reads it directly, but it is no longer this framework's own
// path to the current SQL dialect.
Driver string
)