I’ve been searching for a solution but have been unable to find one.
I currently have a summary gridview with some editablecolumns and a linkcolumn that loads a detailview via ajax with x-editable fields. (note: i’m using yiibooster)
6685
The desired action is for calculations to occur and be shown in the summary gridview once the x-editablefields have been saved.
It seems the ajax loading of the detail view breaks the update function of the gridview. I’ve added the following to try and fix that but it did not.
if( Yii::app()->request->isAjaxRequest && ($action != 'ViewDetails')) {
Yii::app()->clientScript->scriptMap['jquery.js'] = false;
Yii::app()->clientScript->scriptMap['jquery.min.js'] = false;
Yii::app()->clientScript->scriptMap['jquery.yiigridview.js'] = false;
Yii::app()->clientScript->scriptMap['jquery.group.yiigridview.js'] = false;
Yii::app()->clientScript->scriptMap['bootstrap.min.js'] = false;
Yii::app()->clientScript->scriptMap['bootstrap-datepicker.min.js'] = false;
Yii::app()->clientScript->scriptMap['bootstrap-datepicker-noconflict.js'] = false;
Yii::app()->clientScript->scriptMap['bootstrap-editable.min.js'] = false;
Yii::app()->clientScript->scriptMap['jquery.jqote2.min.js'] = false;
Yii::app()->clientScript->scriptMap['jquery.ajax.cache.js'] = false;
Yii::app()->clientScript->scriptMap['jquery.ba-bbq.js'] = false;
Yii::app()->clientScript->scriptMap['jquery-ui-no-conflict.min.js'] = false;
}
The closest I’ve come to a solution is to is to reload the gridview via innerHtml to the div, however that breaks the gridview editable fields as the javascript does not reload.
The current code for the editable field in the detailview is
array( 'name' => 'quickSetup',
'editable' => array(
'type' => 'text',
'success' => "js: function(data) {
$.fn.yiiGridView.update('parts-panel');
}"
),
Which returns -
Thanks in advance for any help you can offer.