rentaiming
2024-07-10 b29becf95484be48aa09e87fcc7cc19f94cf9c81
ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/service/impl/GoodsBrandServiceImpl.java
@@ -5,12 +5,12 @@
import com.ruoyi.common.core.utils.StringUtils;
import com.ruoyi.common.core.utils.page.BeanUtils;
import com.ruoyi.common.core.utils.page.PageDTO;
import com.ruoyi.goods.controller.mamagement.DTO.GoodsBrandDTO;
import com.ruoyi.goods.controller.mamagement.DTO.GoodsBrandQuery;
import com.ruoyi.goods.controller.mamagement.VO.GoodsBrandVO;
import com.ruoyi.goods.domain.pojo.GoodsBrand;
import com.ruoyi.goods.controller.management.dto.GoodsBrandDTO;
import com.ruoyi.goods.controller.management.dto.GoodsBrandQuery;
import com.ruoyi.goods.controller.management.vo.GoodsBrandVO;
import com.ruoyi.goods.mapper.GoodsBrandMapper;
import com.ruoyi.goods.service.IGoodsBrandService;
import com.ruoyi.system.api.domain.GoodsBrand;
import java.util.List;
import org.springframework.stereotype.Service;
@@ -50,7 +50,8 @@
        Page<GoodsBrand> page = this.lambdaQuery()
                .like(StringUtils.isNotEmpty(query.getBrandName()), GoodsBrand::getBrandName,
                        query.getBrandName())
                .page(new Page<GoodsBrand>(query.getPageCurr(), query.getPageSize()));
                .orderByDesc(GoodsBrand::getCreateTime)
                .page(new Page<>(query.getPageCurr(), query.getPageSize()));
        if (StringUtils.isEmpty(page.getRecords())) {
            return PageDTO.empty(page.getTotal(), page.getPages());
        }
@@ -63,7 +64,6 @@
     *
     * @param dto 商品品牌数据传输对象,包含商品品牌的信息。 如果dto中的id为空,则认为是新品牌,调用save方法保存;
     *            如果id不为空,则认为是更新已有品牌,调用updateById方法更新。
     * @return 无返回值
     */
    @Override
    public void saveGoodsBrand(GoodsBrandDTO dto) {