<div>
  <h4 style=" font-weight: bold; color : #428bca; margin-bottom:5px">
    {{'aepintervention.intervRecherche' | translate}}
  </h4>
  <button
    ng-disabled="res.int['intRech'].geometry==undefined"
    type="button"
    class="btn btn-default"
    ng-click="localiaseAno(res.int['intRech'])"
    title="{{'bizedition.attributesPopupLocate'|translate}}"
  >
    <i class="fa fa-location-arrow"></i>
  </button>

  <table class="table">
    <thead>
      <tr>
        <th style="text-align:left;color : #ff4000;">
          {{'aepintervention.infoCommunes' | translate}}
        </th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td>
          <div class="row">
            <div class="col-xs-6">
              <label for="inputKey" class=" col-form-label"
                >{{'aepintervention.dateDebut' | translate}}</label
              >
              <div
                javautildate
                gcatt="{name:'date_debut'}"
                result="res.int['intRech'].properties"
                ng-init="res.int['intRech'].properties"
                class="input-group ng-isolate-scope"
                data-type="date"
                field-data="fieldData"
              ></div>
            </div>
            <div class="col-xs-6">
              <label for="example-text-input" class="col-form-label">
                Agent</label
              >
              <div class="form-group">
                <select
                  class="form-control"
                  ng-model="res.int['intRech'].properties.agent"
                >
                  <option disabled selected hidden value>
                    -------------------
                  </option>
                  <option ng-repeat="ag in agents"> {{ag}} </option>
                </select>
              </div>
            </div>
          </div>
          <div class="row">
            <div class="col-xs-6">
              <label for="inputKey" class=" col-form-label"
                >{{'aepintervention.dateFin' | translate}}</label
              >
              <div
                javautildate
                gcatt="{name:'date_fin'}"
                result="res.int['intRech'].properties"
                ng-init="res.int['intRech'].properties"
                class="input-group ng-isolate-scope"
                data-type="date"
                field-data="fieldData"
              ></div>
            </div>
          </div>
        </td>
      </tr>
    </tbody>
  </table>

  <table class="table">
    <thead>
      <tr>
        <th style="text-align:left;color : #ff4000;">
          {{'aepintervention.descriptif' | translate}}
        </th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td>
          <div class="row">
            <label for="inputKey" class="col-xs-4 col-form-label"
              >{{'aepintervention.origine' | translate}}
            </label>
            <div
              form-field
              class="col-xs-5"
              fti="ftis['intRech']"
              ftid="ftis['intRech'].uid"
              map="map"
              attname="'rech_origine'"
              default=""
              initvalue="res.int['intRech'].properties"
              res="res.int['intRech'].properties"
            ></div>
          </div>
          <table class="table table-xs">
            <thead>
              <tr>
                <th style="text-align:left; padding-left:2px">
                  {{'aepintervention.rensTravaux' | translate}}
                </th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td>
                  <div class="row">
                    <label
                      style="font-weight:200"
                      for="example-text-input"
                      class="col-xs-4 col-form-label"
                      >{{'aepintervention.localisation' | translate}}</label
                    >
                    <div
                      form-field
                      class="col-xs-5"
                      fti="ftis['intRech']"
                      ftid="ftis['intRech'].uid"
                      map="map"
                      attname="'rech_localisation'"
                      default=""
                      initvalue="res.int['intRech'].properties"
                      res="res.int['intRech'].properties"
                    ></div>
                  </div>
                  <div class="row">
                    <label
                      style="font-weight:200"
                      for="example-text-input"
                      class="col-xs-4 col-form-label"
                      >{{'aepintervention.voie' | translate}}</label
                    >
                    <div
                      form-field
                      class="col-xs-5"
                      fti="ftis['intRech']"
                      ftid="ftis['intRech'].uid"
                      map="map"
                      attname="'rech_voie'"
                      default=""
                      initvalue="res.int['intRech'].properties"
                      res="res.int['intRech'].properties"
                    ></div>
                  </div>
                </td>
              </tr>
            </tbody>
          </table>
          <div class="row">
            <label for="inputKey" class="col-xs-4 col-form-label"
              >{{'aepintervention.materielLoc' | translate}}
            </label>
            <div
              form-field
              class="col-xs-5"
              fti="ftis['intRech']"
              ftid="ftis['intRech'].uid"
              map="map"
              attname="'rech_materiel'"
              default=""
              initvalue="res.int['intRech'].properties"
              res="res.int['intRech'].properties"
            ></div>
          </div>
          <div class="row">
            <label for="inputKey" class="col-xs-4 col-form-label"
              >{{'aepintervention.trafic' | translate}}
            </label>
            <div
              form-field
              class="col-xs-5"
              fti="ftis['intRech']"
              ftid="ftis['intRech'].uid"
              map="map"
              attname="'rech_trafic'"
              default=""
              initvalue="res.int['intRech'].properties"
              res="res.int['intRech'].properties"
            ></div>
          </div>
        </td>
      </tr>
    </tbody>
  </table>
  <!-- <button type="button" class="btn btn-default"  ng-click="addIntRech()" title="Enregistrer"><i class="glyphicon glyphicon-floppy-save"></i></button>   -->
  <button
    type="button"
    class="btn btn-default"
    ng-if="res.int['intRech'].id==undefined"
    ng-click="addIntRechAboOuv(res.int['intRech'], ftis['intRech'].uid,'Ano_IR')"
    title="{{'common.save' | translate}}"
  >
    <i class="glyphicon glyphicon-floppy-save"></i>
  </button>
  <button
    type="button"
    class="btn btn-default"
    ng-if="res.int['intRech'].id!=undefined"
    ng-disabled="currentAnomalie.properties.etat=='Dossier clos'"
    ng-click="updateIntervention(res.int['intRech'],ftis['intRech'].uid)"
    title="{{'common.save' | translate}}"
  >
    <i class="glyphicon glyphicon-floppy-save"></i>
  </button>
  <button
    type="button"
    class="btn btn-default"
    ng-disabled="currentAnomalie.properties.etat=='Dossier clos'"
    ng-if="res.int['intRech'].id!=undefined"
    ng-click="removeIntRechAboOuv(res.int['intRech'],'Ano_IR',ftis['intRech'].uid,ftis['anomalie'].uid)"
    title="{{'common.delete' | translate}}"
  >
    <i class="glyphicon glyphicon-trash"></i>
  </button>
</div>
