feat: The 'chat_models' field of user table, holds the model IDS in place of the model values

This commit is contained in:
RockYang
2024-03-18 15:37:46 +08:00
parent aa72be6ff3
commit f215643f2e
13 changed files with 73 additions and 76 deletions

View File

@@ -25,8 +25,12 @@ func NewConfigHandler(app *core.AppServer, db *gorm.DB) *ConfigHandler {
func (h *ConfigHandler) Update(c *gin.Context) {
var data struct {
Key string `json:"key"`
Config map[string]interface{} `json:"config"`
Key string `json:"key"`
Config struct {
types.SystemConfig
Content string `json:"content,omitempty"`
Updated bool `json:"updated,omitempty"`
} `json:"config"`
}
if err := c.ShouldBindJSON(&data); err != nil {