feat: 一键编辑标签下渠道重定向

This commit is contained in:
CalciumIon
2024-11-19 01:42:46 +08:00
parent 807385d3d1
commit 6e6e390f6f
3 changed files with 15 additions and 11 deletions

View File

@@ -158,8 +158,8 @@ func SearchChannels(c *gin.Context) {
keyword := c.Query("keyword")
group := c.Query("group")
modelKeyword := c.Query("model")
//idSort, _ := strconv.ParseBool(c.Query("id_sort"))
channels, err := model.SearchChannels(keyword, group, modelKeyword)
idSort, _ := strconv.ParseBool(c.Query("id_sort"))
channels, err := model.SearchChannels(keyword, group, modelKeyword, idSort)
if err != nil {
c.JSON(http.StatusOK, gin.H{
"success": false,
@@ -294,10 +294,11 @@ func DeleteDisabledChannel(c *gin.Context) {
}
type ChannelTag struct {
Tag string `json:"tag"`
NewTag *string `json:"newTag"`
Priority *int64 `json:"priority"`
Weight *uint `json:"weight"`
Tag string `json:"tag"`
NewTag *string `json:"new_tag"`
Priority *int64 `json:"priority"`
Weight *uint `json:"weight"`
MapMapping *string `json:"map_mapping"`
}
func DisableTagChannels(c *gin.Context) {