소스 검색

1.学生激活数量计算

yuanliang 1 년 전
부모
커밋
5b6e59ad15
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      cooleshow-user/user-tenant/src/main/java/com/yonge/cooleshow/tenant/controller/StudentController.java

+ 2 - 2
cooleshow-user/user-tenant/src/main/java/com/yonge/cooleshow/tenant/controller/StudentController.java

@@ -84,10 +84,10 @@ public class StudentController extends BaseController {
 
         Map<Long, List<TenantActivationCode>> groupByUserId = new HashMap<>();
         if (!rows.isEmpty() && query.getTenantAlbumPurchaseId() != null) {
-            List<Long> studentIdList = rows.stream().map(Student::getUserId).collect(Collectors.toList());
+            List<String> studentPhones = rows.stream().map(StudentVo::getPhone).collect(Collectors.toList());
              groupByUserId = tenantActivationCodeService.lambdaQuery()
                     .eq(TenantActivationCode::getId, query.getTenantAlbumPurchaseId())
-                    .in(TenantActivationCode::getActivationUserId, studentIdList)
+                    .in(TenantActivationCode::getActivationPhone, studentPhones)
                     .list().stream().collect(Collectors.groupingBy(TenantActivationCode::getActivationUserId));
         }