- 博客(5)
- 收藏
- 关注
原创 vuex
const userModule = { namespaced: true, state: { 原始数据 }, mutations: { test(statem,params){} 只能通过它直接修改state里的数据 }, actions: { test(context,params){ context.commit('test',params) } },}调用...mapActions('
2020-06-26 17:18:12 84
原创 vue router
1. this.$router.push({name: 'Home'})2. this.$router.replace({name: 'Home'}) 都是跳转到指定路由 , push会在history添加记录 点击回退 , 返回上一个页面.. replace 不会返回上一个页面路由传参 url传参<router-link :to="'/user/'+(item)"> 路由为/user/:id获取参数: <p>{{thi
2020-06-26 16:49:35 76
原创 @Validated的基础校验和分组校验
实现新增用户时 id为null,修改用户时id不为null的功能@Datapublic class User { public interface add { } /** * 未使用分组的字段在默认分组Default里 */ public interface update extends Default { } ...
2020-03-21 16:15:35 343
原创 记录下@JsonView注解的使用
1. 简单使用@Data@AllArgsConstructorpublic class User { @JsonView(UserViews.UserSimpleView.class) private Long id; @JsonView(UserViews.UserSimpleView.class) private String name; @...
2020-03-20 13:44:07 223
原创 spring事务传播行为required 和 requies_new
@Transactional(propagation = Propagation.REQUIRED) A(大方法){ B(); REQUIRED C();REQUIRES_NEW E();REQUIRED F();REQUIRES_NEW ...
2020-03-20 12:31:26 527
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人