mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-07-21 15:11:08 +08:00
Go CLI: refactor commands (#16447)
### Summary 1. Move debug commands to dev file. 2. Refactor some commands syntax --------- Signed-off-by: Jin Hai <haijin.chn@gmail.com>
This commit is contained in:
@@ -558,8 +558,8 @@ func (h *ProviderHandler) ShowTask(c *gin.Context) {
|
||||
}
|
||||
|
||||
type AlterProviderInstanceRequest struct {
|
||||
ModelName string `json:"model_name"`
|
||||
APIKey string `json:"api_key"`
|
||||
InstanceName string `json:"instance_name"`
|
||||
APIKey string `json:"api_key"`
|
||||
}
|
||||
|
||||
func (h *ProviderHandler) AlterProviderInstance(c *gin.Context) {
|
||||
@@ -599,7 +599,7 @@ func (h *ProviderHandler) AlterProviderInstance(c *gin.Context) {
|
||||
return
|
||||
}
|
||||
|
||||
code, err := h.modelProviderService.AlterProviderInstance(userID, providerName, instanceName, req.ModelName, req.APIKey)
|
||||
code, err := h.modelProviderService.AlterProviderInstance(userID, providerName, instanceName, req.InstanceName, req.APIKey)
|
||||
if err != nil {
|
||||
c.JSON(http.StatusOK, gin.H{
|
||||
"code": code,
|
||||
|
||||
Reference in New Issue
Block a user