소스 검색

feat: 子账号查询父级账号权益

zhangxinlei1996 2 년 전
부모
커밋
cfe5a083e2
1개의 변경된 파일2개의 추가작업 그리고 1개의 파일을 삭제
  1. 2 1
      service/power.go

+ 2 - 1
service/power.go

@@ -167,6 +167,7 @@ func (this *PowerService) Power(userid string, baseUserId, accountId, entId, pos
 				}
 				if (*data)["s_member_mainid"] != nil && common.ObjToString((*data)["s_member_mainid"]) != "" && i_member_sub_status > 0 {
 					member.Pid = common.ObjToString((*data)["s_member_mainid"])
+					bigmemberServiceUserQuery["s_userid"] = member.Pid
 					member.IsSubCount = 1
 				}
 				if (member.Pid != "" && common.IntAllDef((*data)["i_member_sub_status"], 0) == 1) || this.Conn.MgoJy.Count("member", map[string]interface{}{"userid": userid}) > 0 {
@@ -227,7 +228,7 @@ func (this *PowerService) Power(userid string, baseUserId, accountId, entId, pos
 							product_type := common.ObjToString(v["product_type"])
 							if strings.Contains(product_type, entity.ProductType_vip) {
 								oBuyset := common.ObjToMap((*o_entniche)["o_buyset"])
-								upgrade := common.Int64All((*oBuyset)["oBuyset"])
+								upgrade := common.Int64All((*oBuyset)["upgrade"])
 								areacount := common.Int64All((*oBuyset)["areacount"])
 								buyerclasscount := common.Int64All((*oBuyset)["buyerclasscount"])
 								newcitys, _ := (*oBuyset)["newcitys"].([]interface{})