AllowEditing="false" appears not to work for all columns if the first column is set to "true"
It appears that in an EjsGrid with AllowEditing set to true (through GridEditSettings), if the first column is left empty or set to AllowEditing="true", all following columns become editable, even if they have AllowEditing="false". Things appear to function correctly if the first column is set to AllowEditing="false".
Here's an example of my code that does not work (all columns, including the last, are editable):
<EjsGrid ID=@($"CardOnFileGrid-{this.version}") Toolbar="this.toolbarItems" TValue="CardOnFileModel" @ref="this.cofGrid"
ShowColumnChooser="true" AllowPaging="true" AllowReordering="false" AllowResizing="true" AllowSorting="true" EnablePersistence="false"
Height="100%" Width="100%">
<EjsDataManager [email protected] CrossDomain="true" Adaptor="Adaptors.UrlAdaptor"></EjsDataManager>
<GridPageSettings PageSize="20" PageSizes="this.pageSizes" />
<GridFilterSettings Type="Syncfusion.EJ2.Blazor.Grids.FilterType.Menu"></GridFilterSettings>
<GridEditSettings AllowAdding="true" AllowEditing="true" AllowDeleting="true"></GridEditSettings>
<GridSelectionSettings CheckboxOnly="true"></GridSelectionSettings>
<GridColumns>
<GridColumn Field=@nameof(CardOnFileModel.Description) HeaderText="Description" TextAlign="TextAlign.Left" AutoFit="true" AllowEditing="true">
[...]
<GridColumn Field=@nameof(CardOnFileModel.Amount) HeaderText="Amount" TextAlign="TextAlign.Left" AutoFit="true" AllowEditing="false"></GridColumn>
<GridColumn Field=@nameof(CardOnFileModel.Status) HeaderText="Status" TextAlign="TextAlign.Left" AutoFit="true" AllowEditing="false"></GridColumn>
</GridColumns>
</EjsGrid>
If the order is changed around as such, then all of the AllowEditing sections appear to work:
<EjsGrid ID=@($"CardOnFileGrid-{this.version}") Toolbar="this.toolbarItems" TValue="CardOnFileModel" @ref="this.cofGrid"
ShowColumnChooser="true" AllowPaging="true" AllowReordering="false" AllowResizing="true" AllowSorting="true" EnablePersistence="false"
Height="100%" Width="100%">
<EjsDataManager [email protected] CrossDomain="true" Adaptor="Adaptors.UrlAdaptor"></EjsDataManager>
<GridPageSettings PageSize="20" PageSizes="this.pageSizes" />
<GridFilterSettings Type="Syncfusion.EJ2.Blazor.Grids.FilterType.Menu"></GridFilterSettings>
<GridEditSettings AllowAdding="true" AllowEditing="true" AllowDeleting="true"></GridEditSettings>
<GridSelectionSettings CheckboxOnly="true"></GridSelectionSettings>
<GridColumns>
<GridColumn Field=@nameof(CardOnFileModel.Status) HeaderText="Status" TextAlign="TextAlign.Left" AutoFit="true" AllowEditing="false"></GridColumn>
<GridColumn Field=@nameof(CardOnFileModel.Description) HeaderText="Description" TextAlign="TextAlign.Left" AutoFit="true" AllowEditing="true">
[...]
<GridColumn Field=@nameof(CardOnFileModel.Amount) HeaderText="Amount" TextAlign="TextAlign.Left" AutoFit="true" AllowEditing="false"></GridColumn>
</GridColumns>
</EjsGrid>
SIGN IN To post a reply.
1 Reply
LR
Logesh Rajappa
Syncfusion Team
January 17, 2020 11:11 AM UTC
Hi Ricky,
Thanks for contacting Syncfusion support
Query: my code that does not work (all columns, including the last, are editable)
We tried to reproduce the reported issue, but the grid editing behaves appropriate to the configuration. So we would like to get more information about the issue. Also please find the below working sample for your reference.
Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/URL_AllowEditing-183695931
Regards,
Logesh R
SIGN IN To post a reply.
- 1 Reply
- 2 Participants
-
RB Ricky Brooks
- Jan 15, 2020 11:06 PM UTC
- Jan 17, 2020 11:11 AM UTC