SmartIT_Extensions/dist/NTTDATA/api/views/field-customization/custom-fields/number-custom-field-ntt.html

32 lines
1.3 KiB
HTML

<div class="clearfix">
<label class="label_control-wrap">
<custom-field-label-ntt></custom-field-label-ntt>
<span class="custom-field__value" ng-if="!$parent.editMode && (data.value || data.value == 0)" tooltip="{{tooltipToShow}}">
{{(data.value | number:data.precision)}}</span>
<span class="custom-field-ntt__noValue" ng-if="!$parent.editMode && !data.value" ng-bind-html="('customField.label.noValue' | i18n)"></span>
<div class="ticket__required-field" ng-if="!$parent.editMode && data.isRequired && !data.value && data.value != 0">
<i class="icon-exclamation_triangle"></i> {{'ticket.notification.draft.missingField' | i18n:(data.label)}}
</div>
<div class="custom-field__number" ng-show="$parent.editMode">
<input type="number" valid-number
name="{{ data.name }}"
class="form-control"
precision="{{ data.precision }}"
step="{{ data.step }}"
number-type="{{ data.dataType }}"
number-required="{{ data.isRequired }}"
aria-required="{{data.isRequired}}"
ng-required="data.isRequired"
aria-labelledby="{{data.name + 'Label'}}"
ng-min="{{ data.min }}"
ng-max="{{ data.max }}"
ng-change="onFieldValueChange()"
ng-disabled="data.isReadOnly || !isEditable"
ng-model="data.value" />
</div>
</label>
</div>