My grid columns are Dynamic add。
Transposition of columns encountered while editing grid in case of there were frozen columns.
https://stackblitz.com/edit/angular-ae4eds?file=app.component.html
|
App.component.html
<ng-template #editSettingsTemplate let-data>
<div ngForm #orderForm="ngForm">
<table class="e-table e-inline-edit" cellspacing="0.25">
<colgroup>
<col style="width: 120px;">
<col style="width: 120px;">
<col style="width: 120px;">
<col style="width: 130px;">
<col style="width: 150px;">
</colgroup>
<tbody>
<tr>
<td style="text-align: right" class='e-rowcell'>
<div class="e-input-group" [ngClass]= "{'e-disabled': !data.isAdd}">
<input class="e-input e-field" [(ngModel)]="orderData.OrderID" required [attr.disabled]="!data.isAdd ? '' : null" name='OrderID' type="text" (focus)="focusIn($event.target)"
(blur)="focusOut($event.target)" #OrderID style="text-align: right" />
</div>
</td>
<td class='e-rowcell'>
<div class="e-input-group">
<input class="e-input e-field" name='CustomerName' [(ngModel)]="orderData.CustomerName" required type="text" (focus)="focusIn($event.target)"
(blur)="focusOut($event.target)" #CustomerName />
</div>
</td>
<td style="text-align: right" class='e-rowcell'>
<ejs-numerictextbox name="Freight" id="Freight" [(ngModel)]="orderData.Freight" floatLabelType='Never'></ejs-numerictextbox>
</td>
<td style="text-align: right" class='e-rowcell'>
<ejs-datepicker id="OrderDate" name="OrderDate" required [(ngModel)]="orderData.OrderDate" floatLabelType='Never'></ejs-datepicker>
</td>
<td class='e-rowcell'>
<ejs-dropdownlist id="ShipCountry" name="ShipCountry" [(ngModel)]="orderData.ShipCountry" [dataSource]='shipCountryDistinctData' [fields]="{text: 'ShipCountry', value: 'ShipCountry' }" popupHeight='300px' floatLabelType='Never'></ejs-dropdownlist>
</td>
</tr>
</tbody>
</table>
</div>
</ng-template>
|
There is no doubt on static-columns.
However, it is required to use dynamic columns for the project I’m working on.
So, is there any other solution that can figure out this problem?