mirror of
https://github.com/thousmile/molly-multi-tenant.git
synced 2025-12-30 04:32:26 +00:00
1.添加 @Validated分组校验参数!
This commit is contained in:
@@ -97,13 +97,13 @@ export function isCompress(value: string) {
|
||||
|
||||
/** 用户密码 */
|
||||
export function isPassword(value: string) {
|
||||
const reg = /^(?=.*[a-zA-Z])(?=.*[0-9])[A-Za-z0-9]{5,24}$/
|
||||
const reg = /^(?=.*[a-zA-Z])(?=.*[0-9])[A-Za-z0-9]{5,32}$/
|
||||
return reg.test(value)
|
||||
}
|
||||
|
||||
/** 用户名称 */
|
||||
export function isUsername(value: string) {
|
||||
const reg = /^[a-zA-Z0-9_-]{5,24}$/
|
||||
const reg = /^[a-zA-Z0-9_-]{5,32}$/
|
||||
return reg.test(value)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user