Reputation: 2871
I looked all over the web for this "simple" question with no answer!
how to embed a select input field into a dgrid like this example:
suppose we have this column:
editor({
label: "name",
autoSave:true,
field: "f_name",
className: 'style4'
}, "text", "dblclick")
Upvotes: 1
Views: 2119
Reputation: 2871
the answer based on frederic answer:
editor({
label: "subject",
field: "subject",
editorArgs: {
style: "width:75px;",
options: [
{value: "true", label: "true"},
{value: "false", label: "false"}
]
}
}, Select, "dblclick")
Upvotes: 2
Reputation: 750
Try something like this:
"dgrid.editor({
field: 'state',
editorArgs: {store: stateStore, style: 'width:120px;', maxHeight: -1}
}, dijit.form.Select)"
Here is the example: https://github.com/SitePen/dgrid/blob/master/test/GridFromHtml_Editors.html
Upvotes: 2