From fedcec4da39256d5bc149669aa3e8ea22b9e4fe1 Mon Sep 17 00:00:00 2001 From: dengqichen Date: Fri, 6 Dec 2024 14:10:50 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=88=90workingDirectory?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/resources/db/migration/V1.0.1__init_data.sql | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/backend/src/main/resources/db/migration/V1.0.1__init_data.sql b/backend/src/main/resources/db/migration/V1.0.1__init_data.sql index a3aef1ef..e9bffe25 100644 --- a/backend/src/main/resources/db/migration/V1.0.1__init_data.sql +++ b/backend/src/main/resources/db/migration/V1.0.1__init_data.sql @@ -427,8 +427,9 @@ true, NOW(), 'system', NOW(), 'system', 1, false), "cron": { "type": "string", "title": "CRON表达式", - "pattern": "^(\\d+|\\*|\\*/\\d+|\\d+\\-\\d+|\\d+(,\\d+)*) (\\d+|\\*|\\*/\\d+|\\d+\\-\\d+|\\d+(,\\d+)*) (\\d+|\\*|\\*/\\d+|\\d+\\-\\d+|\\d+(,\\d+)*) (\\d+|\\*|\\*/\\d+|\\d+\\-\\d+|\\d+(,\\d+)*) (\\d+|\\*|\\*/\\d+|\\d+\\-\\d+|\\d+(,\\d+)*) (\\d+|\\*|\\*/\\d+|\\d+\\-\\d+|\\d+(,\\d+)*)$", - "description": "定时触发的CRON表达式" + "description": "定时触发的CRON表达式(秒 分 时 日 月 周)", + "pattern": "^\\s*($|[0-9\\-*/,]+\\s+[0-9\\-*/,]+\\s+[0-9\\-*/,]+\\s+[0-9\\-*/,]+\\s+[0-9\\-*/,]+\\s+[0-9\\-*/,?]+)\\s*$", + "examples": ["0 0 * * * ?", "0 0/5 * * * ?", "0 0 8 * * ?"] } }, "required": ["name", "cron"]