feat: allow to view chat message in manager console

This commit is contained in:
RockYang
2024-02-22 17:16:44 +08:00
parent b99b310306
commit e6bbd83c6b
23 changed files with 688 additions and 26 deletions

View File

@@ -90,6 +90,8 @@ func (c *Client) Imagine(task types.MjTask) (ImageRes, error) {
SetErrorResult(&errRes).
Post(apiURL)
if err != nil {
errStr, _ := io.ReadAll(r.Body)
logger.Errorf("API 返回:%s, API URL: %s", string(errStr), apiURL)
return ImageRes{}, fmt.Errorf("请求 API 出错:%v", err)
}

View File

@@ -14,7 +14,7 @@ var logger = logger2.GetLogger()
func NewSendServiceManager(config *types.AppConfig) (*ServiceManager, error) {
active := Ali
if config.OSS.Active != "" {
if config.SMS.Active != "" {
active = strings.ToUpper(config.SMS.Active)
}
var handler Service