diff --git a/backend/plugin/config/sql/mysql/init.sql b/backend/plugin/config/sql/mysql/init.sql index 553a9ea1..04fc0017 100644 --- a/backend/plugin/config/sql/mysql/init.sql +++ b/backend/plugin/config/sql/mysql/init.sql @@ -1,8 +1,8 @@ -insert into sys_config (id, name, type, key, value, is_frontend, remark, created_time, updated_time) +insert into sys_config (id, name, type, `key`, value, is_frontend, remark, created_time, updated_time) values -(1, '状态', 'EMAIL', 'EMAIL_STATUS', '1', 0, null, '2025-08-17 23:08:44', '2025-08-19 10:53:24'), -(2, '服务器地址', 'EMAIL', 'EMAIL_HOST', 'smtp.qq.com', 0, null, '2025-08-17 23:08:57', '2025-08-19 10:53:24'), -(3, '服务器端口', 'EMAIL', 'EMAIL_PORT', '465', 0, null, '2025-08-17 23:10:53', '2025-08-19 10:53:24'), -(4, '邮箱账号', 'EMAIL', 'EMAIL_USERNAME', 'fba@qq.com', 0, null, '2025-08-17 23:11:47', '2025-08-19 10:53:24'), -(5, '邮箱密码', 'EMAIL', 'EMAIL_PASSWORD', '', 0, null, '2025-08-17 23:12:09', '2025-08-19 10:53:24'), -(6, 'SSL 加密', 'EMAIL', 'EMAIL_SSL', '1', 0, null, '2025-08-17 23:52:46', '2025-08-19 10:53:24'); +(1, '状态', 'EMAIL', 'EMAIL_STATUS', '1', 0, null, now(), null), +(2, '服务器地址', 'EMAIL', 'EMAIL_HOST', 'smtp.qq.com', 0, null, now(), null), +(3, '服务器端口', 'EMAIL', 'EMAIL_PORT', '465', 0, null, now(), null), +(4, '邮箱账号', 'EMAIL', 'EMAIL_USERNAME', 'fba@qq.com', 0, null, now(), null), +(5, '邮箱密码', 'EMAIL', 'EMAIL_PASSWORD', '', 0, null, now(), null), +(6, 'SSL 加密', 'EMAIL', 'EMAIL_SSL', '1', 0, null, now(), null), diff --git a/backend/plugin/config/sql/mysql/init_snowflake.sql b/backend/plugin/config/sql/mysql/init_snowflake.sql index a7251e5d..e10d9dd6 100644 --- a/backend/plugin/config/sql/mysql/init_snowflake.sql +++ b/backend/plugin/config/sql/mysql/init_snowflake.sql @@ -1,8 +1,8 @@ -insert into sys_config (id, name, type, key, value, is_frontend, remark, created_time, updated_time) +insert into sys_config (id, name, type, `key`, value, is_frontend, remark, created_time, updated_time) values -(2069061886627938304, '状态', 'EMAIL', 'EMAIL_STATUS', '1', 0, null, '2025-08-17 23:08:44', '2025-08-19 10:53:24'), -(2069061886627938305, '服务器地址', 'EMAIL', 'EMAIL_HOST', 'smtp.qq.com', 0, null, '2025-08-17 23:08:57', '2025-08-19 10:53:24'), -(2069061886627938306, '服务器端口', 'EMAIL', 'EMAIL_PORT', '465', 0, null, '2025-08-17 23:10:53', '2025-08-19 10:53:24'), -(2069061886627938307, '邮箱账号', 'EMAIL', 'EMAIL_USERNAME', 'fba@qq.com', 0, null, '2025-08-17 23:11:47', '2025-08-19 10:53:24'), -(2069061886627938308, '邮箱密码', 'EMAIL', 'EMAIL_PASSWORD', '', 0, null, '2025-08-17 23:12:09', '2025-08-19 10:53:24'), -(2069061886627938309, 'SSL 加密', 'EMAIL', 'EMAIL_SSL', '1', 0, null, '2025-08-17 23:52:46', '2025-08-19 10:53:24'); +(2069061886627938304, '状态', 'EMAIL', 'EMAIL_STATUS', '1', 0, null, now(), null), +(2069061886627938305, '服务器地址', 'EMAIL', 'EMAIL_HOST', 'smtp.qq.com', 0, null, now(), null), +(2069061886627938306, '服务器端口', 'EMAIL', 'EMAIL_PORT', '465', 0, null, now(), null), +(2069061886627938307, '邮箱账号', 'EMAIL', 'EMAIL_USERNAME', 'fba@qq.com', 0, null, now(), null), +(2069061886627938308, '邮箱密码', 'EMAIL', 'EMAIL_PASSWORD', '', 0, null, now(), null), +(2069061886627938309, 'SSL 加密', 'EMAIL', 'EMAIL_SSL', '1', 0, null, now(), null), diff --git a/backend/plugin/config/sql/postgresql/init.sql b/backend/plugin/config/sql/postgresql/init.sql index eae239dd..8a8a9438 100644 --- a/backend/plugin/config/sql/postgresql/init.sql +++ b/backend/plugin/config/sql/postgresql/init.sql @@ -1,11 +1,11 @@ -insert into sys_config (id, name, type, key, value, is_frontend, remark, created_time, updated_time) +insert into sys_config (id, name, type, "key", value, is_frontend, remark, created_time, updated_time) values -(1, '状态', 'EMAIL', 'EMAIL_STATUS', '1', 0, null, '2025-08-17 23:08:44', '2025-08-19 10:53:24'), -(2, '服务器地址', 'EMAIL', 'EMAIL_HOST', 'smtp.qq.com', 0, null, '2025-08-17 23:08:57', '2025-08-19 10:53:24'), -(3, '服务器端口', 'EMAIL', 'EMAIL_PORT', '465', 0, null, '2025-08-17 23:10:53', '2025-08-19 10:53:24'), -(4, '邮箱账号', 'EMAIL', 'EMAIL_USERNAME', 'fba@qq.com', 0, null, '2025-08-17 23:11:47', '2025-08-19 10:53:24'), -(5, '邮箱密码', 'EMAIL', 'EMAIL_PASSWORD', '', 0, null, '2025-08-17 23:12:09', '2025-08-19 10:53:24'), -(6, 'SSL 加密', 'EMAIL', 'EMAIL_SSL', '1', 0, null, '2025-08-17 23:52:46', '2025-08-19 10:53:24'); +(1, '状态', 'EMAIL', 'EMAIL_STATUS', '1', 0, null, now(), null), +(2, '服务器地址', 'EMAIL', 'EMAIL_HOST', 'smtp.qq.com', 0, null, now(), null), +(3, '服务器端口', 'EMAIL', 'EMAIL_PORT', '465', 0, null, now(), null), +(4, '邮箱账号', 'EMAIL', 'EMAIL_USERNAME', 'fba@qq.com', 0, null, now(), null), +(5, '邮箱密码', 'EMAIL', 'EMAIL_PASSWORD', '', 0, null, now(), null), +(6, 'SSL 加密', 'EMAIL', 'EMAIL_SSL', '1', 0, null, now(), null), -- reset auto-increment values for each table based on max id select setval(pg_get_serial_sequence('sys_config', 'id'),coalesce(max(id), 0) + 1, true) from sys_config; diff --git a/backend/plugin/config/sql/postgresql/init_snowflake.sql b/backend/plugin/config/sql/postgresql/init_snowflake.sql index a7251e5d..49c86712 100644 --- a/backend/plugin/config/sql/postgresql/init_snowflake.sql +++ b/backend/plugin/config/sql/postgresql/init_snowflake.sql @@ -1,8 +1,8 @@ -insert into sys_config (id, name, type, key, value, is_frontend, remark, created_time, updated_time) +insert into sys_config (id, name, type, "key", value, is_frontend, remark, created_time, updated_time) values -(2069061886627938304, '状态', 'EMAIL', 'EMAIL_STATUS', '1', 0, null, '2025-08-17 23:08:44', '2025-08-19 10:53:24'), -(2069061886627938305, '服务器地址', 'EMAIL', 'EMAIL_HOST', 'smtp.qq.com', 0, null, '2025-08-17 23:08:57', '2025-08-19 10:53:24'), -(2069061886627938306, '服务器端口', 'EMAIL', 'EMAIL_PORT', '465', 0, null, '2025-08-17 23:10:53', '2025-08-19 10:53:24'), -(2069061886627938307, '邮箱账号', 'EMAIL', 'EMAIL_USERNAME', 'fba@qq.com', 0, null, '2025-08-17 23:11:47', '2025-08-19 10:53:24'), -(2069061886627938308, '邮箱密码', 'EMAIL', 'EMAIL_PASSWORD', '', 0, null, '2025-08-17 23:12:09', '2025-08-19 10:53:24'), -(2069061886627938309, 'SSL 加密', 'EMAIL', 'EMAIL_SSL', '1', 0, null, '2025-08-17 23:52:46', '2025-08-19 10:53:24'); +(2069061886627938304, '状态', 'EMAIL', 'EMAIL_STATUS', '1', 0, null, now(), null), +(2069061886627938305, '服务器地址', 'EMAIL', 'EMAIL_HOST', 'smtp.qq.com', 0, null, now(), null), +(2069061886627938306, '服务器端口', 'EMAIL', 'EMAIL_PORT', '465', 0, null, now(), null), +(2069061886627938307, '邮箱账号', 'EMAIL', 'EMAIL_USERNAME', 'fba@qq.com', 0, null, now(), null), +(2069061886627938308, '邮箱密码', 'EMAIL', 'EMAIL_PASSWORD', '', 0, null, now(), null), +(2069061886627938309, 'SSL 加密', 'EMAIL', 'EMAIL_SSL', '1', 0, null, now(), null),