mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-07-21 07:01:04 +08:00
Feat: add built in DSL file API (#17003)
### Summary 1. list and get by id API for builtin DSL 2. add DSL default component param values validation 3. remove all hard code keys for parser config
This commit is contained in:
@@ -25,7 +25,7 @@ import (
|
||||
"ragflow/internal/common"
|
||||
"ragflow/internal/engine"
|
||||
"ragflow/internal/engine/redis"
|
||||
"ragflow/internal/httputil"
|
||||
"ragflow/internal/handler"
|
||||
"ragflow/internal/server"
|
||||
"ragflow/internal/service"
|
||||
"ragflow/internal/storage"
|
||||
@@ -1039,7 +1039,7 @@ func (h *Handler) RemoveIngestionTasks(c *gin.Context) {
|
||||
if req.Email == nil && req.Status == nil {
|
||||
tasks, err := h.service.RemoveIngestionTasks(req.Tasks)
|
||||
if err != nil {
|
||||
common.ErrorWithCode(c, httputil.IngestionTaskErrorCode(err), err.Error())
|
||||
common.ErrorWithCode(c, handler.IngestionTaskErrorCode(err), err.Error())
|
||||
return
|
||||
}
|
||||
|
||||
@@ -1047,7 +1047,7 @@ func (h *Handler) RemoveIngestionTasks(c *gin.Context) {
|
||||
} else {
|
||||
tasks, err := h.service.RemoveIngestionTasksByCondition(req.Tasks, req.Email, req.Status)
|
||||
if err != nil {
|
||||
common.ErrorWithCode(c, httputil.IngestionTaskErrorCode(err), err.Error())
|
||||
common.ErrorWithCode(c, handler.IngestionTaskErrorCode(err), err.Error())
|
||||
return
|
||||
}
|
||||
common.SuccessWithData(c, tasks, "Remove tasks successfully")
|
||||
@@ -1070,7 +1070,7 @@ func (h *Handler) StopIngestionTasks(c *gin.Context) {
|
||||
if req.Email == nil && req.Status == nil {
|
||||
tasks, err := h.service.StopIngestionTasks(req.Tasks)
|
||||
if err != nil {
|
||||
common.ErrorWithCode(c, httputil.IngestionTaskErrorCode(err), err.Error())
|
||||
common.ErrorWithCode(c, handler.IngestionTaskErrorCode(err), err.Error())
|
||||
return
|
||||
}
|
||||
var result []map[string]string
|
||||
|
||||
Reference in New Issue
Block a user