This commit is contained in:
suyl
2021-07-02 10:33:37 +08:00
parent 48d7bfc8d5
commit e2edd85b73
3 changed files with 36 additions and 0 deletions

View File

@@ -28,6 +28,21 @@ func (c *KnowController) GetKnowledgeDepot() {
})
}
// @Title 添加知识条目
// @Description 添加知识条目
// @Param token header string true "认证token"
// @Param title formData string false "标题"
// @Param content formData string false "内容"
// @Success 200 {object} controllers.CallResult
// @Failure 200 {object} controllers.CallResult
// @router /AddKnowledgeDepot [post]
func (c *KnowController) AddKnowledgeDepot() {
c.callAddKnowledgeDepot(func(params *tKnowAddKnowledgeDepotParams) (retVal interface{}, errCode string, err error) {
err = knowledge.AddKnowledgeDepot(params.Ctx, params.Title, params.Content)
return retVal, "", err
})
}
// @Title 更新知识条目
// @Description 更新知识条目
// @Param token header string true "认证token"