Browse Source

fix:修改

duxin 2 năm trước cách đây
mục cha
commit
9030a9d9c7
1 tập tin đã thay đổi với 3 bổ sung2 xóa
  1. 3 2
      entity/power/power.go

+ 3 - 2
entity/power/power.go

@@ -5,6 +5,7 @@ import (
 	"app.yhyue.com/moapp/jybase/redis"
 	"encoding/json"
 	"fmt"
+	"go.mongodb.org/mongo-driver/bson/primitive"
 	"leadGeneration/public"
 	"leadGeneration/vars"
 )
@@ -76,13 +77,13 @@ func HasAheadPower(userId string) bool {
 	query := map[string]interface{}{
 		"$or": []map[string]interface{}{
 			{
-				"_id": userId,
+				"_id": primitive.ObjectIDFromHex(userId),
 				"i_member_status": map[string]interface{}{
 					"$gt": 0,
 				},
 			},
 			{
-				"_id": userId,
+				"_id": primitive.ObjectIDFromHex(userId),
 				"i_vip_status": map[string]interface{}{
 					"$gt": 0,
 				},