![](https://img-blog.csdnimg.cn/20201014180756922.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
SpringBoot
sylvia_lily
这个作者很懒,什么都没留下…
展开
-
axios的post请求和get请求发送
要注意post请求参数只能后端@requestBody接收get请求参数只能后端@requestParam接收 this.$axios.get('/payTest',{params:{totalPrice:this.map.totalPrice}}) .then(res => { console.log(res.data.data) thi原创 2021-06-24 14:27:33 · 135 阅读 · 0 评论 -
springboot中使用mybatis-plus开启驼峰命名
mybatis: configuration: #开启驼峰命名 map-underscore-to-camel-case: true原创 2021-06-21 11:30:43 · 3709 阅读 · 0 评论 -
使用自定义注解和aop对用户的行为记录进行存储
@Component@Aspectpublic class LogProcess { /** * 线程池多少个: * 1. 如果是IO密集型应用, 是CPU核心的两倍. * 2. 如果是CPU密集型应用, 是cup核心数 + 1 */ //创建线程池 private ExecutorService executorService = Executors.newFixedThreadPool(16); private P原创 2021-06-20 01:14:13 · 140 阅读 · 0 评论 -
使用ControllerAdvice注解来进行全局数据处理
@ControllerAdvice ,这是一个增强的 Controller。使用这个 Controller ,可以实现三个方面的功能:全局异常处理全局数据绑定全局数据预处理处理所有controller返回的数据//定义一个全局的响应//@ControllerAdvice,所有的Controller只要执行,这个地方就会得到通知@ControllerAdvice(value = {"com.hubu.controller"})public class GlobalResponse impl原创 2021-06-19 21:57:17 · 311 阅读 · 0 评论 -
SpringBoot的环境搭建及使用
Spring-boot一. 第一个Spring-boot的应用1.1 maven配置 在maven文件中加入如下的依赖:<parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>2.1.6.RELEASE</version><原创 2021-06-07 19:19:47 · 160 阅读 · 3 评论