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

Method UpdateFriendlink

controllers/ManagerController.go:1049–1055  ·  view source on GitHub ↗

更新友链

()

Source from the content-addressed store, hash-verified

1047
1048// 更新友链
1049func (this *ManagerController) UpdateFriendlink() {
1050 id, _ := this.GetInt("id")
1051 if err := new(models.FriendLink).Update(id, this.GetString("field"), this.GetString("value")); err != nil {
1052 this.JsonResult(1, "操作失败:"+err.Error())
1053 }
1054 this.JsonResult(0, "操作成功")
1055}
1056
1057// 删除友链
1058func (this *ManagerController) DelFriendlink() {

Callers

nothing calls this directly

Calls 2

JsonResultMethod · 0.80
UpdateMethod · 0.45

Tested by

no test coverage detected