Hello
in my controller i declare a grid and i return a view with return view(‘personnes.index’, array(‘phpgrid_output’ => $out_master));
in my view i make {!! $phpgrid_output !!} but how do i make a {!! $phpgrid_output_MASTER!!} and the {!! $phpgrid_output_DETAIL !!} for the lookup-detail ?
thanks in advance,
Philippe
https://gist.github.com/philippedemaret33/0fb80ac6285ddadc628bc32f11c137f2
Ok,
pick sources from lookup-grid.php demo
in the Controller
$opt[“edit_options”][“afterShowForm”] = ‘function (form) {
function initLookupGrid(baseGridId, baseField, detailGridId, detailField)
{
…
replace list1 and list2 with listMaster and listDetail
return view(‘MyView.index’, array(‘phpgrid_output_Master’ => $out_master, ‘phpgrid_output_Details’ => $out_detail));
In the view
<div class=”title m-b-md”> <div class=”quote”>{!! $phpgrid_output_Master !!}</div>
<div id=”lookup_listDetails” style=”display:none; width:70vw”>{!! $phpgrid_output_Uds !!}</div>
and it’s work !