Hi there,
I have tried to refer back to my essential JS 1 versions of applications for reference, however I am struggling to find how I can achieve the following in the new EJ2 grid component:
var paramTypesDropdown = [{ value: 'checkbox', text: 'checkbox' }, { value: 'string', text: 'string' }, { value: 'date', text: 'date' }, { value: 'datetime', text: 'datetime' }, { value: 'number', text: 'number' }, { value: 'decimal', text: 'decimal' }, { value: 'dropdown', text: 'dropdown' }, { value: 'dropdown-multiselect', text: 'dropdown-multiselect' }];
$('#taskmanagementtaskparamsgrid').ejGrid({
dataSource: data.items,
// Sets the EDIT/ADD dropdownlist for multi choice fields
actionComplete: function(args) {
if (args.requestType == 'add') {
// Set the dropdown types
$('#taskmanagementtaskparamsgridparameterType').ejDropDownList({
dataSource: paramTypesDropdown,
selectedIndex: 1
}
// rest of code removed for brevity...
});
So as you can see, on the actionComplete (which I can now do in EJ2 thanks to a previous post), I refer to the grid and column name (JQuery selector back then) and assign a dropdownlist component with a pre-selected list. This only needs to be shown in edit/add mode as I have seen examples of using a template. Ideally I don't want to use the template option in this case.
Is there any way to render another EJ2 component in the grid column as above?
Many thanks in advance!