adonisjs / validator

Schema based validator for AdonisJS
MIT License
115 stars 40 forks source link

Need to add validation for ro-MD #139

Closed mik7up closed 2 years ago

mik7up commented 2 years ago

https://github.com/validatorjs/validator.js/issues/1931

Need to add validation for Moldova republic of mobile phone numbers. https://github.com/validatorjs/validator.js/edit/master/src/lib/isMobilePhone.js

'ro-MD': /^(+?373|0)((6(0|1|2|6|7|8|9))|(7(7|8|9)))\d{6}$/

https://www.localeplanet.com/icu/ro-MD/index.html

60 xxxxxx — Orange 61 xxxxxx — Orange 62 xxxxxx — Orange 66 xxxxxx — Unité 67 xxxxxx — Unité 68 xxxxxx — Orange 69 xxxxxx — Orange 78 xxxxxx — Moldcell 79 xxxxxx — Moldcell 77 xxxxxx — IDC

RomainLanz commented 2 years ago

Hey @mik7up! 👋🏻

This is not something we are handling. In the meanwhile, feel free to create a custom rule to support your case.