- 博客(21)
- 收藏
- 关注
原创 spring 日志配置
springboot 里面的默认日志使用的是logback于是乎你只需要配置logback-spring.xml 只需要改一下路径jiuOK
2022-11-19 14:39:40
891
原创 redis 做缓存
根据方法对其返回结果进行缓存,下次请求时,如果缓存存在,则直接读取缓存数据返回;如果缓存不存在,则执行方法,并把返回的结果存入缓存中。一般用在查询方法上。使用该注解标志的方法,每次都会执行,并将结果存入指定的缓存中。其他方法可以直接从响应的缓存中读取缓存数据,而不需要再去查询数据库。一般用在新增方法上。使用该注解标志的方法,会清空指定的缓存。一般用在更新或者删除方法上。
2022-11-19 14:36:42
135
原创 easyExcel工具
easyExcel依赖 <dependency> <groupId>com.alibaba</groupId> <artifactId>easyexcel</artifactId> </dependency>@Datapublic class SubjectEeVo { @ExcelProperty(value = "id" ,index = 0
2022-11-10 16:20:20
85
原创 spring 打包插件
这个是 spring cloud boot 的打包的东西用法就是在pom 中添加 然后 在子项目中点击 打包就行 maven的生命周期中的 你懂的
2022-11-03 16:59:48
90
原创 Rollup 构建TS项目
外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-6tO01duX-1667465752105)(/Users/chenzhonghai/Desktop/截屏2022-10-06 19.33.04.png)]最后将tsconfig.js的module改为ES2015。
2022-11-03 16:56:44
319
原创 Mitt的使用
Mitt的使用npm install mitt -Simport mitt from 'mitt'const Mit = mitt()declare module 'vue'{ export interface ComponentCustomProperties{ $Bus: typeof Mit }}app.config.globalProperties.$Bus = Mitimport { getCurrentInstance } from 'vue';c
2022-11-03 16:55:42
1357
原创 nest守卫 装饰器 swagger
nest g d其实就是封装了一下SetMetadataimport {return ctx . switchToHttp() . getRequest < Request >() . originalUrl }) //使用 findAll(@ ReqUrl() url : string)
2022-11-03 16:52:47
609
1
原创 nest模块(module)
需要在module中配置exports创建一个user模块user.module.ts中添加exportapp.module.ts中添加imports于是乎就可以在 app模块中使用user模块的service。
2022-10-20 18:20:42
712
原创 nest 提供者
controller 中能使用service 的原因是 service向module中注入的自己 一个健值对。之后controller中默认的健就会找不到 所以需要手动修改。controller通过键 拿到service。新建一个service类。还可以通过此方法传常量。还可以传递一个工厂方法。可以是一个异步的方法。
2022-10-19 22:23:35
221
原创 搭建springcloud环境
**!本人比较菜 不要喷 参考了ruoyi项目所以有很多工具包都是借鉴ruoyi中的jdk 8***mysql:8.0。
2022-10-13 19:45:02
415
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人