Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gic-demo-base
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gic_demo
gic-demo-base
Commits
a72e0cad
Commit
a72e0cad
authored
Jun 11, 2019
by
朱瑞泽
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
代码调整
parent
5cf7a0e1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
1 deletions
+21
-1
MyJavaMapperGenerator.java
.../com/gic/demo/helper/generator/MyJavaMapperGenerator.java
+20
-0
generatorConfig_test.xml
gic-demo-helper/src/main/resources/generatorConfig_test.xml
+1
-1
No files found.
gic-demo-helper/src/main/java/com/gic/demo/helper/generator/MyJavaMapperGenerator.java
0 → 100644
View file @
a72e0cad
package
com
.
gic
.
demo
.
helper
.
generator
;
import
org.mybatis.generator.api.dom.java.CompilationUnit
;
import
org.mybatis.generator.codegen.mybatis3.javamapper.JavaMapperGenerator
;
import
java.util.List
;
/**
* @author zhurz
*/
public
class
MyJavaMapperGenerator
extends
JavaMapperGenerator
{
@Override
public
List
<
CompilationUnit
>
getCompilationUnits
()
{
introspectedTable
.
setMyBatis3JavaMapperType
(
introspectedTable
.
getMyBatis3JavaMapperType
().
replace
(
"TabGic"
,
""
));
introspectedTable
.
setMyBatis3XmlMapperFileName
(
introspectedTable
.
getMyBatis3XmlMapperFileName
().
replace
(
"TabGic"
,
""
));
return
super
.
getCompilationUnits
();
}
}
gic-demo-helper/src/main/resources/generatorConfig_test.xml
View file @
a72e0cad
...
...
@@ -36,7 +36,7 @@
</sqlMapGenerator>
<!-- mapper class -->
<javaClientGenerator
type=
"
XMLMAPPER
"
<javaClientGenerator
type=
"
com.gic.demo.helper.generator.MyJavaMapperGenerator
"
targetPackage=
"com.gic.demo.project.service.dao.mapper"
targetProject=
"src/main/java"
>
<property
name=
"enableSubPackages"
value=
"true"
/>
</javaClientGenerator>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment