core/dynamic-forms/input/input.type.component.ts
FieldType
changeDetection | ChangeDetectionStrategy.OnPush |
selector | c8y-field-input |
templateUrl | ./input.type.component.html |
Properties |
|
Accessors |
type |
gettype()
|
<input
*ngIf="type !== 'number'; else numberTmp"
[type]="type"
[formControl]="formControl"
class="form-control"
[formlyAttributes]="field"
[required]="to.required"
[attr.autocomplete]="to.autocomplete ? to.autocomplete : null"
[class.is-invalid]="showError"
/>
<ng-template #numberTmp>
<input
type="number"
[formControl]="formControl"
class="form-control"
[formlyAttributes]="field"
[required]="to.required"
[attr.autocomplete]="to.autocomplete ? to.autocomplete : null"
[class.is-invalid]="showError"
/>
</ng-template>