zss
15 小时以前 2757f1d46f388f684aad93b3dc7ad805c45c6248
src/main/java/com/ruoyi/basic/service/impl/CustomerServiceImpl.java
@@ -74,9 +74,13 @@
        // 2. 构建查询条件(增强空值安全)
        LambdaQueryWrapper<Customer> queryWrapper = new LambdaQueryWrapper<>();
        String customerName = customer.getCustomerName();
        String customerType = customer.getCustomerType();
        if (StringUtils.isNotBlank(customerName)) {
            queryWrapper.like(Customer::getCustomerName, customerName);
        }
        if (StringUtils.isNotBlank(customerType)) {
            queryWrapper.like(Customer::getCustomerType, customerType);
        }
        // 3. 执行分页查询(保留分页元数据)
        IPage<Customer> customerPage = customerMapper.selectPage(page, queryWrapper);