I am having problems to open a dialog after clicking a CGridView’s row. Do you consider the way I am attempting this is correct?
Baiscally I have a CGridView, when I click any of its rows the method "selectionChanged" is triggered where I do a "jQuery.ajax(…"
jQuery.ajax(
{
"url":rel_url + "/rowDetails&name="+projectName+"&status="+projectStatus,
"cache":false,
"success":function(content)
{
$("#detailsDialog").dialog("open");
}
});
This jQuery.ajax triggers "actionRowDetails" in my controller, this action does a "renderPartial" of a php file that contains the dialog I want to display:
<?php
$this->beginWidget('zii.widgets.jui.CJuiDialog', array(
'id'=>'detailsDialog',
'options'=>array(
'title'=>'Project Details',
'width'=>500,
'height'=>300,
'autoOpen'=>true,
),
));
echo 'Dialog content here';
$this->endWidget('zii.widgets.jui.CJuiDialog');
?>
Inside the success method of the jQuery.ajax(… I attempt the following but it doesn’t work:
$("#detailsDialog").dialog("open");
Any help will be highly appreciated
Diego