<section>
  <div class="page-header">
    <h1>User <span ng-bind="user.username"></span></h1>
  </div>
  <div class="col-md-12">
    <form name="userForm" ng-submit="update(userForm.$valid)" novalidate>
      <fieldset>
        <div class="form-group" show-errors>
          <label for="firstName">First Name</label>
          <input type="text" id="firstName" name="firstName" class="form-control" ng-model="user.firstName" placeholder="First Name" required />
          <div ng-messages="userForm.firstName.$error" role="alert">
            <p class="help-block error-text" ng-message="required">First name is required.</p>
          </div>
        </div>
        <div class="form-group" show-errors>
          <label for="lastName">Last Name</label>
          <input type="text" id="lastName" name="lastName" class="form-control" ng-model="user.lastName" placeholder="Last Name" required />
          <div ng-messages="userForm.lastName.$error" role="alert">
            <p class="help-block error-text" ng-message="required">Last name is required.</p>
          </div>
        </div>
        <div class="form-group" show-errors>
          <label class="control-label" for="roles">Roles</label>
          <div class="controls">
            <input class="form-control" type="text" name="roles" ng-model="user.roles" id="roles" ng-list required />
            <div ng-messages="userForm.roles.$error" role="alert">
              <p class="help-block error-text" ng-message="required">At least one role is required.</p>
            </div>
          </div>
        </div>
        <div class="form-group">
          <input type="submit" value="Update" class="btn btn-default">
        </div>
        <div ng-show="error" class="text-danger">
          <strong ng-bind="error"></strong>
        </div>
      </fieldset>
    </form>
  </div>
</section>
