From 906366d5f53217508bc8e530272f4f83669690ef Mon Sep 17 00:00:00 2001 From: memorylkf <312904636@qq.com> Date: Tue, 10 Feb 2026 16:30:18 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20[=E6=A8=A1=E6=9D=BF=E7=AE=A1=E7=90=86]?= =?UTF-8?q?=20=E6=A3=80=E6=B5=8B=E6=9D=BF=E5=88=97=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/hxhq/business/controller/JcbController.java | 17 ----------------- .../com/hxhq/business/controller/PublicController.java | 13 +++++++++++++ .../com/hxhq/business/service/impl/JcbServiceImpl.java | 8 ++++++++ 3 files changed, 21 insertions(+), 17 deletions(-) diff --git a/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/JcbController.java b/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/JcbController.java index 42bb6a4..1a79110 100644 --- a/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/JcbController.java +++ b/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/JcbController.java @@ -1,15 +1,9 @@ package com.hxhq.business.controller; -import java.util.Arrays; -import java.util.List; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.*; -import com.hxhq.business.domain.Jcb; import com.hxhq.business.service.IJcbService; import com.hxhq.common.core.web.controller.BaseController; -import com.hxhq.common.core.web.domain.AjaxResult; -import com.hxhq.common.core.web.page.TableDataInfo; - /** * 检测板Controller @@ -23,15 +17,4 @@ public class JcbController extends BaseController { @Autowired private IJcbService jcbService; - - /** - * 查询检测板列表 - */ - @GetMapping("/list") - public TableDataInfo list(Jcb jcb) - { - startPage(); - List list = jcbService.queryList(jcb); - return getDataTable(list); - } } diff --git a/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/PublicController.java b/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/PublicController.java index 8916c65..065c0f4 100644 --- a/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/PublicController.java +++ b/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/controller/PublicController.java @@ -76,6 +76,8 @@ public class PublicController extends BaseController { public ISysDeptService sysDeptService; @Autowired public ISystemLogService systemLogService; + @Autowired + public IJcbService jcbService; /** @@ -316,4 +318,15 @@ public class PublicController extends BaseController { systemLogService.saveSimpleInfo(name,nameEn,jcmc,jcmcEn); return success(); } + + /** + * 查询检测板列表 + */ + @GetMapping("/list") + public TableDataInfo list(Jcb jcb) + { + startPage(); + List list = jcbService.queryList(jcb); + return getDataTable(list); + } } \ No newline at end of file diff --git a/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/JcbServiceImpl.java b/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/JcbServiceImpl.java index 2ed0b7c..7e8799d 100644 --- a/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/JcbServiceImpl.java +++ b/hxhq-modules/hxhq-system/src/main/java/com/hxhq/business/service/impl/JcbServiceImpl.java @@ -4,6 +4,7 @@ import java.util.List; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.hxhq.common.core.utils.DateUtils; +import com.hxhq.common.core.utils.StringUtils; import org.springframework.stereotype.Service; import com.hxhq.business.mapper.JcbMapper; import com.hxhq.business.domain.Jcb; @@ -29,6 +30,13 @@ public class JcbServiceImpl extends ServiceImpl implements IJcbS public List queryList(Jcb jcb) { QueryWrapper queryWrapper = Wrappers.query(); + if(StringUtils.isNoneBlank(jcb.getBh())){ + queryWrapper.like("bh",jcb.getBh()); + } + if(StringUtils.isNoneBlank(jcb.getCjr())){ + queryWrapper.like("cjr",jcb.getCjr()); + } + queryWrapper.orderByDesc("id"); return this.list(queryWrapper); }