zl程序教程

您现在的位置是:首页 >  后端

当前栏目

SpringBoot集成mybatis

2023-09-27 14:26:27 时间
mybatis-plus:
  configuration:
  ## 设成trueDO模型字段命名必须采用驼峰方式
  map-underscore-to-camel-case: false
  log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
mybatis-plus:
  type-aliases-package: com.znsd.springboot.springbootdubboapi.model
  type-aliases-super-type: java.lang.Object
  configuration:
    map-underscore-to-camel-case: true
    cache-enabled: true
    lazy-loading-enabled: true
    multiple-result-sets-enabled: true
    use-generated-keys: true
    default-statement-timeout: 60
    default-fetch-size: 100
  mapper-locations: classpath*:mybatis-mappings/*.xml
		<!-- mybatisplus -->
		<dependency>
	        <groupId>com.baomidou</groupId>
	        <artifactId>mybatis-plus-boot-starter</artifactId>
	        <version>3.4.0</version>
	   </dependency>
	   <dependency>
	        <groupId>com.baomidou</groupId>
	        <artifactId>mybatis-plus-generator</artifactId>
	        <version>3.4.0</version>
	   </dependency>
	   

参考