Detail Caption Update on Master change

QuestionsDetail Caption Update on Master change
S19K15 asked 1 year ago

Hi, is there any way to update the caption of child grid when using tab-master-detail based on selected record of master's grid?
For example when a user changes the selected record on master grid the property "caption" of detail grid must change -> $grid_detail_jott["caption"] = "ID:"."-".intval($_GET["IDNumb"]);

3 Answers
Abu Ghufran answered 1 year ago

$opt["onSelectRow"] = "function(id){ $('#list2').jqGrid('setCaption','Details for ID: '+id); }";
$grid->set_options($opt);

where list2 is detail grid id.

S19K15 answered 1 year ago

Can i take a different data field from my master grid columns ecxept the id?

Abu Ghufran answered 1 year ago

For grid id list1, if you want to get data of column 'invdate' selected row:
jQuery('#list1').jqGrid('getCell', id, 'invdate');

Your Answer

8 + 19 =

OR, enter

Attach code here and paste link in question.
Attach screenshot here and paste link in question.



How useful was this discussion?

Click on a star to rate it!

Average rating / 5. Vote count:

As you found this post useful...

Follow us on social media!

We are sorry that this post was not useful for you!

Let us improve this post!