修复超级用户部分问题
This commit is contained in:
parent
9408bc3831
commit
5356efaa73
5
main.go
5
main.go
|
|
@ -9,6 +9,7 @@ import (
|
||||||
"io"
|
"io"
|
||||||
"log"
|
"log"
|
||||||
"os"
|
"os"
|
||||||
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
"videoplayer/dao"
|
"videoplayer/dao"
|
||||||
"videoplayer/handler"
|
"videoplayer/handler"
|
||||||
|
|
@ -142,7 +143,9 @@ func JWTAuthMiddleware() gin.HandlerFunc {
|
||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
c.Set("id", s_id)
|
id, _ := strconv.Atoi(s_id)
|
||||||
|
//查看s_id类型
|
||||||
|
c.Set("id", id)
|
||||||
c.Next()
|
c.Next()
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -112,7 +112,7 @@ func UserSyncDataFromMaster() {
|
||||||
req.Token = tokens[0]
|
req.Token = tokens[0]
|
||||||
req.Device = proto.Config.SERVER_NAME
|
req.Device = proto.Config.SERVER_NAME
|
||||||
all := worker.GetRedis("user_sync_all")
|
all := worker.GetRedis("user_sync_all")
|
||||||
var is_all bool //是否全量同步
|
is_all := false //是否全量同步
|
||||||
if all == "" || all == "1" {
|
if all == "" || all == "1" {
|
||||||
is_all = true
|
is_all = true
|
||||||
//清空数据表
|
//清空数据表
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue