feat article update排除关联
This commit is contained in:
parent
1e6dddc0b0
commit
c617344e33
@ -51,7 +51,7 @@ func (a *articleApi) Upsert(article v2.Article) error {
|
||||
|
||||
func (a *articleApi) Update(article v2.Article, selects ...string) error {
|
||||
if len(selects) > 0 {
|
||||
selects = []string{"remark", "exclude"}
|
||||
selects = []string{"Remark", "Exclude"}
|
||||
}
|
||||
return a.db.Model(&article).Select(selects).Omit(clause.Associations).Updates(article).Error
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user