MCPcopy Create free account
hub / github.com/TruthHun/BookStack / Update

Method Update

models/banner.go:42–48  ·  view source on GitHub ↗
(id int, field string, value interface{})

Source from the content-addressed store, hash-verified

40}
41
42func (m *Banner) Update(id int, field string, value interface{}) (err error) {
43 _, err = orm.NewOrm().QueryTable(m).Filter("id", id).Update(orm.Params{field: value})
44 if err == orm.ErrNoRows {
45 err = nil
46 }
47 return
48}
49
50func (m *Banner) Delete(id int) (err error) {
51 var banner Banner

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected