From 427f924888afb32d639939a39c8616af95cd9de2 Mon Sep 17 00:00:00 2001 From: molon <3739161+molon@users.noreply.github.com> Date: Fri, 15 Mar 2024 03:51:35 +0800 Subject: [PATCH] fix MapColumns desc --- chainable_api.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chainable_api.go b/chainable_api.go index a04d3d2f..408ae5a6 100644 --- a/chainable_api.go +++ b/chainable_api.go @@ -185,7 +185,7 @@ func (db *DB) Omit(columns ...string) (tx *DB) { return } -// MapColumns specify column-to-field for customizing how database columns are assigned to struct fields during querying +// MapColumns modify the column names in the query results to facilitate align to the corresponding structural fields func (db *DB) MapColumns(m map[string]string) (tx *DB) { tx = db.getInstance() tx.Statement.ColumnMapping = m