ÎļþÃû´Ó ruoyi/src/main/java/com/ruoyi/framework/config/GenConfig.java ÐÞ¸Ä |
| | |
| | | package com.ruoyi.framework.config;
|
| | | package com.ruoyi.generator.config;
|
| | |
|
| | | import org.springframework.beans.factory.annotation.Value;
|
| | | import org.springframework.boot.context.properties.ConfigurationProperties;
|
| | | import org.springframework.context.annotation.PropertySource;
|
| | | import org.springframework.stereotype.Component;
|
| | |
|
| | | /**
|
| | |
| | | */
|
| | | @Component
|
| | | @ConfigurationProperties(prefix = "gen")
|
| | | @PropertySource(value = { "classpath:generator.yml" })
|
| | | public class GenConfig
|
| | | {
|
| | | /** ä½è
*/
|
| | |
| | | /** çæå
è·¯å¾ */
|
| | | public static String packageName;
|
| | |
|
| | | /** èªå¨å»é¤è¡¨åç¼ï¼é»è®¤æ¯true */
|
| | | /** èªå¨å»é¤è¡¨åç¼ï¼é»è®¤æ¯false */
|
| | | public static boolean autoRemovePre;
|
| | |
|
| | | /** 表åç¼(ç±»åä¸ä¼å
å«è¡¨åç¼) */
|
| | |
| | | return author;
|
| | | }
|
| | |
|
| | | @Value("${author}")
|
| | | public void setAuthor(String author)
|
| | | {
|
| | | GenConfig.author = author;
|
| | |
| | | return packageName;
|
| | | }
|
| | |
|
| | | @Value("${packageName}")
|
| | | public void setPackageName(String packageName)
|
| | | {
|
| | | GenConfig.packageName = packageName;
|
| | |
| | | return autoRemovePre;
|
| | | }
|
| | |
|
| | | @Value("${autoRemovePre}")
|
| | | public void setAutoRemovePre(boolean autoRemovePre)
|
| | | {
|
| | | GenConfig.autoRemovePre = autoRemovePre;
|
| | |
| | | return tablePrefix;
|
| | | }
|
| | |
|
| | | @Value("${tablePrefix}")
|
| | | public void setTablePrefix(String tablePrefix)
|
| | | {
|
| | | GenConfig.tablePrefix = tablePrefix;
|