fix🐛 query built from **** sources

This commit is contained in:
wenjianzhang
2021-05-30 22:17:11 +08:00
parent 9026da4a6d
commit da16b4af7a
13 changed files with 52 additions and 52 deletions
+2 -2
View File
@@ -104,7 +104,7 @@ func (e *SysRole) UpdateSysRole(c *system.SysRole) error {
}
}()
db := tx.Model(&c).
Where(c.GetId()).Updates(c)
Where(" role_id = ?", c.GetId()).Updates(c)
if db.Error != nil {
e.Log.Errorf("db error:%s", err)
return err
@@ -221,4 +221,4 @@ func (e *SysRole) UpdateDataScope(c *system.SysRole) (err error) {
}
}
return err
}
}