for each (var validator:Validator in requiredValidator.validators)
{
if (validator.property == "usr_id" && !isBuyer)
{
continue;
}
else
{
var e:ValidationResultEvent = validator.validate();
if (e.type == ValidationResultEvent.INVALID)
{
SCAlert.show("M000016");
return;
}
}
}
// for each (var event:ValidationResultEvent in requiredValidator.invalidate())
// {
// SCAlert.show("M000016");
// return;
// }
if (!StringUtil.isNullTrim(_userInfo.email))
{
var emailValidator:SCEmailValidator = new SCEmailValidator();
var e:ValidationResultEvent = emailValidator.validate(_userInfo.email);
if (e.type == ValidationResultEvent.INVALID)
{
SCAlert.show(e.message);
return;
}
// if (!checkMail(_userInfo.email))
// {
// SCAlert.show("M000005"); // email형식이 잘못되었습니다.
// return;
// }
}
[한X] validators 활용
|
2016.10.13 18:45:53
|
2016.10.19 08:40:48
|
401
|
Aiden
Total of Attached file
0.00 Bytes of 0 files
2016.11.15
2016.10.19
2016.10.19
2016.10.14
2016.10.13
2016.10.07
2016.10.07
2016.10.07
2016.08.22
2016.06.23