Using <select> tag with <option>
Closed this issue · 0 comments
klaydze commented
I'm not sure if showErrors can handle <select> tag. After implementing show-errors, it does not validate my dropdown.
<div class="form-group" show-errors> <label for="department" class="control-label col-md-2">Department</label> <div class="col-md-10"> <select class="form-control" id="department" name="department" ng-model="employee.departmentId" required> <option ng-repeat="d in departments" value="{{d.DepartmentID}}">{{d.DepartmentName}}</option> </select> <p class="help-block" ng-if="employeeFrm.department.$error.required">The department is required</p> </div> </div>
Thanks