feat: support Tencent's model (close #519)

This commit is contained in:
JustSong
2023-10-03 14:19:03 +08:00
parent d663de3e3a
commit b4b4acc288
10 changed files with 375 additions and 26 deletions

View File

@@ -25,12 +25,12 @@ func Distribute() func(c *gin.Context) {
if ok {
id, err := strconv.Atoi(channelId.(string))
if err != nil {
abortWithMessage(c, http.StatusBadRequest, "无效的渠道 ID")
abortWithMessage(c, http.StatusBadRequest, "无效的渠道 Id")
return
}
channel, err = model.GetChannelById(id, true)
if err != nil {
abortWithMessage(c, http.StatusBadRequest, "无效的渠道 ID")
abortWithMessage(c, http.StatusBadRequest, "无效的渠道 Id")
return
}
if channel.Status != common.ChannelStatusEnabled {