<!-- Composant de visualisation des objets partagés par l'ensemble des config de règles -->
<cfg-rules-infos
  id="updateCfgRulesInfos"
  featuretype="currentfeaturetype">
</cfg-rules-infos>
<br/>

<label class="rulesCfgTitle" translate>rulecfg.lineSnappedOnFeature.endLineSnappedOnPoint.title</label>
<br />
<div ng-if="currentfeaturetype.typeInfo === 'LINE' ">
  <div ng-if="editTypeList">
    <div 
      dual-list-box
      class="ruleCfgEditTypeList"
      data="editTypeList">
    </div>
  </div>
  <label translate>rulecfg.lineSnappedOnFeature.pointToSnapOn</label>
  <br/>
  <select
    class="ruleCfgInput"
    ng-model="layerToSnapOn"
    ng-options="fti.name as fti.alias for fti in ftis"
    ng-title="{{'rulecfg.common.choiceprompt' | translate}}"
    >
  </select>
  <button
    type="button"
    class="btn btn-mini btn-success"
    ng-click="addLayer(layerToSnapOn)"
    translate
    >common.add
  </button>

  <label
    ng-show="rule.parameters.layersToSnapOn.length > 0"
    translate
    >
  </label>
  <br />
  <translate>rulecfg.lineSnappedOnFeature.endObject</translate>
  <table
    ng-show="rule.parameters.layersToSnapOn.length > 0"
    class="rulecfggetintersectedLineTab2"
    >
    <tr>
      <th><translate>rulecfg.getintersectingline.layersColumn</translate></th>
      <th>
        <translate>rulecfg.setremoteattribute.shareObjectSourceName</translate>
      </th>
      <th><translate>rulecfg.getintersectingline.deleteColumn</translate></th>
    </tr>
    <tr ng-repeat="layer in rule.parameters.layersToSnapOn">
      <td>{{layer.layerName}}</td>
      <td>
        <select
          class="ruleCfgInput"
          ng-model="layer.shareObjectName"
          ng-options="shareObjName for shareObjName in allSharedObjectsNames"
          >
        </select>
      </td>
      <td>
        <button
          type="button"
          class="btn btn-mini btn-danger"
          ng-click="removeLayer($index)"
          >
          <i class="fa fa-minus"></i>
        </button>
      </td>
    </tr>
  </table>
</div>
<div ng-if="currentfeaturetype.typeInfo !== 'LINE' ">
  <translate>rulecfg.common.rulenotfitthislayer</translate>
</div>
