Tenho um modal em que preciso obrigar que o usuário selecione uma opção do combo e também insira um valor no campo de input. Usei a diretiva ng-required e para exibir a mensagem de erro mas mesmo assim ele não está obrigando, Alguma idéia:
Desde já obrigado.
// **** html do Combo ******
<div class="modal-body">{{'application.outbound.outboundBatchControl.wantToSeparation'| translate}}</div>
<div class="form-group">
<select ng-model="selectedLabelType"
style="width: 500px"
name="labelType"
id="labelType"
class="form-control"
ng-options="labelType as labelType.label for labelType in labelType track by labelType.id"
placeholder="{{'application.msg.labelSelect.labelType' | translate}}"
ng-required="true">
<span ng-class="error" ng-show="modalReprint.$error.required">Campo Combo é obrigatorio</span>
<option value="" >{{'application.msg.labelSelect.labelType' | translate}}</option>
</select>
</div>
// ********** html do Input ***********
<div class="form-group">
<label for="LabelTo" class="control-label" translate>Label To</label>
<input ng-model="inputPriorityTo"
style="width: 500px"
id="priorityTo"
name="priorityTo"
type="text"
class="form-control fontSizeItemReceiving"
maxlength="20"
ng-required="true"/>
<span ng-class="error" ng-show="modalReprint.$error.required">Campo From é obrigatorio</span>
</div>