Can't inline-edit a joined field using a select
Can't inline-edit a joined field using a select
Hello Allan
I have joined two tables using the Editor, and when I try to inline-edit the joined column (as a select) I get the following error:
uncaught exception: Unable to automatically determine field from source. Please specify the field name
I can edit correctly using the default editing dialog.
In the editor config JS I have this
{
label: "Appealed From:",
name: "results.appealedFrom",
type: "select"
},
and in the initialization (note the editField - thought that would fix it....)
{
data:"appealedFrom.name", editField: "appealedFrom.id"
},
The php looks like this
Field::inst( 'results.appealedFrom' )->options( 'appealedFrom', 'id', 'name' ),
Field::inst( 'appealedFrom.name' )
)
->leftJoin( 'appealedFrom', 'appealedFrom.id', '=', 'results.appealedFrom' )
Obviously I have left a bit out but everything works except for that single column in inline-edit mode.
I used the debugger: code is aginar
Any help gratefully received!
Replies
No sooner did I ask the question did I find the answer. A typo in the editField entry. Thank you nonetheless