diff --git a/utils/index.d.ts b/utils/index.d.ts index 2238b1f..311d73b 100644 --- a/utils/index.d.ts +++ b/utils/index.d.ts @@ -334,9 +334,9 @@ export function validatorEndTime(timeStart: string): { }; /** - * 验证结束时间是否大于等于当前时间 + * 验证时间是否大于等于当前时间 */ -export function validatorEndTimeGTCurrentDay(): { +export function validatorTimeGTCurrentDay(): { validator: (_: any, value: any) => Promise; }; diff --git a/utils/index.js b/utils/index.js index 249b47f..11a78e3 100644 --- a/utils/index.js +++ b/utils/index.js @@ -525,13 +525,13 @@ export const validatorEndTime = (timeStart) => { } /** - * 验证结束时间是否大于等于当前时间 + * 验证时间是否大于等于当前时间 */ -export const validatorEndTimeGTCurrentDay = () => { +export const validatorTimeGTCurrentDay = () => { return { validator: (_, value) => { if (value && value <= dayjs().format("YYYY-MM-DD hh:mm:ss")) { - return Promise.reject("结束时间必须大于当前时间"); + return Promise.reject("需要大于当前时间"); } else { return Promise.resolve();