<ion-view title="Contact">

  <ion-content class="has-header padding">
    <div class="bar bar-positive" style="margin-bottom: 8px; position: relative;" ng-show="result">{{result}}</div>
    <form ng-submit="sendContact()">
      <div class="list">
        <label class="item item-input item-stacked-label">
          <span class="input-label">First Name</span>
          <input type="text" ng-model="contact.first_name" placeholder="Enter First Name">
        </label>
        <label class="item item-input item-stacked-label">
          <span class="input-label">Last Name</span>
          <input type="text" ng-model="contact.last_name" placeholder="Enter Last Name">
        </label>
        <label class="item item-input item-stacked-label">
          <span class="input-label">Phone #</span>
          <input type="text" ng-model="contact.phone" placeholder="Enter Phone Number">
        </label>
        <label class="item item-input item-stacked-label">
          <span class="input-label">Email</span>
          <input type="text" ng-model="contact.email" placeholder="Enter Email">
        </label>
        <label class="item item-input  item-stacked-label item-select">
          <select ng-model="contact.reason"
                  ng-init="contact.reason = reasons[0]"
                  ng-options="reason as reason.name for reason in reasons track by reason.id">
          </select>
        </label>
        <label class="item item-input item-stacked-label">
          <span class="input-label">Message</span>
          <input type="text" ng-model="contact.message" placeholder="Enter any comments">
        </label>
        <padding>
          <button class="button button-balanced button-block" ng-disabled="!contact.email || !contact.first_name || !contact.last_name">
            Send
          </button>
        </padding>
      </div>
    </form>
  </ion-content>
</ion-view>