上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 30 下一页
摘要: List<Long> parentPath = findParentPath(catelogId, paths);Collections.reverse(parentPath); //将集合逆序(前后颠倒位置)return parentPath.toArray(new Long[parentPath 阅读全文
posted @ 2022-11-28 17:06 sensen~||^_^|||& 阅读(29) 评论(0) 推荐(0) 编辑
摘要: @Overridepublic Long[] findCatelogPath(Long catelogId) { List<Long> paths = new ArrayList<>(); List<Long> parentPath = findParentPath(catelogId, paths 阅读全文
posted @ 2022-11-28 16:36 sensen~||^_^|||& 阅读(11) 评论(0) 推荐(0) 编辑
摘要: 实体类查询字段不为空时才返回的注解:@JsonInclude@JsonInclude(JsonInclude.Include.NON_EMPTY)@TableField(exist = false)private List<CategoryEntity> children; 阅读全文
posted @ 2022-11-28 16:04 sensen~||^_^|||& 阅读(14) 评论(0) 推荐(0) 编辑
摘要: @Overridepublic List<CategoryEntity> listWithTree() { //1、查询所有的分类数据 List<CategoryEntity> entities = categoryDao.selectList(null); //2、组装成父子的树形结构 //2.1 阅读全文
posted @ 2022-11-24 15:22 sensen~||^_^|||& 阅读(154) 评论(0) 推荐(0) 编辑
摘要: 转自:https://www.cnblogs.com/ajing2018/p/14281612.html Stream管道流map的基础用法: (对管道流中的每一个数据元素进行转换操作)eg:将集合中的每一个字符串,全部转换成大写List<String> alpha = Arrays.asList( 阅读全文
posted @ 2022-11-24 15:05 sensen~||^_^|||& 阅读(62) 评论(0) 推荐(0) 编辑
摘要: //添加表中不存在的字段@TableField(exist = false)private List<CategoryEntity> children; 阅读全文
posted @ 2022-11-24 10:11 sensen~||^_^|||& 阅读(172) 评论(0) 推荐(0) 编辑
摘要: 1、使用简单示例: @Overridepublic List<CategoryEntity> listWithTree() { //1、查询所有的分类数据 List<CategoryEntity> entities = categoryDao.selectList(null); //2、组装成父子的 阅读全文
posted @ 2022-11-24 08:27 sensen~||^_^|||& 阅读(108) 评论(0) 推荐(0) 编辑
摘要: package com.cars.ict.common.utils;import com.baomidou.mybatisplus.core.metadata.IPage;import java.io.Serializable;import java.util.List;/** * 分页工具类 * 阅读全文
posted @ 2022-11-15 16:49 sensen~||^_^|||& 阅读(115) 评论(0) 推荐(0) 编辑
摘要: 当我们调用一个工具类的方法的时候 eg: 工具类: @Componentpublic class ConvertUtils { @Resource private JcdeptMapper jcdeptMapper; @Autowired private JcdeptController jcdep 阅读全文
posted @ 2022-11-14 16:13 sensen~||^_^|||& 阅读(142) 评论(0) 推荐(0) 编辑
摘要: 一、升序:@Testpublic void test1() { //创建ArrayList集合对象 List<String> al = new ArrayList<>(); //往集合里添加数据 al.add("aa"); al.add("bb"); al.add("cc"); al.add("dd 阅读全文
posted @ 2022-11-11 14:32 sensen~||^_^|||& 阅读(175) 评论(0) 推荐(0) 编辑
上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 30 下一页