0
ための角度JSの検証は誰が電話番号の検証で私を助けることができるとEメールEメールおよび電話番号
<div class="form-group" ng-if="notificationMethod == 'call' || notificationMethod == 'text'" >
<label for="phoneNumber">Phone Number</label>
<input type="phoneNumber" class="form-control" id="phoneNumber" placeholder="Enter Phone Number" ng-model="phoneNumberToBeNotified" ng-minlength="10" ng-maxlength="10" ng-pattern="^\d{4}-\d{3}-\d{4}$" required/>
<!-- <span class="error" style="color:#ff0000;" ng-show="myForm.phoneNumber.$error.required"> This field is required </span>
<span class="error" style="color:#ff0000;" ng-show="myForm.phoneNumber.$error.minlength"> Mobile number should be of 10 digits </span><br>
<span class="error" style="color:#ff0000;" ng-show="myForm.phoneNumber.$error.minlength"> Mobile number should be of 10 digits </span> -->
</div>
<div class="form-group" ng-if="notificationMethod == 'email'">
<label for="email">E-Mail</label>
<input type="email" class="form-control" name="email" placeholder="Enter Email" ng-model="emailToBeNotified" required/>
<span ng-show="myForm.email.$error.required"> This field is required </span>
<span ng-show="myForm.email.$error.email"> Not a valid email </span>
</div>
を追加するには、電話番号の検証で私を助けることができますか? –