mirror of
https://github.com/jxxghp/MoviePilot-Frontend.git
synced 2026-05-13 17:31:23 +08:00
12 lines
282 B
TypeScript
12 lines
282 B
TypeScript
import type { ValidationRule } from 'vuetify/types/services/validation'
|
|
|
|
// 必输校验
|
|
export const requiredValidator: ValidationRule = (value: any) => {
|
|
return !!value
|
|
}
|
|
|
|
// 数字校验
|
|
export const numberValidator: ValidationRule = (value: any) => {
|
|
return !isNaN(value)
|
|
}
|