本文共 643 字,大约阅读时间需要 2 分钟。
1.springboot配置文件application.yml里面添加mybatis依赖
代码 如下:
mybatis: type-aliases-package: com.jerryl.activiti.entity mapper-locations: classpath:mapper/*.xml check-config-location: true
2.pom.xml里面添加mybatis依赖
代码如下:
org.mybatis.spring.boot mybatis-spring-boot-starter 1.3.2
3、创建Mapper
package com.jerryl.mapper;import com.jerryl.activiti.entity.DeploymentEntity;import org.apache.ibatis.annotations.Mapper;/** * @Description TODO * @Date 2019/8/27 15:18 * @Created by xiayunan */@Mapperpublic interface DeploymentMapper { int insertOne(DeploymentEntity deploymentEntity);}
4、创建XML
5.测试
转载地址:http://pjne.baihongyu.com/