mirror of
https://github.com/documize/community.git
synced 2025-07-23 07:09:43 +02:00
add entries to search index
This commit is contained in:
parent
2c5f73a486
commit
1b96c9093f
15 changed files with 244 additions and 417 deletions
|
@ -252,7 +252,8 @@ func (h *Handler) Update(w http.ResponseWriter, r *http.Request) {
|
|||
|
||||
ctx.Transaction.Commit()
|
||||
|
||||
h.Indexer.UpdateDocument(ctx, d)
|
||||
a, _ := h.Store.Attachment.GetAttachments(ctx, documentID)
|
||||
go h.Indexer.IndexDocument(ctx, d, a)
|
||||
|
||||
response.WriteEmpty(w)
|
||||
}
|
||||
|
@ -316,7 +317,7 @@ func (h *Handler) Delete(w http.ResponseWriter, r *http.Request) {
|
|||
|
||||
ctx.Transaction.Commit()
|
||||
|
||||
h.Indexer.DeleteDocument(ctx, documentID)
|
||||
go h.Indexer.DeleteDocument(ctx, documentID)
|
||||
|
||||
response.WriteEmpty(w)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue