I need to use input field witch unique name for all fields. I cant't use [ngModelOptions]="{standalone: true}", because I have validation problem in the form (these fields are ignored in validation). This is part of my code:
<ng-template pTemplate="rowgroupfooter" let-vehicle>
<td>
<mat-input-container class="full-width" color="warn">
<input matInput [(ngModel)]="vehicle.subscription_price" [ngModelOptions]="{standalone: true}" required [disabled]="viewMode" type="number" min="0" [ngClass]="{ 'edited-price': vehicle.isSubscriptionPriceChanged }"
(input)="vehicle.isSubscriptionPriceChanged=true;" pInputText appendTo="body" style="background-color: white">
<mat-error>To pole jest wymagane</mat-error>
</mat-input-container>
</td>
...(more rows)
</ng-template>
So, how to add name="index" dynamically.
E.g
name='1'
name = '2'
...
name = 'n'