<!-- List box for 1:n and m:n relations -->
<!--
  <table>
  -->
<table ng-show="theField01.objectId!=null" style="color:black;">
  <tr height="4">
    <td colspan="6"></td>
  </tr>
  <tr ng-if="theField01.showList" bgcolor="#f8f8f8">
    <td>
      {{theField01.fieldDesc.alias}}
    </td>
    <td style="width:25px;"></td>
    <td>
      <select
        class=""
        data-ng-attr-size="{{theField01.lineNumber}}"
        style="width:{{theField01.width}};"
        ng-change="objectHasBeenSelected()"
        ng-model="selectedObject.code"
      >
        <option
          ng-repeat="desc in options"
          value="{{desc.code}}"
          title="{{desc.value}}"
        >
          {{desc.value}}
        </option>
      </select>
    </td>
    <td style="width:25px;"></td>
    <td ng-if="useTableSelect">
      <button
        ng-click="openTableSelect()"
        title="Ouvrir la liste de choix"
        ng-disabled="theField01.mode=='readonly'"
      >
        <img src="img/common/16px-List-add.png" />
      </button>
      <br />
      <button
        ng-click="removeSelectedObjFromRelation()"
        title="Enlever l'élément sélectionné"
        ng-disabled="theField01.mode=='readonly' || removeCmdIsDisabled"
      >
        <img src="img/common/16px-List-remove.png" />
      </button>
    </td>
    <td>
      <table halign="center" ng-show="theField01.mode!='readonly'">
        <tr>
          <td>
            <button
              ng-if="theField01.relation.occurence=='1-N'"
              ng-click="moveObject(-1)"
              ng-disabled="theField01.mode=='readonly' || selectedObject.code==null"
            >
              Monter
            </button>
          </td>
        </tr>
        <tr>
          <td>
            <button
              ng-if="theField01.relation.occurence=='1-N'"
              ng-click="addRelatedObject()"
              ng-disabled="theField01.mode=='readonly'"
            >
              <img src="img/common/16px-List-add.png" />
            </button>
          </td>
          <td>
            <button
              ng-if="theField01.relation.occurence=='1-N'"
              ng-click="delRelatedObject()"
              ng-disabled="theField01.mode=='readonly' || selectedObject.code==null"
              title="Supprimer"
            >
              <img src="img/common/16px-List-remove.png" />
            </button>
          </td>
        </tr>
        <tr>
          <td colspan="2">
            <button
              ng-if="theField01.relation.occurence=='1-N'"
              ng-click="moveObject(1)"
              ng-disabled="theField01.mode=='readonly' || selectedObject.code==null"
            >
              Descendre
            </button>
          </td>
        </tr>
        <tr></tr>
        <tr>
          <td colspan="2" ng-if="!useTableSelect">
            <input
              type="radio"
              name="mode"
              value="create"
              ng-model="radioMode.value"
              ng-change="modeHasChanged()"
            />Création<br />
            <input
              type="radio"
              name="mode"
              value="view"
              ng-model="radioMode.value"
              ng-change="modeHasChanged()"
            />Consultation
          </td>
        </tr>
      </table>
    </td>
  </tr>

  <tr>
    <td colspan="5">
      <div
        ffpl2Directive
        my-field="{{theField01}}"
        id-of-direct-parent-scope="{{$parent.$id}}"
        ng-if="theField01.fieldDesc.inlineInput && theField01.inlineConfig.contentType=='panelContainer' && !showTable"
      ></div>

      <div fftablel2Directive my-field="{{theField01}}" ng-if="showTable"></div>
    </td>
  </tr>
</table>
