nacos config
This commit is contained in:
@@ -52,6 +52,7 @@ func MetadataModulePATCH(tx *gorm.DB, module string, tableStructPointer any, upd
|
||||
if stype.Kind() == reflect.Pointer {
|
||||
stype = stype.Elem()
|
||||
}
|
||||
tname := tx.NamingStrategy.TableName(stype.Name())
|
||||
|
||||
updatesql := `UPDATE %s
|
||||
SET metadata = CASE
|
||||
@@ -80,7 +81,7 @@ func MetadataModulePATCH(tx *gorm.DB, module string, tableStructPointer any, upd
|
||||
args = append(args, metadata, metadata)
|
||||
args = append(args, values...)
|
||||
|
||||
updatesql = fmt.Sprintf(updatesql, tx.NamingStrategy.TableName(stype.Name()), module, WhereKeysCond)
|
||||
updatesql = fmt.Sprintf(updatesql, tname, module, WhereKeysCond)
|
||||
// logx.Error(updatesql)
|
||||
err = tx.Exec(updatesql, args...).Error
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user