Skip to content

Commit

Permalink
update: 自动建表 mysql使用utf8mb4字符集
Browse files Browse the repository at this point in the history
  • Loading branch information
Wizzercn committed Jul 7, 2022
1 parent bb5ed12 commit b242ff7
Show file tree
Hide file tree
Showing 37 changed files with 37 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
<mysql-connector-java.version>8.0.16</mysql-connector-java.version>
<jaxb-api.version>2.3.1</jaxb-api.version>
<slf4j.version>1.7.25</slf4j.version>
<logback.version>1.2.3</logback.version>
<logback.version>1.2.9</logback.version>
<sa-token.version>1.25.0</sa-token.version>
<easy-captcha.version>1.6.2</easy-captcha.version>
<commons-lang3.version>3.8.1</commons-lang3.version>
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/cms/models/Cms_article.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
*/
@Data
@Table("cms_article")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Cms_article extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/cms/models/Cms_channel.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
*/
@Data
@Table("cms_channel")
@TableMeta("{'mysql-charset':'utf8mb4'}")
@TableIndexes({@Index(name = "INDEX_CHANNEL", fields = {"code"}, unique = true)})
public class Cms_channel extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/cms/models/Cms_link.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
*/
@Data
@Table("cms_link")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Cms_link extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/cms/models/Cms_link_class.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
*/
@Data
@Table("cms_link_class")
@TableMeta("{'mysql-charset':'utf8mb4'}")
@TableIndexes({@Index(name = "INDEX_CMS_LINK_CLASS", fields = {"code"}, unique = true)})
public class Cms_link_class extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/cms/models/Cms_site.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
*/
@Data
@Table("cms_site")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Cms_site extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_api.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("sys_api")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Sys_api extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;

Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_app_conf.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
* Created by wizzer on 2019/2/27.
*/
@Table("sys_app_conf")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Sys_app_conf extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;

Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_app_list.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
*/
@Data
@Table("sys_app_list")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Sys_app_list extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;

Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_app_task.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
*/
@Data
@Table("sys_app_task")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Sys_app_task extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;

Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_config.java
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("sys_config")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Sys_config extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Name
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_dict.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("sys_dict")
@TableMeta("{'mysql-charset':'utf8mb4'}")
@TableIndexes({@Index(name = "INDEX_SYS_DICT_PATH", fields = {"path"}, unique = true)})
public class Sys_dict extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_log.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("sys_log_${month}")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Sys_log extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_menu.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("sys_menu")
@TableMeta("{'mysql-charset':'utf8mb4'}")
@TableIndexes({@Index(name = "INDEX_SYS_MENU_PATH", fields = {"path"}, unique = true), @Index(name = "INDEX_SYS_MENU_PREM", fields = {"permission"}, unique = true)})
public class Sys_menu extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_msg.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("sys_msg")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Sys_msg extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_msg_user.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("sys_msg_user")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Sys_msg_user extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_role.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("sys_role")
@TableMeta("{'mysql-charset':'utf8mb4'}")
@TableIndexes({@Index(name = "INDEX_SYS_ROLE_CODE", fields = {"code"}, unique = true)})
public class Sys_role extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_route.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("sys_route")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Sys_route extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_task.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("sys_task")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Sys_task extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_unit.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("sys_unit")
@TableMeta("{'mysql-charset':'utf8mb4'}")
@TableIndexes({@Index(name = "INDEX_SYS_UNIT_PATH", fields = {"path"}, unique = true),
@Index(name = "INDEX_SYS_UNIT_UNITCODE", fields = {"unitcode"}, unique = true)
})
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/sys/models/Sys_user.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("sys_user")
@TableMeta("{'mysql-charset':'utf8mb4'}")
@J4EName("用户数据")
@TableIndexes({@Index(name = "INDEX_SYS_USER_LOGINNAMAE", fields = {"loginname"}, unique = true)})
public class Sys_user extends BaseModel implements Serializable {
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_config.java
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_config")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Wx_config extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_mass.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_mass")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Wx_mass extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_mass_news.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_mass_news")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Wx_mass_news extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_mass_send.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_mass_send")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Wx_mass_send extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_menu.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_menu")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Wx_menu extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_msg.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_msg")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Wx_msg extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_msg_reply.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_msg_reply")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Wx_msg_reply extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_reply.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_reply")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Wx_reply extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_reply_img.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_reply_img")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Wx_reply_img extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_reply_news.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_reply_news")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Wx_reply_news extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_reply_txt.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_reply_txt")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Wx_reply_txt extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_tpl_id.java
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_tpl_id")
@TableMeta("{'mysql-charset':'utf8mb4'}")
@TableIndexes({@Index(name = "INDEX_WX_TPL_ID", fields = {"id", "wxid"}, unique = true)})
public class Wx_tpl_id extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_tpl_list.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_tpl_list")
@TableMeta("{'mysql-charset':'utf8mb4'}")
@TableIndexes({@Index(name = "INDEX_WX_TPL_LIST", fields = {"template_id","wxid"}, unique = true)})
public class Wx_tpl_list extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_tpl_log.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_tpl_log")
@TableMeta("{'mysql-charset':'utf8mb4'}")
public class Wx_tpl_log extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
@Column
Expand Down
1 change: 1 addition & 0 deletions src/main/java/com/budwk/app/wx/models/Wx_user.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
@Data
@EqualsAndHashCode(callSuper = true)
@Table("wx_user")
@TableMeta("{'mysql-charset':'utf8mb4'}")
@TableIndexes({@Index(name = "INDEX_WX_USER_OPENID", fields = {"openid"}, unique = true)})
public class Wx_user extends BaseModel implements Serializable {
private static final long serialVersionUID = 1L;
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/application.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ quartz:
#Other delegates can see: http://www.quartz-scheduler.org/documentation/quartz-2.x/tutorials/tutorial-lesson-09.html
dataSource: myDS
tablePrefix: SYS_QRTZ_
isClustered: true
isClustered: false
clusterCheckinInterval: 20000
maxMisfiresToHandleAtATime: 120
misfireThreshold: 120000
Expand Down

0 comments on commit b242ff7

Please sign in to comment.