|
[Style]
<style>
.space {
white-space: pre-wrap !important;
}
</style>
[Grid]
var data = [{ OrderID: "Example 1", CustomerID: "Customer ID 1" },
{ OrderID: "Example 2", CustomerID: "Customer ID with Missing gap" }];
$("#Grid").ejGrid({
dataSource: data, // to bind oData
allowPaging: true,
editSettings: { allowEditing: true, allowAdding: true, allowDeleting: true },// enable editSettings
columns: [
{ field: "OrderID", isPrimaryKey: true, headerText: 'Order ID', width: 90 },
{ field: "CustomerID", headerText: 'Customer ID', cssClass: "space", width: 90, editType: ej.Grid.EditingType.Dropdown }
]
});
|
I have reviewed the playground you have supplied and it only partially works.
It corrects the readonly gap on the grid, but the gap is still missing on the dropdown entry, please see the attached image demonstrating this.
|
$("#Grid").ejGrid({
. . .
actionComplete: function (args) {
//actionComplete event in Grid
if (args.requestType == "beginedit") {
//here we can apply the cssClass property while editing the Grid
$("#" + this._id + "CustomerID").ejDropDownList({ cssClass: "space" });
}
},
columns: [
. . .
]
});
|