de1bc7e08b5b435e95e317e468e4baa07a929287
[dlux.git] / modules / yangman-resources / src / main / resources / yangman / views / rightpanel / form / list-data-top.tpl.html
1 <!-- Previous button -->
2 <button ng-click="yangList.shiftDisplayPrev()">
3     <md-icon class="material-icons">{{yangList.showPrevButton() ? 'arrow_back' : ''}}</md-icon>
4     <md-tooltip md-direction="top">{{ 'LIST_PREV_ITEM' | translate }}</md-tooltip>
5 </button>
6
7 <section ng-repeat="offset in yangList.displayOffsets" class="yangmanModule__right-panel__form__list-item"
8          layout="row" layout-align="start center"
9          ng-if="yangList.currentDisplayIndex + offset > -1 && node.listData.length > yangList.currentDisplayIndex + offset">
10
11     <!-- label -->
12     <md-tab-item class="md-tab pointer" ng-click="node.changeActElementData(yangList.currentDisplayIndex + offset)"
13                  ng-class="{'': yangList.currentDisplayIndex + offset === node.actElemIndex}">
14         <div layout="row">
15             <span flex="grow">
16                 {{yangForm.getNodeName(node.localeLabel, node.label)}}&nbsp;{{ yangList.getListName(offset, true).name }}
17             </span>
18         </div>
19
20         <md-tooltip md-direction="top" ng-if="yangList.getListName(offset, false).tooltip.length">
21             {{yangList.getListName(offset, false).tooltip}}
22         </md-tooltip>
23
24         <md-ink-bar class="custom" ng-if="yangList.currentDisplayIndex + offset === node.actElemIndex"></md-ink-bar>
25     </md-tab-item>
26
27     <!-- remove button -->
28     <md-icon md-font-set="material-icons"
29              class="pointer"
30              ng-click="yangList.removeListElem(yangList.currentDisplayIndex + offset,false)"
31              ng-if="selectedDatastore.label === yangList.constants.DATA_STORE_CONFIG && !yangList.disableAddingListElement">
32         <md-tooltip md-direction="top">{{ 'YANGMAN_LIST_DELETE_ITEM' | translate }}</md-tooltip>
33         remove_circle_outline
34     </md-icon>
35
36     <!-- duplicated key -->
37     <md-icon md-font-set="material-icons"
38              ng-show="node.doubleKeyIndexes.indexOf(yangList.currentDisplayIndex + offset) > -1"
39              ng-if="selectedDatastore.label === yangList.constants.DATA_STORE_CONFIG">
40         <md-tooltip md-direction="top">{{ 'YANGMAN_LIST_INDEX_DUPLICATE' | translate }}</md-tooltip>
41         error_outline
42     </md-icon>
43 </section>
44
45 <!-- Next button -->
46 <button ng-click="yangList.shiftDisplayNext('listData')"
47         ng-show="yangList.showNextButton('listData')">
48     <md-icon class="material-icons">arrow_forward</md-icon>
49     <md-tooltip md-direction="top">{{ 'LIST_NEXT_ITEM' | translate }}</md-tooltip>
50 </button>