import"./useForm-Dx3lJ3DG.js";import{m as c}from"./index-CLZzJyTP.js";import{h as u,i as d}from"./componentMap-DpsJvoqz.js";import"./JAreaLinkage-M9TGy8nY.js";import"./JSelectUser-CfAGgHjD.js";import"./JSelectDept-CaEHrQp6.js";import"./JCodeEditor-CR57XeIe.js";import"./JAddInput-B36c3B5x.js";import"./JPopup-BvqhHpPl.js";import{C as n}from"./EasyCronInput-CWOTSpxK.js";import"./JEllipsis-C_gT_vEQ.js";import"./JDictSelectTag-CfF54ALX.js";import"./JImageUpload-BFwNYdm5.js";const m={validator({},o){if(!o)return Promise.resolve();const e=o.split(" ").filter(r=>!!r);if(e.length>7)return Promise.reject("Cron表达式最多7项！");let i=o;if(e.length===7){const r=e[6];if(r!=="*"&&r!=="?"){let t=[];if(r.indexOf("-")>=0?t=r.split("-"):r.indexOf("/")?t=r.split("/"):t=[r],t.some(s=>isNaN(Number(s))))return Promise.reject("Cron表达式参数[年]错误："+r)}i=e.slice(0,6).join(" ")}try{return n.parseExpression(i).next(),Promise.resolve()}catch(r){return Promise.reject("Cron表达式错误："+r)}}},J=m.validator;export{J};
