From 1690d4d06b0c20b3606e50e0844ef67e07947a0d Mon Sep 17 00:00:00 2001
From: phpcjl <phpcjl@gmail.com>
Date: 星期二, 10 十二月 2024 14:05:59 +0800
Subject: [PATCH] 1.

---
 ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/BannerController.java |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/BannerController.java b/ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/BannerController.java
index 5fe3a69..21573c3 100644
--- a/ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/BannerController.java
+++ b/ruoyi-service/ruoyi-other/src/main/java/com/ruoyi/other/controller/BannerController.java
@@ -8,7 +8,6 @@
 import com.ruoyi.other.service.BannerService;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
-import org.apache.ibatis.annotations.Param;
 import org.springframework.web.bind.annotation.*;
 
 import javax.annotation.Resource;
@@ -32,8 +31,8 @@
 	@ApiOperation(value = "banner列表", tags = {"小程序-banner"})
 	public R<List<Banner>> list(String name, Integer jumpType, Integer position){
         List<Banner> list = bannerService.lambdaQuery().like(StringUtils.isNotEmpty(name), Banner::getName, name)
-                .eq(Banner::getJumpType, jumpType)
-                .eq(Banner::getPosition, position)
+                .eq(jumpType!=null,Banner::getJumpType, jumpType)
+                .eq(position!=null,Banner::getPosition, position)
                 .list();
         return R.ok(list);
     }

--
Gitblit v1.7.1