From 9009e97c4cf3c58f33c2d22bbcbfa5d3dfc53592 Mon Sep 17 00:00:00 2001 From: wuchunlei Date: Mon, 7 Jul 2025 14:38:51 +0800 Subject: [PATCH] =?UTF-8?q?=E8=BF=87=E6=BB=A4=E5=9B=BD=E9=99=85=E4=B8=AD?= =?UTF-8?q?=E5=8C=BB=E5=B8=88=E5=92=8C=E9=92=88=E7=81=B8=E5=B8=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../master/controller/UserCertificateController.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/peanut/modules/master/controller/UserCertificateController.java b/src/main/java/com/peanut/modules/master/controller/UserCertificateController.java index c0207efc..7968b21f 100644 --- a/src/main/java/com/peanut/modules/master/controller/UserCertificateController.java +++ b/src/main/java/com/peanut/modules/master/controller/UserCertificateController.java @@ -53,7 +53,10 @@ public class UserCertificateController { MPJLambdaWrapper wrapper = new MPJLambdaWrapper(); wrapper.leftJoin(UserCertificate.class,UserCertificate::getUserId,MyUserEntity::getId); wrapper.in(UserCertificate::getLabelId,5,8); - wrapper.notExists("select 1 from (select count(1) c,user_id from user_certificate where label_id in (13,19) group by user_id having c>1) s where s.user_id = t.id "); + //过滤获得国际中医师证和国际针灸师证得人 + wrapper.notExists("select 1 from (" + + "select count(1) c,user_id from user_certificate where label_id in (13,19) group by user_id having c>1) s " + + "where s.user_id = t.id "); wrapper.select("count(1) as count,user_id userId,name,tel,email"); wrapper.groupBy(UserCertificate::getUserId); wrapper.orderByDesc("count"); @@ -62,7 +65,8 @@ public class UserCertificateController { for (Map map:certificatePage.getRecords()){ map.put("certificate",userCertificateService.list(new LambdaQueryWrapper() .eq(UserCertificate::getUserId,map.get("userId")) - .in(UserCertificate::getLabelId,5,8))); + .in(UserCertificate::getLabelId,5,8,13,19) + .orderByDesc(UserCertificate::getLabelId))); } return R.ok().put("certificateList", certificatePage); }