abiao před 2 roky
rodič
revize
e71c87748a

+ 3 - 4
go/gopath/src/fohow.com/apps/controllers/user_controller/user_controller.go

@@ -222,6 +222,9 @@ func (self *UserController) Get() {
 			}
 		}
 		user.IdentityCardWithStar = user.GetCardNoWithStar()
+		if user.Employ {
+			go self.SetTodayCache(wxUser.Id)
+		}
 	}
 	if wxUser != nil {
 		wxUser.Head = self.GetFullImgUrl(wxUser.Head)
@@ -237,15 +240,11 @@ func (self *UserController) Get() {
 		}
 
 	}
-
 	type Ret struct {
 		User         *user_model.User                     `json:"user"`
 		WxUser       *user_model.WxUser                   `json:"wx_user"`
 		MerchantUser *merchant_model.MerchantUserRelation `json:"merchant"`
 	}
-	if user.Employ {
-		go self.SetTodayCache(wxUser.Id)
-	}
 
 	// 商户信息, 如果不是商户,则返回 null
 	merchant_user_id := int64(0)