<div class="container-fluid">
<div class="row">
  <div class="col-sm-6 col-sm-offset-3">
    <div ng-controller="SIPAccountAdminCtrl">
      <form role="form" name="sipAccountForm"
        ng-repeat="sip_account in sipAccounts">
        <h1>{{sip_account.name}}</h1>
        <div class="form-group has-feedback" ng-class="{'has-error' : sipAccountForm.sipDomainInput.$invalid}">
          <label for="sipDomainInput{{index}}">SIP DOMAIN</label>
          <input type="text" class="form-control" id="sipDomainInput{{index}}" name="sipDomainInput"
            ng-model="sip_account.sip_domain"
            required/>
            <span class='glyphicon glyphicon-remove form-control-feedback'
      	ng-show="sipAccountForm.sipDomainInput.$invalid"></span>
        </div>
        <div class="form-group has-feedback" ng-class="{'has-error' : sipAccountForm.sipUserInput.$invalid}">
          <label for="sipUserInput{{index}}">SIP USER</label>
          <input type="text" class="form-control" id="sipUserInput{{index}}" name="sipUserInput"
            ng-model="sip_account.sip_user"
            required/>
            <span class='glyphicon glyphicon-remove form-control-feedback'
      	ng-show="sipAccountForm.sipUserInput.$invalid"></span>
        </div>
        <div class="form-group has-feedback" ng-class="{'has-error' : sipAccountForm.sipPasswordInput.$invalid}">
          <label for="sipPasswordInput{{index}}">SIP PASSWORD</label>
          <input type="text" class="form-control" id="sipPasswordInput{{index}}" name="sipPasswordInput"
            ng-model="sip_account.sip_password"
            required/>
            <span class='glyphicon glyphicon-remove form-control-feedback'
      	ng-show="sipAccountForm.sipPasswordInput.$invalid"></span>
        </div>
        <button type="submit" class="btn btn-danger"
          ng-disabled="sipAccountForm.$invalid"
          ng-click="update(sip_account)">Apply Settings</button>
      </form>
    {{sent}}
    </div>
  </div>
</div>
</div>
