Commit bcfe04037a65564f0c74960027ed993c4efaa8bf
1 parent
dd0121f0
Exists in
master
and in
4 other branches
提交
Showing
1 changed file
with
8 additions
and
5 deletions
Show diff stats
src/HttpServer/logic/httpserver.go
@@ -83,11 +83,14 @@ func ClearData(w http.ResponseWriter, r *http.Request) { | @@ -83,11 +83,14 @@ func ClearData(w http.ResponseWriter, r *http.Request) { | ||
83 | 83 | ||
84 | s := string(result) | 84 | s := string(result) |
85 | logger.Info("ClearData , body:%v,uuid=%v", s, Uuid) | 85 | logger.Info("ClearData , body:%v,uuid=%v", s, Uuid) |
86 | - | ||
87 | - redishandler.GetRedisClient().HDel(redis.USER_DATA_KEY, strconv.Itoa(Uuid)) | ||
88 | - redishandler.GetRedisClient().HDel(redis.USER_TASKINFO_LIST, strconv.Itoa(Uuid)) | ||
89 | - redishandler.GetRedisClient().HDel(redis.USER_ACHIEVEMENTINFO_LIST, strconv.Itoa(Uuid)) | ||
90 | - redishandler.GetRedisClient().HDel(redis.USER_WITHDRAW_RECORDLIST, strconv.Itoa(Uuid)) | 86 | + var rdata GetuserdataReq |
87 | + json.Unmarshal(result, &rdata) | ||
88 | + rkey := strconv.Itoa(Uuid) + rdata.Channel | ||
89 | + | ||
90 | + redishandler.GetRedisClient().HDel(redis.USER_DATA_KEY, rkey) | ||
91 | + redishandler.GetRedisClient().HDel(redis.USER_TASKINFO_LIST, rkey) | ||
92 | + redishandler.GetRedisClient().HDel(redis.USER_ACHIEVEMENTINFO_LIST, rkey) | ||
93 | + redishandler.GetRedisClient().HDel(redis.USER_WITHDRAW_RECORDLIST, rkey) | ||
91 | 94 | ||
92 | fmt.Fprint(w, "success!") | 95 | fmt.Fprint(w, "success!") |
93 | } | 96 | } |