MCPcopy Index your code
hub / github.com/TruthHun/BookStack / UpdateSubmitBook

Method UpdateSubmitBook

controllers/ManagerController.go:1165–1176  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1163}
1164
1165func (this *ManagerController) UpdateSubmitBook() {
1166 field := this.GetString("field")
1167 value := this.GetString("value")
1168 id, _ := this.GetInt("id")
1169 if id > 0 {
1170 _, err := orm.NewOrm().QueryTable(models.NewSubmitBooks()).Filter("id", id).Update(orm.Params{field: value})
1171 if err != nil {
1172 this.JsonResult(1, err.Error())
1173 }
1174 }
1175 this.JsonResult(0, "更新成功")
1176}
1177
1178// Versions 版本管理
1179func (this *ManagerController) Version() {

Callers

nothing calls this directly

Calls 3

NewSubmitBooksFunction · 0.92
JsonResultMethod · 0.80
UpdateMethod · 0.45

Tested by

no test coverage detected