Explorar o código

增加 redis 队列

abiao %!s(int64=5) %!d(string=hai) anos
pai
achega
eed9de2843

+ 2 - 2
go/gopath/src/fohow.com/apps/controllers/tool_controller/express_controller.go

@@ -90,7 +90,7 @@ func (self *ToolController) GetExpressInfo() {
 	param.Set("no", expressNo)               //需要查询的订单号
 	param.Set("key", express_model.JUHE_KEY) //应用APPKEY(应用详细页查询)
 	param.Set("dtype", "json")               //返回数据的格式,xml或json,默认json
-	var netReturn map[string]interface{}
+	var netReturn interface{}
 	ret := &Ret{}
 	//将数据存入 redis
 	key := fmt.Sprintf("express.GetExpressInfo(%s)", expressNo)
@@ -104,7 +104,7 @@ func (self *ToolController) GetExpressInfo() {
 			fmt.Errorf("请求失败,错误信息:\r\n%v", err)
 		} else {
 			helpers.SetRedisValue(key, string(data), 90)
-			json.Unmarshal(data, &netReturn)
+			json.Unmarshal(data, &resp)
 		}
 		//cache.Cache.Put(k, ret, 90*time.Minute)
 	}