SmartIT_Extensions/BAK/AdressSearchFIX/adressService/views/adress-custom-field-ntt.html

40 lines
2.5 KiB
HTML

<div class="clearfix" ng-class="{'character-limit_message' : charLimit && $parent.editMode}">
<label class="label_control-wrap">
<custom-field-label></custom-field-label>
<span class="icon-pencil" ng-click="showAdressDialog({displayOnly:false})" ng-enter="showAdressDialog({displayOnly:false})" ng-if="$parent.editMode"></span>
<span class="icon-mapmarker" ng-click="showAdressDialog({displayOnly:true})" ng-enter="showAdressDialog({displayOnly:true})" ng-if="details.searchType && !$parent.editMode"></span>
<span class="custom-field__value" ng-if="!$parent.editMode && data.value" tooltip="{{tooltipToShow}}"
ng-bind-html="((status.isCollapsed) ? (data.value | characters: 160 : '' : 'workorder' | securelinky : '_blank') : (data.value | securelinky : '_blank')) || ('customField.label.noValue' | i18n)">
</span>
<div class="ticket__required-field" ng-if="!$parent.editMode && data.isRequired && !data.value">
<i class="icon-exclamation_triangle"></i> {{'ticket.notification.draft.missingField' | i18n:(data.label)}}
</div>
<div class="large-text__toggle-link row" ng-if="data.value.length > 160 && !$parent.editMode"
ng-click="status.isCollapsed = !status.isCollapsed">
{{ status.isCollapsed ? ('customArea.showMore' | i18n) : ('customArea.showLess' | i18n) }}
</div>
<div>
<div style="float:left; width:100%">
<input id="adress-typeahead-ntt" class="form-control" type="text" name="{{ data.name }}" title=" "
aria-required="{{data.isRequired}}" aria-labelledby="{{data.name + 'Label'}}"
ng-change="onFieldValueChangeNTT()" ng-model="data.value"
ng-model-options="{ updateOn: 'default blur', debounce: { 'default': 750, 'blur': 0 }}"
ng-required="data.isRequired" ng-disabled="data.isReadOnly || !isEditable"
ng-show="$parent.editMode" typeahead-min-length="3" typeahead-wait-ms="50"
typeahead-on-select="selectAdress($item)" typeahead-loading="category.isDataLoading"
typeahead-template-url="views/adress-selector-template-ntt.html"
typeahead="suggestion for suggestion in getAdresses($viewValue)"
autocorrect="off" spellcheck="false" autocomplete="off"/>
</div>
<!--<div ng-if="$parent.editMode" style="float:left; width:5%;padding-left:5px;"><span class="icon-pencil" ng-click="openAdressSearch($event)"></span> </div>-->
<br style="clear: left;">
</div>
<div>
<character-limit-message field="data.value" ng-if="charLimit && $parent.editMode" limit="{{charLimit}}">
</character-limit-message>
</div>
</label>
</div>